diff options
author | Andrew Carlotti <andrew.carlotti@arm.com> | 2024-04-03 23:35:08 +0100 |
---|---|---|
committer | Andrew Carlotti <andrew.carlotti@arm.com> | 2024-04-11 15:26:46 +0100 |
commit | 3ef14f56343ad3445f874638700f6b82f032a1ae (patch) | |
tree | 7f68041f23fda356e8acd91f2e6bcf0b5d677ace /gcc/btfout.cc | |
parent | e33fc847d5457bd56734cad056955102a23f405b (diff) | |
download | gcc-3ef14f56343ad3445f874638700f6b82f032a1ae.zip gcc-3ef14f56343ad3445f874638700f6b82f032a1ae.tar.gz gcc-3ef14f56343ad3445f874638700f6b82f032a1ae.tar.bz2 |
aarch64: Fix FMV array iteration bounds
There was an assumption in some places that the aarch64_fmv_feature_data
array contained FEAT_MAX elements. While this assumption held up till
now, it is safer and more flexible to use the array size directly.
Also fix the lower bound in compare_feature_masks to use ">=0" instead
of ">0", and add a test using the features at index 0 and 1. However,
the test already passed, because the earlier popcount check makes it
impossible to reach the loop if the masks differ in exactly one
location.
gcc/ChangeLog:
* config/aarch64/aarch64.cc (compare_feature_masks):
Use ARRAY_SIZE and >=0 for iteration bounds.
(aarch64_mangle_decl_assembler_name): Use ARRAY_SIZE.
gcc/testsuite/ChangeLog:
* g++.target/aarch64/mv-1.C: New test.
Diffstat (limited to 'gcc/btfout.cc')
0 files changed, 0 insertions, 0 deletions