This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC 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]

[Bug libgomp/65070] libgomp calls syscall instruction directly


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=65070

--- Comment #4 from Nadav Har'El <nyh at math dot technion.ac.il> ---
There is a fine line between relying on "Linux" (e.g., the glibc ABI functions
as defined in LSB for example), and relying on obscure architecture-specific
tricks (like calling the syscall *instruction* in a way that only works on
x86-64). The latter may be justified when performance is the ultimate concern,
but I wonder if this is the case here (as I explained in my previous comments).
When is not the case, I don't understand why not use the syscall() library
function. *That* is the Linux ABI, not the x86-64 instruction.

This is not only an OSv question (although my attempt to use it in OSv brought
up this question). It's also a question why all this complexity is needed, when
glibc's syscall() function already has it. It looks to me like gratuitous
duplication, unless I'm missing the real reason why this was done.

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