assert (! "unexpected dynamic reloc type");
Roland McGrath
roland@frob.com
Fri Jul 16 16:58:00 GMT 1999
> Roland McGrath <roland@frob.com> writes:
>
> > Say what?? This is code that is never even reached unless there is a fatal
> > problem.
>
> You have to look how gcc generates code. Since gcc so far does not use
> block reordering, code for ifs are generated like this:
>
> cmp
> jump if not to label
>
> code for if
>
> label:
>
> Therefore a larger `if code' is polluting the icache significantly.
I see. Well, I was already planning to use a call to a separate function
to do the message formatting and panic, just to consolidate the code for
all platforms. The current code calls __assert_fail, with four arguments.
The bad-reloc-type panic function will need only two args (link_map and reloc),
so the code will be smaller.
More information about the Libc-hacker
mailing list