Re: [patch] Speed up find_pc_section

Tristan Gingold
2009-09-09T07:56:31Z

On Sep 9, 2009, at 7:58 AM, Joel Brobecker wrote:

>
>> +/* Return 1 if SECTION should be inserted into the section map.
>> + We want to insert only non-overlay and non-TLS section. */
>
> Can you explain what we do not want to add TLS sections? Is that
> just an optimization (code addresses should never point to TLS)?

(I suppose that the address of a TLS section is not relevant as it is
'duplicated' and relocated
for each thread).

...

>> +/* Filter out overlapping sections, issuing a warning if any are
>> found.
>> + Overlapping sections could really be overlay sections which we
>> didn't
>> + classify as such in insert_section_p, or we could be dealing
>> with a
>> + corrupt binary. */
>
> I think we should also mention the MacOS port where we load all
> sections
> of all .o files instead of just the debugging info. It looks like a
> design flaw in the MacOS port, but it was really a shortcut in getting
> things to work (aka a hack).

What is the correct way to load just the debugging info ? These
object files are
loaded using 'symbol_file_add_from_bfd' and I thought it was the only
way.

Tristan.