When enabling Turbo mode on the CPU, the operating frequency fluctuates with changes of the workload. I observed through the turbostat command that each core has a different frequency during operation.
Interestingly, even in the case of hyper-threading, the frequencies of the two logical cores belonging to the same physical core are also different. Considering that both logical cores are based on the same physical core, why do they have different operating frequencies?
Furthermore, in Intel CPUs, there is a concept of "turbo level" for AVX instructions, where lvl1/2 instructions can cause the CPU to work under lower frequency. Does this behavior affect the frequency of the other logical core on the same physical core?
That's not physically possible. It probably changed frequencies between your observations.
"Physical core" isn't an abstraction, there literally is one physical core (that executes the instructions of a pair of logical cores), and it has a specific clock speed and voltage at any given time.
Changing frequency involves pausing the clock for a few microseconds while the new voltage and/or frequency stabilize. (Lost Cycles on Intel? An inconsistency between rdtsc and CPU_CLK_UNHALTED.REF_TSC). (And yes, changing voltage at the same frequency can be necessary for 256-bit or 512-bit instructions, to give some headroom for the greater swings in voltage from the potentially more highly varying currents drawn by SIMD multipliers being idle or not in a given cycle.)
So yes, wide SIMD instructions lowering the frequency of a core will affect both logical cores. But probably not other physical cores; at least for turbo above the "base" speed, even desktop / laptop CPUs should be able to independently change clocks.
For speeds below the rated speed, Intel client CPUs (not server) generally do run all cores at the same speed, so an infinite loop on one core can be sufficient to stop another core from down-clocking below the base frequency even if they otherwise would on memory-bound workloads with EPP =
balance_performanceor less (notperformance). Slowing down CPU Frequency by imposing memory stress