On Thu, Mar 05, 2026 at 03:15:24PM -0800, Song Liu wrote:
> Add support for LTO in klp-build toolchain. The key changes are to the
> symbol correlation logic.Basically, we want to:
> 
> 1. Match symbols with differerent .llvm.<hash> suffixes, e.g., foo.llvm.123
>    to foo.llvm.456.
> 2. Match local symbols with promoted global symbols, e.g., local foo
>    with global foo.llvm.123.
> 
> 1/7 and 2/7 are small cleanup/fix for existing code.
> 3/7 through 7/7 contains the core logic changes to correlate_symbols().
> 
> Changes v3 => v4:
> 1. Minor fixes in patches 1, 3, 7.
> 2. Only keep patches 1-7 for now, as there is ongoing discussion about the
>    test infrastructure.
> 
> Changes v2 => v3:
> 1. Fix a bug in global => local correlations (patch 7/8).
> 2. Remove a WARN().
> 3. Some empty line changes.
> 
> Changes v1 => v2:
> 1. Error out on ambiguous .llvm.<hash>
> 
> Song Liu (7):
>   objtool/klp: Remove redundant strcmp() in correlate_symbols()
>   objtool/klp: Remove trailing '_' in demangle_name()
>   objtool/klp: Use sym->demangled_name for symbol_name hash
>   objtool/klp: Also demangle global objects
>   objtool/klp: Remove .llvm suffix in demangle_name()
>   objtool/klp: Match symbols based on demangled_name for global
>     variables
>   objtool/klp: Correlate locals to globals
> 
>  tools/objtool/elf.c                 | 95 ++++++++++++++++++++++-------
>  tools/objtool/include/objtool/elf.h |  3 +
>  tools/objtool/klp-diff.c            | 89 ++++++++++++++++++++++++++-
>  3 files changed, 165 insertions(+), 22 deletions(-)

Thanks!  I will go ahead and queue these up.

-- 
Josh

Reply via email to