How to turn off optimizer that changes direct call to indirect call

Phung Nguyen nhphung@gmail.com
Fri Sep 3 03:33:00 GMT 2010


Hi all,

When I have a call to a function, GCC will compile into a direct call
to the function. But when I have many calls to the function, the
address of the function will be moved to a register and all the calls
become indirect call.What optimize pass does it and how can I turn it
off? This optimization is good for a variable but it is not good in
the function, so how can I keep it for variables but turning it off
for function?

Phung



More information about the Gcc-help mailing list