LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Kernel (https://www.linuxquestions.org/questions/linux-kernel-70/)
-   -   what is difference between performance and frequency of processers (https://www.linuxquestions.org/questions/linux-kernel-70/what-is-difference-between-performance-and-frequency-of-processers-4175717868/)

Ansen 10-17-2022 09:37 PM

what is difference between performance and frequency of processers
 
There are two concepts in cpufreq framework:
1. performance
2. frequency

But only the frequency is the real variable to adjust the cpu's.
What is different between them ?

dugan 10-18-2022 12:04 AM

Well, uh, you know how computers used to have a turbo button?

Ansen 10-18-2022 01:06 AM

I have no idea about the button.

pan64 10-18-2022 04:24 AM

https://en.wikipedia.org/wiki/Turbo_button
https://www.kernel.org/doc/html/late...m/cpufreq.html

273 10-18-2022 08:40 AM

In a nutshell: How performant a processor is depends upon it's clock speed (how many things it can do per second) and the number of clock cycles (things it does) one instruction takes.
So, say a processor is working at two cycles per second 2Hz and the operation of adding two numbers together takes two clock cycles - that CPU will only be that same speed, in reality, as one which is working at 1Hz but can add in one clock cycle.
Modern processors of the x86 variety actually do more that just simple arithmetic per clock cycle and how much they can do per clock cycle is a big factor in how well they actually perform.

Ansen 10-18-2022 10:23 PM

In Linux Source Code, especially intel_pstate.c, to adjuest cpu's with Performance value, frequency value or pstate value.
So how to know when to choice, when I want to adjuest cpu's?

pan64 10-19-2022 12:59 AM

what kind of file is this intel_pstate.c ? where is it from? Does it have some documentation?

Ansen 10-19-2022 01:24 AM

https://elixir.bootlin.com/linux/lat...intel_pstate.c

I read this file written by C language. I don't know the different between them, and how to choise one for cpu.

dugan 10-19-2022 08:52 AM

Quote:

Originally Posted by Ansen (Post 6386927)
There are two concepts in cpufreq framework:
1. performance
2. frequency

But only the frequency is the real variable to adjust the cpu's.
What is different between them ?

Are you asking what these words mean?

This covers it nicely:

https://en.wikipedia.org/wiki/Clock_rate

Ansen 10-19-2022 08:08 PM

frequency is the clock rate or clock speed when cpu is running.
P state is a combination of voltage and frequency.
But I don't know how to understand performance. The performance is an alias for Pstate?

pan64 10-19-2022 11:53 PM

https://en.wikipedia.org/wiki/Computer_performance

Ansen 10-20-2022 08:15 PM

Thanks All for answers.
According to the documents you have provided and analyzing source code of Linux, I think Performance is a mathematical abstraction and an intermediate variable used for calculating.

dugan 10-22-2022 04:39 PM

Quote:

Originally Posted by Ansen (Post 6387289)
The performance is an alias for Pstate?

The P in p-state is not short for performance. It's short for power. Power as in the electricity that gets used by the CPU.

My understanding of how these relate is the common one: that as power and frequency increase, "performance" (see the Wikipedia article above for the definition) also increases.

Ansen 10-25-2022 02:58 AM

14.2
P-STATE HARDWARE COORDINATION
The Advanced Configuration and Power Interface (ACPI) defines performance states (P-states) that are used to
facilitate system software’s ability to manage processor power consumption. Different P-states correspond to
different performance levels that are applied while the processor is actively executing instructions. Enhanced Intel
SpeedStep Technology supports P-states by providing software interfaces that control the operating frequency and
voltage of a processor.

That copied from "Intel 64 and IA-32 Architectures Software Developer's Manual".
It's to metion: performance states (P-states)

zeebra 10-26-2022 07:42 AM

Quote:

Originally Posted by Ansen (Post 6387077)
In Linux Source Code, especially intel_pstate.c, to adjuest cpu's with Performance value, frequency value or pstate value.
So how to know when to choice, when I want to adjuest cpu's?

Screw Intel_Pstate.. Add
Code:

intel_pstate=disable
to your bootline, and it will use acpi-cpufreq driver instead. With this driver you can do alot more with your cpufreq and frequency scaling in general.


All times are GMT -5. The time now is 10:00 PM.