[patch x64 SEH]: Support xdata/pdata for link-once code

Kai Tietz ktietz70@googlemail.com
Tue Sep 14 18:19:00 GMT 2010


2010/9/14 Richard Henderson <rth@redhat.com>:
> On 09/14/2010 10:06 AM, Kai Tietz wrote:
>> Hmm, is there such a mass of different code-segments to be expected
>> within one file that we will see here a real gain using hash-tables?
>
> With a large c++ file, with either -ffunction-sections or templates
> (which are going to use link-once sections), you may well have on
> the order of tens of thousands of code segments.  And each one of
> those code segments will be used exactly once.
>
> Each will result in a failing search through the linked list.  Better
> to fail earlier if possible, either through C1*O(log N) tree or C2*O(1)
> hash table.  I don't recall the relative magnitude of C1 and C2 in this
> case, so I'd choose the one that's easier to use.
>
> Of course, there's the other common case of all functions in .text.
> If you use the hash table, it might be worth-while to not store the
> standard text section in the table, but in a separate variable.

Yeah, I see. This was the reason why I add new section always to first
element. So in the case of -ffunction-sections for seek. The issue is
the initial find for an new section. Ok, I'll check what here the
easiest algorithm will be.

Kai


-- 
|  (\_/) This is Bunny. Copy and paste
| (='.'=) Bunny into your signature to help
| (")_(") him gain world domination



More information about the Binutils mailing list