diff options
author | Uros Bizjak <ubizjak@gmail.com> | 2025-08-18 11:19:47 +0200 |
---|---|---|
committer | H.J. Lu <hjl.tools@gmail.com> | 2025-08-20 11:48:17 -0700 |
commit | f80dddbe291b23b6851b22f734e2c421a4f9a4bc (patch) | |
tree | 1408b51edd5195099525248d1f8666a28ef11291 /sysdeps | |
parent | dd38f49cdcc3630c541d9f603eb9b5dbeccbbe56 (diff) | |
download | glibc-f80dddbe291b23b6851b22f734e2c421a4f9a4bc.zip glibc-f80dddbe291b23b6851b22f734e2c421a4f9a4bc.tar.gz glibc-f80dddbe291b23b6851b22f734e2c421a4f9a4bc.tar.bz2 |
i386: Use TESTB instead of TESTL in ____longjmp_chk()
There is no need to use TESTL when checking the least-significant bit
with a TEST instruction. Use TESTB, which is three bytes shorter:
f6 44 24 04 01 testb $0x1,0x4(%esp)
vs:
f7 44 24 04 01 00 00 testl $0x1,0x4(%esp)
00
for the same effect.
No functional changes intended.
Signed-off-by: Uros Bizjak <ubizjak@gmail.com>
Cc: H.J.Lu <hjl.tools@gmail.com>
Cc: Carlos O'Donell <carlos@redhat.com>
Reviewed-by: H.J. Lu <hjl.tools@gmail.com>
Diffstat (limited to 'sysdeps')
-rw-r--r-- | sysdeps/unix/sysv/linux/i386/____longjmp_chk.S | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sysdeps/unix/sysv/linux/i386/____longjmp_chk.S b/sysdeps/unix/sysv/linux/i386/____longjmp_chk.S index e468d34..3e09f15 100644 --- a/sysdeps/unix/sysv/linux/i386/____longjmp_chk.S +++ b/sysdeps/unix/sysv/linux/i386/____longjmp_chk.S @@ -67,7 +67,7 @@ ENTRY (____longjmp_chk) /* Without working sigaltstack we cannot perform the test. */ test %eax, %eax jne .Lok2 - testl $1, 4(%esp) + testb $1, 4(%esp) jz .Lfail movl (%esp), %eax |