GitHub
github.com › torvalds › linux › blob › master › tools › perf › tests › perf-record.c
linux/tools/perf/tests/perf-record.c at master · torvalds/linux
#include <perf/mmap.h> #include "event.h" #include "evlist.h" #include "evsel.h" #include "debug.h" #include "record.h" #include "tests.h" #include "util/mmap.h" #include "util/sample.h" #include "util/cpumap.h" · static int sched__get_first_possible_cpu(pid_t pid, cpu_set_t *maskp) { int i, cpu = -1; int nrcpus = cpu__max_cpu().cpu; size_t size = CPU_ALLOC_SIZE(nrcpus); ·
Author torvalds
GitHub
github.com › torvalds › linux › blob › master › tools › perf › Documentation › perf-record.txt
linux/tools/perf/Documentation/perf-record.txt at master · torvalds/linux
Record build-id of all DSOs regardless whether it's actually hit or not. ... Use <n> control blocks in asynchronous (Posix AIO) trace writing mode (default: 1, max: 4). Asynchronous mode is supported only when linking Perf tool with libc library
Author torvalds
Videos
02:58
How to Use Perf Performance Analysis Tool on Ubuntu 22.04 - YouTube
44:55
Linux perf tool metrics - Ian Rogers - YouTube
06:03
Demystifying Perf - YouTube
06:45
Linux perf Tutorial: Profiling User-Space Apps with DWARF Debug ...
12:33
Fastware - perf - How to analyse the performance of my program! ...
GitHub
github.com › zyedidia › perforator
GitHub - zyedidia/perforator: Record "perf" performance metrics for individual functions/regions of an ELF binary.
January 17, 2021 - Record "perf" performance metrics for individual functions/regions of an ELF binary. - zyedidia/perforator
Starred by 81 users
Forked by 5 users
Languages Go 97.7% | Makefile 1.3% | C 1.0% | Go 97.7% | Makefile 1.3% | C 1.0%
Perfwiki
perfwiki.github.io › main › tutorial
Introduction - perf: Linux profiling with performance counters
The perf tool can be used to collect profiles on per-thread, per-process and per-cpu basis. There are several commands associated with sampling: record, report, annotate. You must first collect the samples using perf record. This generates an output file called perf.data.
GitHub
github.com › brendangregg › Misc › blob › master › perf_events › perf.md
Misc/perf_events/perf.md at master · brendangregg/Misc
# Listing all currently known events: perf list # CPU counter statistics for the entire system, for 5 seconds: perf stat -a sleep 5 # Count ext4 events for the entire system, for 10 seconds: perf stat -e 'ext4:*' -a sleep 10 # Show system calls by process, refreshing every 2 seconds: perf top -e raw_syscalls:sys_enter -ns comm # Sample CPU stack traces for the specified PID, at 99 Hertz, for 10 seconds: perf record -F 99 -p PID -g -- sleep 10 # Sample CPU stack traces for the entire system, at 99 Hertz, for 10 seconds: perf record -F 99 -ag -- sleep 10 # Sample CPUs at 49 Hertz, and show top addresses and symbols, live (no perf.data): perf top -F 49 # Show perf.data in an ncurses browser (TUI) if possible: perf report # Show perf.data file as a text report with a sample count column: perf report -n --stdi # List all raw events from perf.data: perf script
Author brendangregg
Perfwiki
perfwiki.github.io
perf: Linux profiling with performance counters
We cannot provide a description for this page right now
GitHub
github.com › jmuehlig › perf-cpp
GitHub - jmuehlig/perf-cpp: Lightweight recording and sampling of performance counters for specific code segments directly from your C++ application. · GitHub
Lightweight recording and sampling of performance counters for specific code segments directly from your C++ application. - jmuehlig/perf-cpp
Starred by 184 users
Forked by 19 users
Languages C++ 97.5% | Python 1.1%
GitHub
github.com › RKMlab › perf
GitHub - RKMlab/perf: PERF is an Exhaustive Repeat Finder · GitHub
If the input filename does not have any extension, _perf.tsv will be appended to the filename. Please note that even in the case of no identified SSRs, the output file is still created (therefore overwriting any previous file of the same name) but with no content in the file. The output is a tab-delimited file, with one SSR record ...
Starred by 33 users
Forked by 11 users
Languages HTML
GitHub
github.com › KDAB › hotspot
GitHub - KDAB/hotspot: The Linux perf GUI for performance analysis. · GitHub
To do off-CPU analysis with Hotspot, you need to record the data with a very specific command: perf record \ -e cycles \ # on-CPU profiling -e sched:sched_switch --switch-events \ # off-CPU profiling --sample-cpu \ # track on which core code is executed -m 8M \ # reduce chance of event loss --aio -z \ # reduce disk-I/O overhead and data size --call-graph dwarf \ # we definitely want backtraces <your application>
Starred by 5.1K users
Forked by 287 users
Languages C++ 92.1% | CMake 3.4% | Python 1.4% | Shell 1.3% | Dockerfile 1.1% | C 0.7%
Perfwiki
perfwiki.github.io › main › todo
Todo - perf: Linux profiling with performance counters
Use Kconfig to allow selecting features and build minimal version of perf, e.g. one with just 'record' for use in embedded platforms.
Brendan Gregg
brendangregg.com › perf.html
Linux perf Examples
perf_events is part of the Linux kernel, under tools/perf. While it uses many Linux tracing features, some are not yet exposed via the perf command, and need to be used via the ftrace interface instead. My perf-tools collection (github) uses both perf_events and ftrace as needed.
GitHub
github.com › tuxology › tracevizlab › tree › master › labs › 005-record-kernel-trace-perf
tracevizlab/labs/005-record-kernel-trace-perf at master · tuxology/tracevizlab
$ sudo perf record -a -e sched:sched_switch -e sched:sched_waking \ -e sched:sched_pi_setprio -e sched:sched_process_fork -e sched:sched_process_exit \ -e sched:sched_process_free -e sched:sched_wakeup \ -e irq:softirq_entry -e irq:softirq_raise -e irq:softirq_exit \ -e irq:irq_handler_entry -e irq:irq_handler_exit \ -e block:block_rq_complete -e block:block_rq_insert -e block:block_rq_issue \ -e block:block_bio_frontmerge -e power:cpu_frequency \ -e net:net_dev_queue -e net:netif_receive_skb \ -e timer:hrtimer_start -e timer:hrtimer_cancel -e timer:hrtimer_expire_entry -e timer:hrtimer_expire_exit \ -e syscalls:sys_enter_* -e syscalls:sys_exit_* \ wget https://lttng.org
Author tuxology
Johannst
johannst.github.io › notes › trace_profile › perf.html
perf - Notes
record stats for running process -o <file> .............. write output to file (default perf.data) -F <hz> ................ sampling frequency --call-graph <method> ..
Iv-m
iv-m.github.io › notes › perf
perf_events notes - iv goes technical
perf record -- node --perf-basic-prof --print-code --redirect-code-traces /tmp/fib.js perf report --objdump=$HOME/src/chr/v8/tools/objdump-v8
GitHub
github.com › torvalds › linux › blob › master › tools › perf › perf.c
linux/tools/perf/perf.c at master · torvalds/linux
* perf top, perf record, perf report, etc.) are started. */ #include "builtin.h" #include "perf.h" · #include "util/build-id.h" #include "util/cache.h" #include "util/env.h" #include <internal/lib.h> // page_size ·
Author torvalds
GitHub
github.com › westerndigitalcorporation › RISC-V-Linux › blob › master › linux › tools › perf › Documentation › perf-record.txt
RISC-V-Linux/linux/tools/perf/Documentation/perf-record.txt at master · westerndigitalcorporation/RISC-V-Linux
This repository provides a Linux kernel bootable on RISC-V boards from SiFive - RISC-V-Linux/linux/tools/perf/Documentation/perf-record.txt at master · westerndigitalcorporation/RISC-V-Linux
Author westerndigitalcorporation
GitHub
gist.github.com › hrwgc › 9750190
perf-guide.md · GitHub
To isolate profiling to a single process or program use perf record.
GitHub
gist.github.com › trevnorris › f0907b010c9d5e24ea97
Here's a rundown of everything I use to do performance analysis in Node. · GitHub
$ perf record -e cycles:u -g -- ./node benchmark/http_simple.js
GitHub
github.com › aayasin › perf-tools
GitHub - aayasin/perf-tools: A collection of performance analysis tools, recipes, handy scripts, microbenchmarks & more · GitHub
lbr/ -- functionality for processing Last Branch Record (LBR) streams ... mmm/ -- the matrix-matrix mutiply (mmm) HPC kernel - multiple optimizations as demonstrated in Tuning Performance via Metrics with Expectations
Starred by 146 users
Forked by 25 users
Languages Python 83.6% | C 7.4% | Makefile 4.4% | Shell 3.1%