[RFC] use symbol_ref flags for rs6000

Dale Johannesen dalej@apple.com
Thu May 1 22:42:00 GMT 2003


On Thursday, May 1, 2003, at 03:30  PM, David Edelsohn wrote:
>>>>>> Andrew Pinski writes:
>
> Andrew> The only problem with this on darwin, it is okay to call the 
> static int
> Andrew> so that will become a regression.
>
> 	Regession in what sense?  I have heard that calling function
> pointer on Darwin actually is faster.

Depends.  If you look at the assembly output, a "direct" call actually 
jumps
to a stub of 8 insns and executes those before getting to the real 
target.
However, the linker eliminates stubs in all cases where that's 
possible, so
if the caller and callee are both present at static link time, the 
direct
call winds up really being direct, therefore faster than going through a
pointer.  Calls to shared libraries do execute the stub code,
and in that case going through a pointer is faster.



More information about the Gcc-patches mailing list