Richard Henderson <r...@redhat.com> wrote on 2010/10/06 00:13:22: > > On 10/05/2010 02:40 PM, Joakim Tjernlund wrote: > > Especially one that doesn't require each function > > to calculate the GOT address in the function prologue(why is that so?) > > Because PIC code can be called from non-PIC code and because > the non-PIC code does not load the GOT address. > > Avoiding re-computation of the PIC register is something that > could be done via LTO and/or cgraph optimizations. To my > knowledge, no one is working on that at present.
One could add an option to assume PIC reg is set. This would help targets where one has complete control. I beleive ARM has one: -msingle-pic-base