Hi everyone, I deployed a Windows VM on a Linux host using KVM, and the serve CPU model is AMD EPYC 9654. Then I met the following problem.
I used some CPU benchmark tools to test the performance of CPU, and I found that after enabling SMT, the single-thread performance of CPU decreased significantly.
I confirmed that there was almost no SMT contention (I turned off the SMT sibling core when testing). In addition, I also found some strange phenomena:
- The single-thread CPU performance is not changed in host whether SMT is enabled or not;
- The single-thread CPU performance is not changed in Linux VM whether SMT is enabled or not.
I used perf tool to analyze the reason (perf kvm stat command), and found the op_cache_hit_miss ratio reached 100% only in SMT+Windows VM.
I also confirmed the bit 5 MSR 0xc0011021 register is 0, so the opcache is not closed all the time.
Does anyone know what the reason is?