Hello all, This is v2 of the series to add global variables to pahole's generated BTF. Please see v1's cover letter for more justification and background. I've incorporated Alan's feedback and added a forgotten Cc for the bpf list. Thanks, Stephen v1: https://lore.kernel.org/dwarves/20240912190827.230176-1-stephen.s.brennan@xxxxxxxxxx/ Stephen Brennan (4): dutil: return ELF section name when looked up by index dwarf_loader: add "artificial" and "top_level" variable flags btf_encoder: cache all ELF section info btf_encoder: add global_var feature to encode globals btf_encoder.c | 373 ++++++++++++++++++++++----------------------- btf_encoder.h | 8 + dutil.c | 14 +- dutil.h | 2 +- dwarf_loader.c | 12 +- dwarves.h | 3 + man-pages/pahole.1 | 8 +- pahole.c | 11 +- 8 files changed, 228 insertions(+), 203 deletions(-) -- 2.43.5