]> git.ipfire.org Git - thirdparty/glibc.git/commit
i386: Remove broken CAN_USE_REGISTER_ASM_EBP (bug 28771)
authorFlorian Weimer <fweimer@redhat.com>
Thu, 13 Jan 2022 13:59:29 +0000 (14:59 +0100)
committerFlorian Weimer <fweimer@redhat.com>
Thu, 13 Jan 2022 13:59:44 +0000 (14:59 +0100)
commita78e6a10d0b50d0ca80309775980fc99944b1727
tree19f7d5292f87eb81b13cc4684c2c818bcbbe7a5e
parentf9dab1b5f23d0fb008a56c7c6c8919adb49d3611
i386: Remove broken CAN_USE_REGISTER_ASM_EBP (bug 28771)

The configure check for CAN_USE_REGISTER_ASM_EBP tried to compile a
simple function that uses %ebp as an inline assembly operand.  If
compilation failed, CAN_USE_REGISTER_ASM_EBP was set 0, which
eventually had these consequences:

(1) %ebx was avoided as an inline assembly operand, with an
    assembler macro hack to avoid unnecessary register moves.
(2) %ebp was avoided as an inline assembly operand, using an
    out-of-line syscall function for 6-argument system calls.

(1) is no longer needed for any GCC version that is supported for
building glibc.  %ebx can be used directly as a register operand.
Therefore, this commit removes the %ebx avoidance completely.  This
avoids the assembler macro hack, which turns out to be incompatible
with the current Systemtap probe macros (which switch to .altmacro
unconditionally).

(2) is still needed in many build configurations.  The existing
configure check cannot really capture that because the simple function
succeeds to compile, while the full glibc build still fails.
Therefore, this commit removes the check, the CAN_USE_REGISTER_ASM_EBP
macro, and uses the out-of-line syscall function for 6-argument system
calls unconditionally.

Reviewed-by: H.J. Lu <hjl.tools@gmail.com>
config.h.in
sysdeps/unix/sysv/linux/i386/configure
sysdeps/unix/sysv/linux/i386/configure.ac
sysdeps/unix/sysv/linux/i386/sysdep.h