]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
x86: %riz, %rip, and %eip don't require REX
authorJan Beulich <jbeulich@suse.com>
Fri, 21 Jun 2024 06:35:23 +0000 (08:35 +0200)
committerJan Beulich <jbeulich@suse.com>
Fri, 21 Jun 2024 06:35:23 +0000 (08:35 +0200)
commit8bcda53caab0308b5908dda68194ab5e3e2dd09d
treedce5a428051efbedc088493ba1347c02a32d772b
parentc68a6e5cadf333ab3d55443d3aed156415660600
x86: %riz, %rip, and %eip don't require REX

While these can't be used as register operands, they can be used for
memory operand addressing. Such uses do not prevent conversion: The
RegRex64 checks in check_Rex_required() for base and index registers
were simply wrong. They specifically also aren't needed for byte
registers, as those won't pass i386_index_check() anyway.
gas/config/tc-i386.c
gas/testsuite/gas/i386/x86-64-apx-ndd-optimize.d
gas/testsuite/gas/i386/x86-64-apx-ndd-optimize.s