Skip to content

Commit e5a5f1f

Browse files
committed
perf: Remove leftover useless options to record trace events from scripts
-f, -c 1, -R are now useless for trace events recording, moreover -M is useless and event hurts. Remove them from the documentation examples and from record scripts. Signed-off-by: Frederic Weisbecker <fweisbec@gmail.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Paul Mackerras <paulus@samba.org> Cc: Tom Zanussi <tzanussi@gmail.com>
1 parent bc4b473 commit e5a5f1f

13 files changed

Lines changed: 17 additions & 21 deletions

‎tools/perf/Documentation/perf-trace-perl.txt‎

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,12 +49,10 @@ available as calls back into the perf executable (see below).
4949
As an example, the following perf record command can be used to record
5050
all sched_wakeup events in the system:
5151

52-
# perf record -c 1 -f -a -M -R -e sched:sched_wakeup
52+
# perf record -a -e sched:sched_wakeup
5353

5454
Traces meant to be processed using a script should be recorded with
55-
the above options: -c 1 says to sample every event, -a to enable
56-
system-wide collection, -M to multiplex the output, and -R to collect
57-
raw samples.
55+
the above option: -a to enable system-wide collection.
5856

5957
The format file for the sched_wakep event defines the following fields
6058
(see /sys/kernel/debug/tracing/events/sched/sched_wakeup/format):

‎tools/perf/Documentation/perf-trace-python.txt‎

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ don't care how it exited, so we'll use 'perf record' to record only
9393
the sys_enter events:
9494

9595
----
96-
# perf record -c 1 -f -a -M -R -e raw_syscalls:sys_enter
96+
# perf record -a -e raw_syscalls:sys_enter
9797

9898
^C[ perf record: Woken up 1 times to write data ]
9999
[ perf record: Captured and wrote 56.545 MB perf.data (~2470503 samples) ]
@@ -359,7 +359,7 @@ your script:
359359
# cat kernel-source/tools/perf/scripts/python/bin/syscall-counts-record
360360

361361
#!/bin/bash
362-
perf record -c 1 -f -a -M -R -e raw_syscalls:sys_enter
362+
perf record -a -e raw_syscalls:sys_enter
363363
----
364364

365365
The 'report' script is also a shell script with the same base name as
@@ -449,12 +449,10 @@ available as calls back into the perf executable (see below).
449449
As an example, the following perf record command can be used to record
450450
all sched_wakeup events in the system:
451451

452-
# perf record -c 1 -f -a -M -R -e sched:sched_wakeup
452+
# perf record -a -e sched:sched_wakeup
453453

454454
Traces meant to be processed using a script should be recorded with
455-
the above options: -c 1 says to sample every event, -a to enable
456-
system-wide collection, -M to multiplex the output, and -R to collect
457-
raw samples.
455+
the above option: -a to enable system-wide collection.
458456

459457
The format file for the sched_wakep event defines the following fields
460458
(see /sys/kernel/debug/tracing/events/sched/sched_wakeup/format):
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
#!/bin/bash
2-
perf record -c 1 -f -a -M -R -e kmem:kmalloc -e irq:softirq_entry -e kmem:kfree
2+
perf record -a -e kmem:kmalloc -e irq:softirq_entry -e kmem:kfree
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
#!/bin/bash
2-
perf record -c 1 -f -a -M -R -e raw_syscalls:sys_exit $@
2+
perf record -a -e raw_syscalls:sys_exit $@
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
#!/bin/bash
2-
perf record -c 1 -f -a -M -R -e syscalls:sys_enter_read -e syscalls:sys_enter_write $@
2+
perf record -a -e syscalls:sys_enter_read -e syscalls:sys_enter_write $@
33

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
#!/bin/bash
2-
perf record -c 1 -f -a -M -R -e syscalls:sys_enter_read -e syscalls:sys_exit_read -e syscalls:sys_enter_write -e syscalls:sys_exit_write $@
2+
perf record -a -e syscalls:sys_enter_read -e syscalls:sys_exit_read -e syscalls:sys_enter_write -e syscalls:sys_exit_write $@
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
#!/bin/bash
2-
perf record -c 1 -f -a -M -R -e syscalls:sys_enter_read -e syscalls:sys_exit_read -e syscalls:sys_enter_write -e syscalls:sys_exit_write $@
2+
perf record -a -e syscalls:sys_enter_read -e syscalls:sys_exit_read -e syscalls:sys_enter_write -e syscalls:sys_exit_write $@

‎tools/perf/scripts/perl/bin/wakeup-latency-record‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#!/bin/bash
2-
perf record -c 1 -f -a -M -R -e sched:sched_switch -e sched:sched_wakeup $@
2+
perf record -a -e sched:sched_switch -e sched:sched_wakeup $@
33

44

55

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
#!/bin/bash
2-
perf record -c 1 -f -a -M -R -e workqueue:workqueue_creation -e workqueue:workqueue_destruction -e workqueue:workqueue_execution -e workqueue:workqueue_insertion $@
2+
perf record -a -e workqueue:workqueue_creation -e workqueue:workqueue_destruction -e workqueue:workqueue_execution -e workqueue:workqueue_insertion $@
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
#!/bin/bash
2-
perf record -c 1 -f -a -M -R -e raw_syscalls:sys_exit $@
2+
perf record -a -e raw_syscalls:sys_exit $@

0 commit comments

Comments
 (0)