This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] powerpc: fenvinline.h refactor



On 24/01/2020 06:50, Florian Weimer wrote:
> * Adhemerval Zanella:
> 
>> I don't think it is a good practice to re-define bultins, use it along with 
>> an extra indirection instead.  Something as:
>>
>>   #  if !__GNUC_PREREQ(9, 0)
>>   #   define __mtfsb0(__b) __asm__ __volatile__ ("mtfsb0 %0" : : "i" (__b))
>>   #   define __mtfsb1(__b) __asm__ __volatile__ ("mtfsb1 %0" : : "i" (__b))
>>   #  else
>>   #   define __mtfsb0(__b) __builtin_mtfsb0 (__b)
>>   #   define __mtfsb1(__b) __builtin_mtfsb1 (__b)
>>   #  endif
> 
> I think __mtfsb0 and __mtfsb1 conflict with gcc's installed
> pu_intrinsics.h header.

Right, in this case prepend with __glibc or any other related unique
identifier.  Checking on ppu_intrinsics.h, I wonder if the asm inline
should not use the 'n' constraint as well.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]