OVERVIEW: llvm SPGO profile generator
USAGE: llvm-profgen [options]
OPTIONS:
Color Options:
--color - Use colors in output (default=autodetect)
Generic Options:
--help - Display available options (--help-hidden for more)
--help-list - Display list of available options (--help-list-hidden for more)
--version - Display the version of this program
ProfGen Options:
--binary=<binary> - Path of profiled executable binary.
--csprof-max-cold-context-depth=<uint> - Keep the last K contexts while merging cold profile. 1 means the context-less base profile
--csprof-max-context-depth=<int> - Keep the last K contexts while merging profile. -1 means no depth limit.
--csprof-max-unsymbolized-context-depth=<int> - Keep the last K contexts while merging unsymbolized profile. -1 means no depth limit.
--csprof-merge-cold-context - If the total count of context profile is smaller than the threshold, it will be merged into context-less base profile.
--data-access-perftrace=<data-access-perftrace> - File path of a Linux perf raw trace (generated by `perf report -D`) consisting of memory access events.
--debug-binary=<debug-binary> - Path of debug info binary, llvm-profgen will load the DWARF info from it instead of the executable binary.
--disassemble-functions=<string> - List of functions to print disassembly for. Accept demangled names only. Only work with show-disassembly-only
--dwp=<string> - Path of .dwp file. When not specified, it will be <binary>.dwp in the same directory as the main binary.
--format=<value> - Format of output profile
=binary - Binary encoding (default)
=extbinary - Extensible binary encoding
=text - Text encoding
=gcc - GCC encoding (only meaningful for -sample)
--ignore-stack-samples - Ignore call stack samples for hybrid samples and produce context-insensitive profile.
--infer-missing-frames - Infer missing call frames due to compiler tail call elimination.
--kernel - Generate the profile for Linux kernel binary.
--llvm-sample-profile=<llvm sample profile> - Path of the LLVM sample profile
--load-function-from-symbol - Gather additional binary function info from symbols (e.g. .symtab) in case dwarf info is incomplete. Only support binaries in ELF format with pseudo probe, for other formats, this flag will be a no-op.
--max-search-depth=<uint> - The maximum levels the DFS-based missing frame search should go with
--output=<output> - Output profile file
--perfdata=<perfdata> - Path of raw perf data created by Linux perf tool (it should be profiled with -b)
--perfscript=<perfscript> - Path of perf-script trace created by Linux perf tool with `script` command(the raw perf.data should be profiled with -b)
--pid=<process Id> - Process Id for the profiled executable binary.
--profile-density-cutoff-hot=<int> - Total samples cutoff for functions used to calculate profile density.
--profile-density-threshold=<number> - If the profile density is below the given threshold, it will be suggested to increase the sampling rate.
--show-canonical-fname - Print canonical function name.
--show-density - show profile density details
--show-detailed-warning - Show detailed warning message.
--show-disassembly-only - Print disassembled code.
--show-mmap-events - Print binary load events.
--show-pseudo-probe - Print pseudo probe section and disassembled info.
--show-source-locations - Print source locations.
--skip-symbolization - Dump the unsymbolized profile to the output file. It will show unwinder output for CS profile generation.
--trim-cold-profile - If the total count of the profile is smaller than threshold, it will be trimmed.
--unsymbolized-profile=<unsymbolized profile> - Path of the unsymbolized profile created by `llvm-profgen` with `--skip-symbolization`
--update-total-samples - Update total samples by accumulating all its body samples.
--use-dwarf-correlation - Use dwarf for profile correlation even when binary contains pseudo probe.
--use-first-loadable-segment-as-base - Use first loadable segment address as base address for offsets in unsymbolized profile. By default first executable segment address is used
--use-offset - Work with `--skip-symbolization` or `--unsymbolized-profile` to write/read the offset instead of virtual address.
Options (39)
| Option | Description | Source |
|---|---|---|
--color | - Use colors in output (default=autodetect) | help |
--help | - Display available options (--help-hidden for more) | help |
--help-list | - Display list of available options (--help-list-hidden for more) | help |
--version | - Display the version of this program | help |
--binary binary | - Path of profiled executable binary. | help |
--csprof-max-cold-context-depth uint | - Keep the last K contexts while merging cold profile. | help |
--csprof-max-context-depth int | - Keep the last K contexts while merging profile. | help |
--csprof-max-unsymbolized-context-depth int | - Keep the last K contexts while merging unsymbolized profile. | help |
--csprof-merge-cold-context | - If the total count of context profile is smaller than the threshold, it will be merged into context-less base profile. | help |
--debug-binary debug-binary | - Path of debug info binary, llvm-profgen will load the DWARF info from it instead of the executable binary. | help |
--disassemble-functions string | - List of functions to print disassembly for. | help |
--dwp string | - Path of .dwp file. | help |
--format value | - Format of output profile =binary - Binary encoding (default) =extbinary - Extensible binary encoding =text - Text encoding =gcc - GCC encoding (only meaningful for -sample) | help |
--ignore-stack-samples | - Ignore call stack samples for hybrid samples and produce context-insensitive profile. | help |
--infer-missing-frames | - Infer missing call frames due to compiler tail call elimination. | help |
--kernel | - Generate the profile for Linux kernel binary. | help |
--llvm-sample-profile llvm | - Path of the LLVM sample profile | help |
--load-function-from-symbol | - Gather additional binary function info from symbols (e.g. .symtab) in case dwarf info is incomplete. | help |
--max-search-depth uint | - The maximum levels the DFS-based missing frame search should go with | help |
--output output | - Output profile file | help |
--perfdata perfdata | - Path of raw perf data created by Linux perf tool (it should be profiled with -b) | help |
--perfscript perfscript | - Path of perf-script trace created by Linux perf tool with `script` command(the raw perf.data should be profiled with -b) | help |
--pid process | - Process Id for the profiled executable binary. | help |
--profile-density-cutoff-hot int | - Total samples cutoff for functions used to calculate profile density. | help |
--profile-density-threshold number | - If the profile density is below the given threshold, it will be suggested to increase the sampling rate. | help |
--show-canonical-fname | - Print canonical function name. | help |
--show-density | - show profile density details | help |
--show-detailed-warning | - Show detailed warning message. | help |
--show-disassembly-only | - Print disassembled code. | help |
--show-mmap-events | - Print binary load events. | help |
--show-pseudo-probe | - Print pseudo probe section and disassembled info. | help |
--show-source-locations | - Print source locations. | help |
--skip-symbolization | - Dump the unsymbolized profile to the output file. | help |
--trim-cold-profile | - If the total count of the profile is smaller than threshold, it will be trimmed. | help |
--unsymbolized-profile unsymbolized | - Path of the unsymbolized profile created by `llvm-profgen` with `--skip-symbolization` | help |
--update-total-samples | - Update total samples by accumulating all its body samples. | help |
--use-dwarf-correlation | - Use dwarf for profile correlation even when binary contains pseudo probe. | help |
--use-first-loadable-segment-as-base | - Use first loadable segment address as base address for offsets in unsymbolized profile. | help |
--use-offset | - Work with `--skip-symbolization` or `--unsymbolized-profile` to write/read the offset instead of virtual address. | help |