Re: [PATCH] x86: use cpufreq_quick_get() for /proc/cpuinfo "cpu MHz" again

From: Thomas Gleixner
Date: Wed Nov 15 2017 - 13:06:32 EST


On Wed, 15 Nov 2017, Linus Torvalds wrote:
> On Tue, Nov 14, 2017 at 11:43 PM, Ingo Molnar <mingo@xxxxxxxxxx> wrote:
> Again, try that "cat" example again, and time it.
>
> (And yes, I also know that "cpu*/cpufreq" is a symlink, but the direct
> names are illogical, and no faster for me. Try it if you like:
>
> time cat /sys/devices/system/cpu/cpufreq/policy*/scaling_cur_freq > /dev/null

Just for the fun of it I tried. It's exactly the same time as /proc/cpuinfo
with the reverted patch which did the full IPI thing, i.e. >4 seconds on
that machine.

Not a surprise because those files do the full IPI thing as well.

Thanks,

tglx