From: "Michael Kerrisk (man-pages)" <mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: Vince Weaver <vincent.weaver-e7X0jjDqjFGHXe+LvDLADg@public.gmane.org>
Cc: "Michael Kerrisk (man-pages)"
<mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
linux-man-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: perf_event_open.2: PERF_SAMPLE_BRANCH_STACK updates
Date: Fri, 13 Sep 2013 06:40:13 +0200 [thread overview]
Message-ID: <5232972D.8060102@gmail.com> (raw)
In-Reply-To: <alpine.DEB.2.10.1309091526560.10528-6xBS8L8d439fDsnSvq7Uq4Se7xf15W0s1dQoKJhdanU@public.gmane.org>
On 09.09.2013 21:32, Vince Weaver wrote:
>
> This started out as just adding the new perf_event_open features
> from Linux 3.11 (which was the addition of transactional memory
> defines for PERF_SAMPLE_BRANCH_STACK samples) but turned into a
> general cleanup of the PERF_SAMPLE_BRANCH_STACK documentation.
>
> The main clarification is that at least one of the non-privilege values
> must be set or else perf_event_open will return an EINVAL error.
Thanks, Vince. Applied.
Cheers,
Michael
> Signed-off-by: Vince Weaver <vincent.weaver-e7X0jjDqjFGHXe+LvDLADg@public.gmane.org>
>
> diff --git a/man2/perf_event_open.2 b/man2/perf_event_open.2
> index f96df8c..b2604c4 100644
> --- a/man2/perf_event_open.2
> +++ b/man2/perf_event_open.2
> @@ -969,13 +969,12 @@ If
> .B PERF_SAMPLE_BRANCH_STACK
> is enabled, then this specifies what branches to include
> in the branch record.
> +
> +The first part of the value is the privilege level, which
> +is a combination of one of the following values.
> If the user does not set privilege level explicitly, the kernel
> will use the event's privilege level.
> Event and branch privilege levels do not have to match.
> -The value is formed by ORing together zero or more of the following values,
> -although
> -.B PERF_SAMPLE_BRANCH_ANY
> -covers all branch types.
> .RS
> .TP
> .B PERF_SAMPLE_BRANCH_USER
> @@ -987,8 +986,16 @@ Branch target is in kernel space
> .B PERF_SAMPLE_BRANCH_HV
> Branch target is in hypervisor
> .TP
> +.B PERF_SAMPLE_BRANCH_PLM_ALL
> +A convenience value that is the three preceding values ORed together.
> +
> +.P
> +In addition to the privilege value, at least one or more of the
> +following bits must be set.
> +
> +.TP
> .B PERF_SAMPLE_BRANCH_ANY
> -Any branch type.
> +Any branch type
> .TP
> .B PERF_SAMPLE_BRANCH_ANY_CALL
> Any call branch
> @@ -996,12 +1003,19 @@ Any call branch
> .B PERF_SAMPLE_BRANCH_ANY_RETURN
> Any return branch
> .TP
> -.BR PERF_SAMPLE_BRANCH_IND_CALL
> +.B PERF_SAMPLE_BRANCH_IND_CALL
> Indirect calls
> .TP
> -.BR PERF_SAMPLE_BRANCH_PLM_ALL
> -User, kernel, and hv
> +.BR PERF_SAMPLE_BRANCH_ABORT_TX " (Since Linux 3.11)"
> +Transactional memory aborts
> +.TP
> +.BR PERF_SAMPLE_BRANCH_IN_TX " (Since Linux 3.11)"
> +Branch in transactional memory transaction
> +.TP
> +.BR PERF_SAMPLE_BRANCH_NO_TX " (Since Linux 3.11)"
> +Branch not in transactional memory transaction
> .RE
> +
> .TP
> .IR "sample_regs_user" " (Since Linux 3.7)"
> This bitmask defines the set of user CPU registers to dump on samples.
> @@ -1572,8 +1586,15 @@ the branch target
> the branch target was mispredicted
> .TP
> .I predicted
> -the branch target was predicted.
> -.RE
> +the branch target was predicted
> +.TP
> +.IR in_tx " (Since Linux 3.11)"
> +the branch was in a transactional memory transaction
> +.TP
> +.IR abort " (Since Linux 3.11)"
> +the branch was in an aborted transactional memory transaction.
> +
> +.P
> The entries are from most to least recent, so the first entry
> has the most recent branch.
>
> @@ -1584,6 +1605,11 @@ and
> is optional; if not supported, both
> values will be 0.
>
> +The type of branches recorded is specified by the
> +.I branch_sample_type
> +field.
> +.RE
> +
> .TP
> .IR abi ", " regs[weight(mask)]
> If
>
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
prev parent reply other threads:[~2013-09-13 4:40 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-09 19:32 perf_event_open.2: PERF_SAMPLE_BRANCH_STACK updates Vince Weaver
[not found] ` <alpine.DEB.2.10.1309091526560.10528-6xBS8L8d439fDsnSvq7Uq4Se7xf15W0s1dQoKJhdanU@public.gmane.org>
2013-09-13 4:40 ` Michael Kerrisk (man-pages) [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5232972D.8060102@gmail.com \
--to=mtk.manpages-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
--cc=linux-man-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=vincent.weaver-e7X0jjDqjFGHXe+LvDLADg@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.