Re: [PATCH 06/34] perf, kvm: Support the intx/intx_cp modifiers in KVM arch perfmon emulation v2

2012-10-23 Thread Andi Kleen
On Tue, Oct 23, 2012 at 03:35:27PM +0200, Andi Kleen wrote: > > So I forgot how all this worked, but will the KVM emulation not pass > > this straight down to the hardware? > > Pass down to perf. > > > > > Don't we have a problem where we're emulating arch perfmon v1 on AMD > > hardware? On

Re: [PATCH 06/34] perf, kvm: Support the intx/intx_cp modifiers in KVM arch perfmon emulation v2

2012-10-23 Thread Andi Kleen
> So I forgot how all this worked, but will the KVM emulation not pass > this straight down to the hardware? Pass down to perf. > > Don't we have a problem where we're emulating arch perfmon v1 on AMD > hardware? On AMD hardware those bits do have meaning. Ah they do? I wasn't aware. I can

Re: [PATCH 06/34] perf, kvm: Support the intx/intx_cp modifiers in KVM arch perfmon emulation v2

2012-10-23 Thread Gleb Natapov
On Tue, Oct 23, 2012 at 02:36:05PM +0200, Peter Zijlstra wrote: > On Thu, 2012-10-18 at 16:19 -0700, Andi Kleen wrote: > > From: Andi Kleen > > > > This is not arch perfmon, but older CPUs will just ignore it. This makes > > it possible to do at least some TSX measurements from a KVM guest > >

Re: [PATCH 06/34] perf, kvm: Support the intx/intx_cp modifiers in KVM arch perfmon emulation v2

2012-10-23 Thread Peter Zijlstra
On Thu, 2012-10-18 at 16:19 -0700, Andi Kleen wrote: > From: Andi Kleen > > This is not arch perfmon, but older CPUs will just ignore it. This makes > it possible to do at least some TSX measurements from a KVM guest Please, always CC people who wrote the code as well, in this case that's Gleb.

Re: [PATCH 06/34] perf, kvm: Support the intx/intx_cp modifiers in KVM arch perfmon emulation v2

2012-10-23 Thread Peter Zijlstra
On Thu, 2012-10-18 at 16:19 -0700, Andi Kleen wrote: From: Andi Kleen a...@linux.intel.com This is not arch perfmon, but older CPUs will just ignore it. This makes it possible to do at least some TSX measurements from a KVM guest Please, always CC people who wrote the code as well, in this

Re: [PATCH 06/34] perf, kvm: Support the intx/intx_cp modifiers in KVM arch perfmon emulation v2

2012-10-23 Thread Gleb Natapov
On Tue, Oct 23, 2012 at 02:36:05PM +0200, Peter Zijlstra wrote: On Thu, 2012-10-18 at 16:19 -0700, Andi Kleen wrote: From: Andi Kleen a...@linux.intel.com This is not arch perfmon, but older CPUs will just ignore it. This makes it possible to do at least some TSX measurements from a KVM

Re: [PATCH 06/34] perf, kvm: Support the intx/intx_cp modifiers in KVM arch perfmon emulation v2

2012-10-23 Thread Andi Kleen
So I forgot how all this worked, but will the KVM emulation not pass this straight down to the hardware? Pass down to perf. Don't we have a problem where we're emulating arch perfmon v1 on AMD hardware? On AMD hardware those bits do have meaning. Ah they do? I wasn't aware. I can add a

Re: [PATCH 06/34] perf, kvm: Support the intx/intx_cp modifiers in KVM arch perfmon emulation v2

2012-10-23 Thread Andi Kleen
On Tue, Oct 23, 2012 at 03:35:27PM +0200, Andi Kleen wrote: So I forgot how all this worked, but will the KVM emulation not pass this straight down to the hardware? Pass down to perf. Don't we have a problem where we're emulating arch perfmon v1 on AMD hardware? On AMD hardware

[PATCH 06/34] perf, kvm: Support the intx/intx_cp modifiers in KVM arch perfmon emulation v2

2012-10-18 Thread Andi Kleen
From: Andi Kleen This is not arch perfmon, but older CPUs will just ignore it. This makes it possible to do at least some TSX measurements from a KVM guest Cc: a...@redhat.com v2: Various fixes to address review feedback Signed-off-by: Andi Kleen --- arch/x86/kvm/pmu.c | 15 +++

[PATCH 06/34] perf, kvm: Support the intx/intx_cp modifiers in KVM arch perfmon emulation v2

2012-10-18 Thread Andi Kleen
From: Andi Kleen a...@linux.intel.com This is not arch perfmon, but older CPUs will just ignore it. This makes it possible to do at least some TSX measurements from a KVM guest Cc: a...@redhat.com v2: Various fixes to address review feedback Signed-off-by: Andi Kleen a...@linux.intel.com ---