Scott L. Burson wrote:
>> There are some separate issues here:
>>
>> 1) Big slowdown with introduction of linkonce
>> processing
>> 2) Performance of ld vs gld before the big
>> slowdown
>> 3) Unknown performance of ld group processing
>> when facing
>> super large C++ objects.
>
> I don't understand what (3) refers to -- maybe it doesn't matter. The link
> task I sent you is the worst one we have.
>
> I've now tried GCC 4.3.2 with the snv_104 linker, and it doesn't make much
> difference (if any) -- the link time is still in the 17 - 18 minute range.
> Maybe the changes that you thought were in 4.3 are actually in 4.4?
>
> BTW, it's easy enough for me to switch back to the snv_86 linker. So there's
> no particular rush here.
>
> -- Scott
In your previous message, you said that you'd be happy to try the newer
gcc, but that you expected that the performance would be no better than
what you were getting before with the snv_86 linker. That's not obvious
to me: The newer gcc generates objects with SHT_GROUP sections instead of
the old linkonce stuff. That's a different code path through ld, with
potentially
different performance. So #3 says that I don't know how fast that's
going to be, but imagine that we might uncover something else that could
be improved.
-----
I assumed that the latest gcc uses SHT_GROUP, but don't actually
know which version introduces it. So let's find out what your new
gcc is doing. Take an object built with your new gcc compiler, and do:
% elfdump -c | grep linkonce
If you get any output, then you're not using a compiler with the SHT_GROUP
stuff, and the fact that you're getting the same link times is not surprising.
If on the other hand,
% elfdump -c | grep GROUP
produces output, then the new compiler does use the group feature.
Alternatively, I do know that the Sun compilers use SHT_GROUP.
I don't know if that's an option for you.
-----
Another data point: When I run your big link on my Nevada system
(Ultra 24, 4GM memory), it links in 10sec. (My test yesterday, with
profiling turned on took 18 sec). I don't remember if you said, but what
sort of machine are you using, and how much memory does it have? Given
the size of this link, I'm wondering if you're swapping...
I'm glad you have snv_86 to fall back on. We'll continue to work on
this issue...
- Ali