I just updated to 6.12.27, and the counter works now. According to rr dev, this is the kernel fix: perf/x86: Fix non-sampling (counting) events on certain x86 platforms