]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit
x86/APX: correct libbfd's EVEX Rn -> Bn transformations
authorJan Beulich <jbeulich@suse.com>
Fri, 31 Jan 2025 09:07:54 +0000 (10:07 +0100)
committerJan Beulich <jbeulich@suse.com>
Fri, 31 Jan 2025 09:07:54 +0000 (10:07 +0100)
commit43a7719af5aea466d8c7ac70742fb8e06d4bcf29
tree7af0bd4711885cc4a032dc2781b1dfe38141c73e
parentb2d844097b9730bf2c455021baccfddd72469aac
x86/APX: correct libbfd's EVEX Rn -> Bn transformations

In the recent GOTPCREL addition I screwed up, in clearing the Rn bits
afterwards rather than setting them. While that ought to be benign (for
the bits being ignored in situations like this), we still want to leave
"canonical" encodings.

The pre-existing GOTTPOFF conversion wasn't doing quite correctly
either: We cannot assume the incoming Bn bits to be in a particular
state, as for the addressing form in question they're ignored as well.

To address both, introduce a helper function. This is then also an
overall reduction of (source) code size (and use of "magic" numbers).
bfd/elf64-x86-64.c
ld/testsuite/ld-x86-64/apx-load1a.d