lkml.org 
[lkml]   [2024]   [Apr]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [RFC PATCH 39/41] KVM: x86/pmu: Implement emulated counter increment for passthrough PMU
From
On Thu, Apr 11, 2024, Sean Christopherson wrote:
> > + struct kvm_pmu *pmu = vcpu_to_pmu(vcpu);
> > + int bit;
> > +
> > + for_each_set_bit(bit, pmu->incremented_pmc_idx, X86_PMC_IDX_MAX) {
>
> I don't love the "incremented_pmc_idx" name. It's specifically for emulated
> events, that should ideally be clear in the name.
>
> And does the tracking the emulated counters actually buy anything? Iterating
> over all PMCs and checking emulated_counter doesn't seem like it'd be measurably
> slow, especially not when this path is likely writing multiple MSRs.
>
> Wait, why use that and not reprogram_pmi?

If the name is a sticking point, just rename it to something generic, e.g.
dirty_pmcs or something.

\
 
 \ /
  Last update: 2024-05-27 16:36    [W:0.180 / U:0.048 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site