Bug 494162 - adx flag not set in cpuid, but adox/adcx insns work
Summary: adx flag not set in cpuid, but adox/adcx insns work
Status: REPORTED
Alias: None
Product: valgrind
Classification: Developer tools
Component: vex (other bugs)
Version First Reported In: 3.22.0
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Julian Seward
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-10-05 10:35 UTC by Joe Pixton
Modified: 2024-10-05 10:35 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joe Pixton 2024-10-05 10:35:50 UTC
SUMMARY
valgrind appears to correctly support instructions under the ADX CPUID flag (adcx, adox), however the ADX flag appears to be masked from CPUID.

STEPS TO REPRODUCE
```
$ git clone https://github.com/ctz/x86utils
$ cd x86utils
$ make

# baseline  for host
$ ./test | grep features-5
features-5: AVX512VL AVX512BW SHA AVX512CD CLWB CLFLUSHOPT AVX512IFMA SMAP ADX RDSEED AVX512DQ AVX512F PQE PQM INVPCID ERMS BMI2 SMEP AVX2 BMI1 FSGSBase 
```

OBSERVED RESULT
```
$ valgrind -q ./test | grep features-5
features-5: RDSEED xFPUCS INVPCID ERMS BMI2 SMEP AVX2 BMI1 TSCAdjust 
```

EXPECTED RESULT
```
$ valgrind -q ./test | grep features-5
features-5: ADX RDSEED xFPUCS INVPCID ERMS BMI2 SMEP AVX2 BMI1 TSCAdjust 
```

SOFTWARE/OS VERSIONS
This is valgrind-3.22.0 as packaged by Ubuntu 24.04 (3.22.0-0ubuntu3), on x86_64.