When profiling code in macOS Instruments 14.1 I'm frequently getting negative PMU counters. Specifically on counters: CPU_CLK_UNHALTED.THREAD
and INST_RETIRED.ANY
. It seems to me like overflow.
What are possible reasons for this and is there any way to correctly read PMU counters on macOS?