Re: [PATCH v3 3/5] KVM: selftests: Add helpers for PMC asserts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Same issue on this one, it's not obvious that the helper is being added to a single
test.

On Tue, Mar 07, 2023, Aaron Lewis wrote:
> Add the helpers, ASSERT_PMC_COUNTING and ASSERT_PMC_NOT_COUNTING, to
> split out the asserts into one place.  This will make it easier to add
> additional asserts related to counting later on.
> 
> No functional changes intended.
> 
> Signed-off-by: Aaron Lewis <aaronlewis@xxxxxxxxxx>
> ---
>  .../kvm/x86_64/pmu_event_filter_test.c        | 70 ++++++++++---------
>  1 file changed, 36 insertions(+), 34 deletions(-)
> 
> diff --git a/tools/testing/selftests/kvm/x86_64/pmu_event_filter_test.c b/tools/testing/selftests/kvm/x86_64/pmu_event_filter_test.c
> index f33079fc552b..8277b8f49dca 100644
> --- a/tools/testing/selftests/kvm/x86_64/pmu_event_filter_test.c
> +++ b/tools/testing/selftests/kvm/x86_64/pmu_event_filter_test.c
> @@ -250,14 +250,27 @@ static struct kvm_pmu_event_filter *remove_event(struct kvm_pmu_event_filter *f,
>  	return f;
>  }
>  
> +#define ASSERT_PMC_COUNTING(count)							\

Looking at the future patches, I think it makes sense to append INSTRUCTIONS to
the name to clarify what it's counting.  That's arguably slightly misleading for
counting branch instructions, but they are still instructions...



[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux