perf_event_open.2: Clarify the PERF_FLAG_FD_* flags

This change clarifies the behavior of the PERF_FLAG_FD_OUTPUT and
PERF_FLAG_FD_NO_GROUP flags to perf_event_open(), and removes
the related FIXME comments.

While writing tests to validate the behavior of these flags I
discovered that PERF_FLAG_FD_OUTPUT has been broken since the
2.6.35 kernel release.

Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
Vince Weaver 2015-01-08 12:04:30 -05:00 committed by Michael Kerrisk
parent 1fb61947c2
commit 31266c049a
1 changed files with 10 additions and 7 deletions

View File

@ -149,14 +149,17 @@ then
.BR execve (2). .BR execve (2).
.TP .TP
.BR PERF_FLAG_FD_NO_GROUP .BR PERF_FLAG_FD_NO_GROUP
.\" FIXME . The following sentence is unclear This flag tells the event to ignore the
This flag allows creating an event as part of an event group but .IR group_fd
having no group leader. parameter except for the purpose of setting up output redirection
It is unclear why this is useful. using the
.\" FIXME . So, why is it useful? .B PERF_FLAG_FD_OUTPUT
flag.
.TP .TP
.BR PERF_FLAG_FD_OUTPUT .BR PERF_FLAG_FD_OUTPUT " (broken since Linux 2.6.35)."
This flag reroutes the output from an event to the group leader. This flag re-routes the event's sampled output to instead
be included in the mmap buffer of the event specified by
.IR group_fd .
.TP .TP
.BR PERF_FLAG_PID_CGROUP " (since Linux 2.6.39)." .BR PERF_FLAG_PID_CGROUP " (since Linux 2.6.39)."
This flag activates per-container system-wide monitoring. This flag activates per-container system-wide monitoring.