Skip to content

Commit e33fc84

Browse files
aarch64: Reorder FMV feature priorities
Some higher priority FMV features were dependent subsets of lower priority features. Fix this, using the new priorities specified in ARM-software/acle#279. gcc/ChangeLog: * config/aarch64/aarch64-option-extensions.def: Reorder FMV entries. gcc/testsuite/ChangeLog: * gcc.target/aarch64/cpunative/native_cpu_21.c: Reorder features. * gcc.target/aarch64/cpunative/native_cpu_22.c: Ditto.
1 parent 1defe74 commit e33fc84

File tree

3 files changed

+9
-13
lines changed

3 files changed

+9
-13
lines changed

gcc/config/aarch64/aarch64-option-extensions.def

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -99,17 +99,17 @@ AARCH64_OPT_EXTENSION(NAME, IDENT, REQUIRES, EXPLICIT_ON, EXPLICIT_OFF, \
9999
AARCH64_FMV_FEATURE(NAME, IDENT, (IDENT))
100100

101101

102-
AARCH64_OPT_EXTENSION("fp", FP, (), (), (), "fp")
103-
104-
AARCH64_OPT_EXTENSION("simd", SIMD, (FP), (), (), "asimd")
105-
106102
AARCH64_OPT_FMV_EXTENSION("rng", RNG, (), (), (), "rng")
107103

108104
AARCH64_OPT_FMV_EXTENSION("flagm", FLAGM, (), (), (), "flagm")
109105

110106
AARCH64_FMV_FEATURE("flagm2", FLAGM2, (FLAGM))
111107

112-
AARCH64_FMV_FEATURE("fp16fml", FP16FML, (F16FML))
108+
AARCH64_OPT_FMV_EXTENSION("lse", LSE, (), (), (), "atomics")
109+
110+
AARCH64_OPT_FMV_EXTENSION("fp", FP, (), (), (), "fp")
111+
112+
AARCH64_OPT_FMV_EXTENSION("simd", SIMD, (FP), (), (), "asimd")
113113

114114
AARCH64_OPT_FMV_EXTENSION("dotprod", DOTPROD, (SIMD), (), (), "asimddp")
115115

@@ -121,12 +121,6 @@ AARCH64_OPT_EXTENSION("rdma", RDMA, (), (SIMD), (), "asimdrdm")
121121

122122
AARCH64_FMV_FEATURE("rmd", RDM, (RDMA))
123123

124-
AARCH64_OPT_FMV_EXTENSION("lse", LSE, (), (), (), "atomics")
125-
126-
AARCH64_FMV_FEATURE("fp", FP, (FP))
127-
128-
AARCH64_FMV_FEATURE("simd", SIMD, (SIMD))
129-
130124
AARCH64_OPT_FMV_EXTENSION("crc", CRC, (), (), (), "crc32")
131125

132126
AARCH64_FMV_FEATURE("sha1", SHA1, ())
@@ -160,6 +154,8 @@ AARCH64_FMV_FEATURE("fp16", FP16, (F16))
160154
-march=armv8.4-a+nofp16+fp16 enables F16 but not F16FML. */
161155
AARCH64_OPT_EXTENSION("fp16fml", F16FML, (), (F16), (), "asimdfhm")
162156

157+
AARCH64_FMV_FEATURE("fp16fml", FP16FML, (F16FML))
158+
163159
AARCH64_FMV_FEATURE("dit", DIT, ())
164160

165161
AARCH64_FMV_FEATURE("dpb", DPB, ())

gcc/testsuite/gcc.target/aarch64/cpunative/native_cpu_21.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ int main()
77
return 0;
88
}
99

10-
/* { dg-final { scan-assembler {\.arch armv8-a\+flagm\+dotprod\+rdma\+lse\+crc\+fp16fml\+rcpc\+i8mm\+bf16\+sve2-aes\+sve2-bitperm\+sve2-sha3\+sve2-sm4\+sb\+ssbs\n} } } */
10+
/* { dg-final { scan-assembler {\.arch armv8-a\+flagm\+lse\+dotprod\+rdma\+crc\+fp16fml\+rcpc\+i8mm\+bf16\+sve2-aes\+sve2-bitperm\+sve2-sha3\+sve2-sm4\+sb\+ssbs\n} } } */
1111

1212
/* Check that an Armv8-A core doesn't fall apart on extensions without midr
1313
values. */

gcc/testsuite/gcc.target/aarch64/cpunative/native_cpu_22.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ int main()
77
return 0;
88
}
99

10-
/* { dg-final { scan-assembler {\.arch armv8-a\+flagm\+dotprod\+rdma\+lse\+crc\+fp16fml\+rcpc\+i8mm\+bf16\+sve2-aes\+sve2-bitperm\+sve2-sha3\+sve2-sm4\+sb\+ssbs\+pauth\n} } } */
10+
/* { dg-final { scan-assembler {\.arch armv8-a\+flagm\+lse\+dotprod\+rdma\+crc\+fp16fml\+rcpc\+i8mm\+bf16\+sve2-aes\+sve2-bitperm\+sve2-sha3\+sve2-sm4\+sb\+ssbs\+pauth\n} } } */
1111

1212
/* Check that an Armv8-A core doesn't fall apart on extensions without midr
1313
values and that it enables optional features. */

0 commit comments

Comments
 (0)