From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753885AbbJTJg1 (ORCPT ); Tue, 20 Oct 2015 05:36:27 -0400 Received: from terminus.zytor.com ([198.137.202.10]:49872 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751448AbbJTJgZ (ORCPT ); Tue, 20 Oct 2015 05:36:25 -0400 Date: Tue, 20 Oct 2015 02:35:47 -0700 From: tip-bot for Stephane Eranian Message-ID: Cc: peterz@infradead.org, torvalds@linux-foundation.org, acme@redhat.com, vincent.weaver@maine.edu, linux-kernel@vger.kernel.org, tglx@linutronix.de, dsahern@gmail.com, jolsa@redhat.com, mingo@kernel.org, namhyung@kernel.org, eranian@google.com, hpa@zytor.com Reply-To: dsahern@gmail.com, tglx@linutronix.de, linux-kernel@vger.kernel.org, vincent.weaver@maine.edu, acme@redhat.com, peterz@infradead.org, torvalds@linux-foundation.org, hpa@zytor.com, eranian@google.com, namhyung@kernel.org, mingo@kernel.org, jolsa@redhat.com In-Reply-To: <1444720151-10275-2-git-send-email-eranian@google.com> References: <1444720151-10275-2-git-send-email-eranian@google.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:perf/core] perf: Add PERF_SAMPLE_BRANCH_CALL Git-Commit-ID: c229bf9dc179d2023e185c0f705bdf68484c1e73 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: c229bf9dc179d2023e185c0f705bdf68484c1e73 Gitweb: http://git.kernel.org/tip/c229bf9dc179d2023e185c0f705bdf68484c1e73 Author: Stephane Eranian AuthorDate: Tue, 13 Oct 2015 09:09:08 +0200 Committer: Ingo Molnar CommitDate: Tue, 20 Oct 2015 10:30:53 +0200 perf: Add PERF_SAMPLE_BRANCH_CALL Add a new branch sample type to cover only call branches (function calls). The current ANY_CALL included direct, indirect calls and far jumps. We want to be able to differentiate indirect from direct calls. Therefore we introduce PERF_SAMPLE_BRANCH_CALL. The implementation is up to each architecture. Signed-off-by: Stephane Eranian Signed-off-by: Peter Zijlstra (Intel) Cc: Arnaldo Carvalho de Melo Cc: David Ahern Cc: Jiri Olsa Cc: Linus Torvalds Cc: Namhyung Kim Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: Vince Weaver Cc: khandual@linux.vnet.ibm.com Link: http://lkml.kernel.org/r/1444720151-10275-2-git-send-email-eranian@google.com Signed-off-by: Ingo Molnar --- include/uapi/linux/perf_event.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/uapi/linux/perf_event.h b/include/uapi/linux/perf_event.h index 6c72e72..6512213 100644 --- a/include/uapi/linux/perf_event.h +++ b/include/uapi/linux/perf_event.h @@ -168,6 +168,7 @@ enum perf_branch_sample_type_shift { PERF_SAMPLE_BRANCH_CALL_STACK_SHIFT = 11, /* call/ret stack */ PERF_SAMPLE_BRANCH_IND_JUMP_SHIFT = 12, /* indirect jumps */ + PERF_SAMPLE_BRANCH_CALL_SHIFT = 13, /* direct call */ PERF_SAMPLE_BRANCH_MAX_SHIFT /* non-ABI */ }; @@ -188,6 +189,7 @@ enum perf_branch_sample_type { PERF_SAMPLE_BRANCH_CALL_STACK = 1U << PERF_SAMPLE_BRANCH_CALL_STACK_SHIFT, PERF_SAMPLE_BRANCH_IND_JUMP = 1U << PERF_SAMPLE_BRANCH_IND_JUMP_SHIFT, + PERF_SAMPLE_BRANCH_CALL = 1U << PERF_SAMPLE_BRANCH_CALL_SHIFT, PERF_SAMPLE_BRANCH_MAX = 1U << PERF_SAMPLE_BRANCH_MAX_SHIFT, };