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

Re: [Xen-devel] [PATCH] libx86: Work around GCC bug with ebx output constrants



>>> On 19.11.18 at 15:08, <andrew.cooper3@xxxxxxxxxx> wrote:
> On 19/11/2018 13:51, Jan Beulich wrote:
>>>>> On 19.11.18 at 14:11, <andrew.cooper3@xxxxxxxxxx> wrote:
>>> In practice, this is a collision between the output constraint and the GOT
>>> which is held in %ebx when compiling with -fPIC for libraries.
>>>
>>> This affects at least GCC 4.9 as shipped in Debian Jessie, but 
>>> experimentally
>>> is fixed in GCC 6 and later.  Curiously, it only affects 32-bit builds.
>> I don't think there's anything curious here: The GOT (or actually
>> .rodata here) gets accessed by %rip-relative addressing in small
>> model 64-bit code, iirc.
> 
> Aah - good point, and also explains the other conditionals in GCC's
> intrinsic header.
> 
> I'll update the logic to cope with the larger 64bit models.

Do you need to? The ABI specifies that the GOT pointer lives
in %r15 in that case.

Jan



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.