lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 29 Sep 2014 13:25:44 -0400
From:	Waiman Long <waiman.long@...com>
To:	Namhyung Kim <namhyung@...nel.org>
CC:	Arnaldo Carvalho de Melo <acme@...nel.org>,
	Peter Zijlstra <peterz@...radead.org>,
	Paul Mackerras <paulus@...ba.org>,
	Ingo Molnar <mingo@...hat.com>, linux-kernel@...r.kernel.org,
	Scott J Norton <scott.norton@...com>,
	Douglas Hatch <doug.hatch@...com>,
	Don Zickus <dzickus@...hat.com>, Jiri Olsa <jolsa@...nel.org>,
	Adrian Hunter <adrian.hunter@...el.com>
Subject: Re: [PATCH v4 2/2] perf tool: improves DSO long names lookup speed
 with rbtree

On 09/29/2014 12:02 AM, Namhyung Kim wrote:
> On Fri, 26 Sep 2014 11:22:34 -0300, Arnaldo Carvalho de Melo wrote:
>> Em Wed, Sep 24, 2014 at 11:45:40AM -0400, Waiman Long escreveu:
>>> +	/*
>>> +	 * Find node with the matching name
>>> +	 */
>>> +	while (*p) {
>>> +		struct dso *this = rb_entry(*p, struct dso, rb_node);
>>> +		long rc = (long)strcmp(name, this->long_name);
>>> +
>>> +		parent = *p;
>>> +		if (rc == 0) {
>>> +			/*
>>> +			 * In case the new DSO is a duplicate of an existing
>>> +			 * one, print an one-time warning&  sort the entry
>>> +			 * by its DSO address.
>>> +			 */
>>> +			if (!dso || (dso == this))
>>> +				return this;	/* Find matching dso */
>>> +			/*
>>> +			 * The kernel DSOs may have duplicated long name,
>>> +			 * so don't print warning for them.
>>> +			 */
>>> +			if (!warned&&  !strstr(name, "kernel.kallsyms")
>>> +				&&  !strstr(name, "/vmlinux")) {
>>> +				pr_warning("Duplicated dso long name: %s\n",
>>> +					   name);
>> Huh? Can you elaborate on this? Ho can we add multiple DSOs with the
>> exact same name into this tree? Have you actually seen this in practice?
>> I guess so, judging by the comment above ("may have").
> I guess it's because we split maps and dsos by section name (for kernel
> only).  Please look at dso__load_sym() - If map_groups__find_by_name()
> with short name + section name fails, it creates a new dso and map, and
> then curr_dso->long_name will be set as dso->long_name.
>
> Thanks,
> Namhyung
>

Yes, it is where I found that the different DSOs may have the same long 
name.

-Longman
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ