Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751757AbdFOUCI (ORCPT ); Thu, 15 Jun 2017 16:02:08 -0400 Received: from mga01.intel.com ([192.55.52.88]:54467 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750749AbdFOUCG (ORCPT ); Thu, 15 Jun 2017 16:02:06 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.39,344,1493708400"; d="scan'208";a="1141689343" Date: Thu, 15 Jun 2017 13:02:05 -0700 From: Andi Kleen To: Stephane Eranian Cc: LKML , Arnaldo Carvalho de Melo , Peter Zijlstra , "mingo@elte.hu" , "Liang, Kan" , Jiri Olsa Subject: Re: [PATCH 0/5] perf: add support for capturing skid IP Message-ID: <20170615200205.GC4789@tassilo.jf.intel.com> References: <1497534989-29231-1-git-send-email-eranian@google.com> <20170615151018.GA4789@tassilo.jf.intel.com> <20170615172320.GB4789@tassilo.jf.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.8.0 (2017-02-23) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1409 Lines: 33 On Thu, Jun 15, 2017 at 12:35:39PM -0700, Stephane Eranian wrote: > On Thu, Jun 15, 2017 at 10:23 AM, Andi Kleen wrote: > > On Thu, Jun 15, 2017 at 09:44:07AM -0700, Stephane Eranian wrote: > >> On Thu, Jun 15, 2017 at 8:10 AM, Andi Kleen wrote: > >> > On Thu, Jun 15, 2017 at 06:56:24AM -0700, Stephane Eranian wrote: > >> >> This patchs adds a new sample record type called > >> >> PERF_SAMPLE_SKID_IP. The goal is to record > >> >> the unmodified interrupted instruction pointer (IP) as seen by > >> >> the kernel and reflected in the machine state. > >> > > >> > Patches look reasonable for me. > >> > > >> > If you only cared about branches it would be more natural to model > >> > it like a 1 entry LBR. That would make a lot more tooling work > >> > automatically. > >> > > >> You'd still have to modify tooling to present correct column headers. > > > > Why? It's from/to? > > > Ah, yes you are right, but it is not clear to me how you would specify > this cleanly with the interface. > Especially in the case where this could be used for non-branch instructions. Generally the skid ip is only interesting for instructions that have some kind of control flow change, or an exception/interrupt. So if it's interesting the headers would be correct. Actually it's even correct for non control flow change, because the IP moves from "FROM" to "TO" ... -Andi