Skip to content

Commit

Permalink
Add FlagM2 to HWCAP feature bits
Browse files Browse the repository at this point in the history
FlagM2 (bit 39, kAXFlag to VIXL) was missing from the HWCAP feature bits used
for mapping Linux's feature reporting to VIXL. This caused subsequent bits to be
off by one.
  • Loading branch information
mmc28a committed Jan 26, 2022
1 parent ae0af05 commit 0222be8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/aarch64/cpu-aarch64.cc
Original file line number Diff line number Diff line change
Expand Up @@ -279,17 +279,18 @@ CPUFeatures CPU::InferCPUFeaturesFromOS(
CPUFeatures::kSVEBitPerm,
CPUFeatures::kSVESHA3,
CPUFeatures::kSVESM4,
CPUFeatures::kFrintToFixedSizedInt,
CPUFeatures::kAXFlag,
// Bits 40-47
CPUFeatures::kFrintToFixedSizedInt,
CPUFeatures::kSVEI8MM,
CPUFeatures::kSVEF32MM,
CPUFeatures::kSVEF64MM,
CPUFeatures::kSVEBF16,
CPUFeatures::kI8MM,
CPUFeatures::kBF16,
CPUFeatures::kDGH,
CPUFeatures::kRNG,
// Bits 48+
CPUFeatures::kRNG,
CPUFeatures::kBTI};

uint64_t hwcap_low32 = getauxval(AT_HWCAP);
Expand Down

0 comments on commit 0222be8

Please sign in to comment.