Re: [PATCH v4 6/6] KVM: selftests: Add svm_pmu_host_guest_test for Host-Only/Guest-Only bits

Jim Mattson
2026-04-07T03:23:32Z

On Mon, Apr 6, 2026 at 6:39 PM Sean Christopherson <seanjc@google.com> wrote:

> A blurb in the changelog explaining why _this_ test needs to honor alignment
> while we've managed to squeak by without problems in other tests would also be
> helpful

read_counters() induces the compiler to generate a movdqa instruction
referencing L2's stack, so the stack pointer at entry to
l2_guest_code() must not be 16-byte aligned. (Odd 8-byte alignment?)

Presumably, we've squeaked by without problems in other tests, because
no L2 instructions have required 16-byte (or greater) stack alignment.