DSO: pc relative symbol address
Ian Lance Taylor
iant@google.com
Fri Mar 19 18:15:00 GMT 2010
kum <a.kumaresh@gmail.com> writes:
> There are no direct invocation of my_foo1. What prevents the compiler
> from emitting a PC relative address to store in my_foo? Something like
> lw $2, PC - <offset>
You need to get the address of my_foo1 into $2. Using a PC relative
value only works if your processor has a PC-relative load instruction.
Not all processors have such an instruction. If your processor has
one and gcc is not using it, then this may be a bug.
Ian
More information about the Gcc-help
mailing list