Re: is -fPIC safe for executable programs, or must -fPIE be used?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Mar 24, 2016 at 3:43 PM, Jeff Law <law@xxxxxxxxxx> wrote:
> On 03/24/2016 01:21 PM, Jeffrey Walton wrote:
>>
>> One of the GCC devs explained why its OK a few years ago, but I can't
>> find the bug report with the explanation. I just use -fPIC all the
>> time unless its i686 because the GOT pointer basically reserves EBX.
>> On i686 it becomes a tradeoff because you lose a register, so you may
>> not want -fPIC/-fPIE at all.
>
> Actually EBX is no longer reserved on i686 when generating PIC code.  I
> believe that code went into gcc-5.

Oh nice, thanks for that.

Jeff



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux