Skip to contentSkip to conversation

perf_event_open.2: Update description for mmap_data bit

PATCH Vince Weaver 3 participants 3 messages Nov 13, 2013 – Dec 12, 2013 3 messages not in the archive Man-pages: manual pages for Linux -- Sections 2, 3, 4, 5, and 7

lore
Share & tools
lore
#2 lore raw
In reply to a message not in the archive

Here's an updated version of the patch that expands the "mmap" definition as well as that of "mmap_data". Also some manpage related formatting improvements from the original patch.

I'm not really sure how signed-off-by's and other tags work when modifying a patch like this so sorry if I mixed that up.

---

man2/perf_event_open.2 +18 -3
index 1889689..5ba1a42 100644
@@ -805,7 +805,16 @@ If set, don't count when the CPU is idle.
 .IR "mmap"
 The
 .I mmap
-bit enables recording of exec mmap events.
+bit enables generation of
+.I PERF_RECORD_MMAP
+samples for every
+.BR mmap (2)
+call that has
+.I PROT_EXEC
+set.
+This allows tools to notice new executable code being mapped into
+a program (dynamic shared libraries for example)
+so that addresses can be mapped back to the original code.
 .TP
 .IR "comm"
 The
@@ -884,8 +893,14 @@ See also
 .IR "mmap_data" " (Since Linux 2.6.36)"
 The counterpart of the
 .I mmap
-field, but enables including data mmap events
-in the ring-buffer.
+field.
+This enables generation of
+.I PERF_RECORD_MMAP
+samples for
+.BR mmap (2)
+calls that do not have
+.I PROT_EXEC
+set (for example data and SysV shared memory).
 .TP
 .IR "sample_id_all" " (Since Linux 2.6.38)"
 If set, then TID, TIME, ID, STREAM_ID, and CPU can

--
To unsubscribe from this list: send the line "unsubscribe linux-man" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

#4 lore raw
In reply to a message not in the archive
Quoted 8 lines · Vince Weaver

Here's an updated version of the patch that expands the "mmap" definition as well as that of "mmap_data". Also some manpage related formatting improvements from the original patch.

I'm not really sure how signed-off-by's and other tags work when modifying a patch like this so sorry if I mixed that up.

I just want the documentation updated as we find holes. I'm fine with your change.

David

--
To unsubscribe from this list: send the line "unsubscribe linux-man" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html

#5 lore raw
In reply to a message not in the archive
Quoted 5 lines · Vince Weaver

Here's an updated version of the patch that expands the "mmap" definition as well as that of "mmap_data". Also some manpage related formatting improvements from the original patch.

Quoted 7 lines

I'm not really sure how signed-off-by's and other tags work when modifying a patch like this so sorry if I mixed that up.

Thanks Vince (and David). I've applied, and added an "Acked-by:" from David, since he said he was fine with your revision.

Cheers,

Michael

Quoted 42 lines

---

man2/perf_event_open.2 +18 -3
index 1889689..5ba1a42 100644
@@ -805,7 +805,16 @@ If set, don't count when the CPU is idle.
 .IR "mmap"
 The
 .I mmap
-bit enables recording of exec mmap events.
+bit enables generation of
+.I PERF_RECORD_MMAP
+samples for every
+.BR mmap (2)
+call that has
+.I PROT_EXEC
+set.
+This allows tools to notice new executable code being mapped into
+a program (dynamic shared libraries for example)
+so that addresses can be mapped back to the original code.
 .TP
 .IR "comm"
 The
@@ -884,8 +893,14 @@ See also
 .IR "mmap_data" " (Since Linux 2.6.36)"
 The counterpart of the
 .I mmap
-field, but enables including data mmap events
-in the ring-buffer.
+field.
+This enables generation of
+.I PERF_RECORD_MMAP
+samples for
+.BR mmap (2)
+calls that do not have
+.I PROT_EXEC
+set (for example data and SysV shared memory).
 .TP
 .IR "sample_id_all" " (Since Linux 2.6.38)"
 If set, then TID, TIME, ID, STREAM_ID, and CPU can
Signature · 6 lines
Michael Kerrisk
Linux man-pages maintainer; http://www.kernel.org/doc/man-pages/
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html