[llvm] [llvm-exegesis] Fix LBR hang on hybrid x86 CPUs (PR #216917)
Fangrui Song via llvm-commits
llvm-commits at lists.llvm.org
Fri Aug 21 22:47:04 PDT 2026
MaskRay wrote:
> Where exactly are you running into this? Hangs with just check-llvm?
>
> If that's the case, then I think I'd probably just prefer a band aid of timing out during test discovery (e.g., timeout of 5s). To fix this properly I think we would need much more principled handling of CPU cores that we don't currently have. I'm also not aware of anyone using the LBR functionality.
Yes, plain `check-llvm` hangs on an Intel Core i7-14700K. `perf` depends on libpfm, and LLVM_ENABLE_LIBPFM is enabled by default, so all users with perf installed may run into this hang if the test is scheduled on an E-core (which is likely guaranteed if you the default `ninja`, which does utilize all cores)
```
llvm/CMakeLists.txt
654:option(LLVM_ENABLE_LIBPFM "Use libpfm for performance counters if available." ON)
```
a standalone perf_event_open repro confirms `perf_event_open` succeeds on an E-core and the
event is simply never scheduled.
https://github.com/llvm/llvm-project/pull/216917
More information about the llvm-commits
mailing list