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 2/4] S390: Use own tbegin macro instead of __builtin_tbegin.


On 12/22/2016 01:54 PM, Florian Weimer wrote:
On 12/06/2016 02:51 PM, Stefan Liebler wrote:

The used inline assembly does not clobber the fprs / vrs!
Clobbering the latter ones would force the compiler to save / restore
the call saved fprs as those overlap with the vrs, but they only
need to be restored if the transaction fails.  Thus the user of the
tbegin macros has to compile the file / function with -msoft-float.
It prevents gcc from using fprs / vrs.

Is it possible to disable the new macros if the file is not compiled
with -msoft-float?
Those macros/builtins are only used for the mutex lock elision code in elision-*.c files. This code does not use float computation. The compiler flag is used to prevent the compiler to perform optimizations which use fprs or vrs. At the moment gcc performs no such optimizations.

If you want to use such macros/builtins in other files you'll at least have to add -mhtm compiler flag to be able to use those builtins.

Bye
Stefan


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