diff options
author | Victor Do Nascimento <victor.donascimento@arm.com> | 2024-05-31 14:25:11 +0100 |
---|---|---|
committer | Victor Do Nascimento <victor.donascimento@arm.com> | 2024-06-12 10:23:38 +0100 |
commit | f6b9a064a295f5371901e2fac380d20e77cf7131 (patch) | |
tree | 8191663d98f6a7f38e42bc16f115f106b5d0ade5 /libatomic/load_n.c | |
parent | cf5f9171bae1f5f3034dc9a055b77446962f1a8c (diff) | |
download | gcc-f6b9a064a295f5371901e2fac380d20e77cf7131.zip gcc-f6b9a064a295f5371901e2fac380d20e77cf7131.tar.gz gcc-f6b9a064a295f5371901e2fac380d20e77cf7131.tar.bz2 |
Libatomic: AArch64: Convert all lse128 assembly to .insn directives
Given the lack of support for the LSE128 instructions in all but the
the most up-to-date version of Binutils (2.42), having the build-time
test for assembler support for these instructions often leads to the
building of Libatomic without support for LSE128-dependent atomic
function implementations. This ultimately leads to different people
having different versions of Libatomic on their machines, depending on
which assembler was available at compilation time.
Furthermore, the conditional inclusion of these atomic function
implementations predicated on assembler support leads to a series of
`#if HAVE_FEAT_LSE128' guards scattered throughout the codebase and
the need for a series of aliases when the feature flag evaluates
to false. The preprocessor macro guards, together with the
conditional aliasing leads to code that is cumbersome to understand
and maintain.
Both of the issues highlighted above will only get worse with the
coming support for LRCPC3 atomics which under the current scheme will
also require build-time checks.
Consequently, a better option for both consistency across builds and
code cleanness is to make recourse to the `.inst' directive. By
replacing all novel assembly instructions for their hexadecimal
representation within `.inst's, we ensure that the Libatomic code is
both considerably cleaner and all machines build the same binary,
irrespective of binutils version available at compile time.
This patch therefore removes all configure checks for LSE128-support
in the assembler and all the guards and aliases that were associated
with `HAVE_FEAT_LSE128'
libatomic/ChangeLog:
* acinclude.m4 (LIBAT_TEST_FEAT_AARCH64_LSE128): Delete.
* auto-config.h.in (HAVE_FEAT_LSE128): Likewise
* config/linux/aarch64/atomic_16.S: Replace all LSE128
instructions with equivalent `.inst' directives.
(HAVE_FEAT_LSE128): Remove all references.
* configure: Regenerate.
* configure.ac: Remove call to LIBAT_TEST_FEAT_AARCH64_LSE128.
Diffstat (limited to 'libatomic/load_n.c')
0 files changed, 0 insertions, 0 deletions