ndk icon indicating copy to clipboard operation
ndk copied to clipboard

Simpleperf: the result of cpu frequency is different from perf tool

Open magicse7en opened this issue 8 years ago • 1 comments

Refer to #644 , one more question:

I disabled DVFS, hotplug and keep all cpus on-line. I guess the simpleperf uses below formula to calculate cpu frequency: frequency = cycles / time ?

But I use linux-tool perf, the result is correct:

Performance counter stats for 'ls': 25.190308 task-clock (msec) # 0.939 CPUs utilized
0 context-switches # 0.000 K/sec
0 cpu-migrations # 0.000 K/sec
331 page-faults # 0.013 M/sec
42514492 cycles # 1.688 GHz
stalled-cycles-frontend
stalled-cycles-backend
27491753 instructions # 0.65 insns per cycle
3803236 branches # 150.980 M/sec
272886 branch-misses # 7.18% of all branches 0.026814000 seconds time elapsed

magicse7en avatar Mar 06 '18 01:03 magicse7en

I think it's already answered and fixed in https://github.com/android-ndk/ndk/issues/644.

yabinc avatar Mar 21 '18 18:03 yabinc