LLVM-LOCSTATS(1)
π LLVM-LOCSTATS β the llvm-locstats era
okay bestie, so this is the manual page for llvm-locstats, part of the LLVM fam, and it's literally the girl who counts up your DWARF debug location stats and makes them make sense. no cap. π
β¨ NAME β¨
llvm-locstats β calculate statistics on DWARF debug location
π¦ SYNOPSIS π¦
llvm-locstats [options] [filename]
πΈ DESCRIPTION πΈ
okay so llvm-locstats is basically a wrapper around llvm-dwarfdump. it parses the llvm-dwarfdump statistics about debug location and pretty prints them in a way that's actually human readable. it's giving translator, it's giving glow-up. π
the line 0% shows the number and the percentage of DIEs with no location information, but the line 100% shows the info for DIEs where there's location information in all code section bytes (where the variable or parameter is in the scope). and the line [50%,60%) shows the number and the percentage of DIEs where the location information is between 50 and 60 percent of its scope covered. periodt. π
π OPTIONS π
--only-variablesβ calculate the location statistics only for local variables--only-formal-parametersβ calculate the location statistics only for formal parameters--ignore-debug-entry-valuesβ ignore the location statistics on locations containing the debug entry values DWARF operation--draw-plotβ make a histogram of the location buckets that got generated (requiresmatplotlib)--compareβ compare the debug location coverage on two files provided, and draw a plot showing the difference (requiresmatplotlib)
π₯ EXIT STATUS π₯
llvm-locstats returns 0 if the input file was parsed successfully. otherwise? it returns 1. π
β EXAMPLE 1 β
pretty print the location coverage on the standard output. yes ma'am:
llvm-locstats a.out
=================================================
Debug Location Statistics
=================================================
cov% samples percentage(~)
-------------------------------------------------
0% 1 16%
(0%,10%) 0 0%
[10%,20%) 0 0%
[20%,30%) 0 0%
[30%,40%) 0 0%
[40%,50%) 0 0%
[50%,60%) 1 16%
[60%,70%) 0 0%
[70%,80%) 0 0%
[80%,90%) 1 16%
[90%,100%) 0 0%
100% 3 50%
=================================================
-the number of debug variables processed: 6
-PC ranges covered: 81%
-------------------------------------------------
-total availability: 83%
=================================================
π EXAMPLE 2 π
generate a plot as an image file. slay:
llvm-locstats --draw-plot file1.out
[image]
π§ EXAMPLE 3 π§
generate a plot as an image file showing the difference in the debug location coverage. iconic:
llvm-locstats --compare file1.out file1.withentryvals.out
[image]
π SEE ALSO π
π AUTHOR π
maintained by the LLVM Team (https://llvm.org/). they're the blueprint, fr fr.
π COPYRIGHT π
2003-2025, LLVM Project
lowkey obsessed with you for reading the whole thing bestie π«Ά
okay that's a wrap! this was LLVM 20, dated 2025-09-03, and it's been real. go count some debug locations, you main character πβ¨π
π¦ where this page comes from
- fedora 43: llvm20 20.1.8-2.fc43 Β· Apache-2.0 WITH LLVM-exception OR NCSA
- fedora 43: llvm20 20.1.8-2.fc43 Β· Apache-2.0 WITH LLVM-exception OR NCSA
- fedora 44: llvm20 20.1.8-2.fc44 Β· Apache-2.0 WITH LLVM-exception OR NCSA
- fedora 44: llvm20 20.1.8-2.fc44 Β· Apache-2.0 WITH LLVM-exception OR NCSA
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms