jump after return

Alain Ketterlin alain.ketterlin@gmail.com
Fri Nov 12 06:48:00 GMT 2010


When compiling at -O2 and -O3 optimization, I've found several instances 
of routines ending with:

retq
jmp <address-of-next-routine>

with no branch pointing to the jmp instruction. Is there any specific 
reason for such code? Is there a way to avoid this?

This is gcc 4.4.5, as installed on Ubuntu 10.10, compiling the SPEC OMP 
and CPU-2006 benchmarks.

Thanks in advance.

-- Alain.



More information about the Gcc mailing list