LLVM-LOCSTATS(1)
π NAME π
llvm-locstats β calculate statistics on DWARF debug location. This page is from the LLVM manual, and yes bestie, it is the debug-info stats icon. π
β¨
πΈ SYNOPSIS πΈ
llvm-locstats [options] [filename]
π¦ DESCRIPTION π¦
Okay so llvm-locstats works like a wrapper around llvm-dwarfdump. It parses llvm-dwarfdump statistics regarding debug location by pretty printing it in a more human readable way. The whole thing is giving debug-info glow-up, no cap. π
The line 0% shows the number and the percentage of DIEs with no location information, but the line 100% shows the information for DIEs where there is location information in all code section bytes (where the variable or parameter is in the scope). The line [50%,60%) shows the number and the percentage of DIEs where the location information is between 50 and 60 percentage of its scope covered. Literally the range midpoints are eating. π
β¨ OPTIONS β¨
--only-variablesβ calculate the location statistics only for local variables. That's the whole assignment, bestie. π--only-formal-parametersβ calculate the location statistics only for formal parameters. Same energy, different parameter moment. π¦--ignore-debug-entry-valuesβ ignore the location statistics on locations containing the debug entry values DWARF operation. It's a very specific vibe check, iykyk. π--draw-plotβ make histogram of location buckets generated. It requiresmatplotlib, so that's a whole dependency situation. πΈ--compareβ compare the debug location coverage on two files provided, and draw a plot showing the difference. Also requiresmatplotlib. π
π EXIT STATUS π
llvm-locstats returns 0 if the input file were parsed successfully. Otherwise, it returns 1. Binary mood, fr fr. π
π₯ EXAMPLE 1 π₯
Pretty print the location coverage on the standard output.
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.
llvm-locstats --draw-plot file1.out
[image]
π EXAMPLE 3 π
Generate a plot as an image file showing the difference in the debug location coverage.
llvm-locstats --compare file1.out file1.withentryvals.out
[image]
π«Ά SEE ALSO π«Ά
π AUTHOR π
Maintained by the LLVM Team (https://llvm.org/).
π COPYRIGHT π
2003-2023, LLVM Project
π That's the whole page, bestie β LLVM version 13, dated 2023-07-14. Catch you in the footer! π
π¦ where this page comes from
- ubuntu jammy: llvm-13 1:13.0.1-2ubuntu2.2 Β· APACHE-2-LLVM-EXCEPTIONS
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms