Skip to content

Commit 95ad526

Browse files
danobianakryiko
authored andcommitted
veristat: Document verifier log dumping capability
`-vl2` is a useful combination of flags to dump the entire verification log. This is helpful when making changes to the verifier, as you can see what it thinks program one instruction at a time. This was more or less a hidden feature before. Document it so others can discover it. Signed-off-by: Daniel Xu <[email protected]> Signed-off-by: Andrii Nakryiko <[email protected]> Link: https://lore.kernel.org/bpf/d57bbcca81e06ae8dcdadaedb99a48dced67e422.1736466129.git.dxu@dxuuu.xyz
1 parent defac89 commit 95ad526

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

tools/testing/selftests/bpf/veristat.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,8 @@ const char argp_program_doc[] =
216216
"\n"
217217
"USAGE: veristat <obj-file> [<obj-file>...]\n"
218218
" OR: veristat -C <baseline.csv> <comparison.csv>\n"
219-
" OR: veristat -R <results.csv>\n";
219+
" OR: veristat -R <results.csv>\n"
220+
" OR: veristat -vl2 <to_analyze.bpf.o>\n";
220221

221222
enum {
222223
OPT_LOG_FIXED = 1000,
@@ -228,7 +229,7 @@ static const struct argp_option opts[] = {
228229
{ "version", 'V', NULL, 0, "Print version" },
229230
{ "verbose", 'v', NULL, 0, "Verbose mode" },
230231
{ "debug", 'd', NULL, 0, "Debug mode (turns on libbpf debug logging)" },
231-
{ "log-level", 'l', "LEVEL", 0, "Verifier log level (default 0 for normal mode, 1 for verbose mode)" },
232+
{ "log-level", 'l', "LEVEL", 0, "Verifier log level (default 0 for normal mode, 1 for verbose mode, 2 for full verification log)" },
232233
{ "log-fixed", OPT_LOG_FIXED, NULL, 0, "Disable verifier log rotation" },
233234
{ "log-size", OPT_LOG_SIZE, "BYTES", 0, "Customize verifier log size (default to 16MB)" },
234235
{ "top-n", 'n', "N", 0, "Emit only up to first N results." },

0 commit comments

Comments
 (0)