[libclc] [libclc] add --only-needed to llvm-link when INTERNALIZE flag is set (PR #130871)

Wenju He via cfe-commits cfe-commits at lists.llvm.org
Thu Mar 20 04:39:06 PDT 2025


wenju-he wrote:

@frasercrmck could you please try this PR on https://github.com/intel/llvm repo?

My experiment:
clang --version
clang version 21.0.0git (https://github.com/llvm/llvm-project f5ee10538b68835112323c241ca7db67ca78bf62)

before PR: 
find . -name "builtins.link*.bc" -printf "%s\n" | paste -sd+ | bc
101593692

after PR:
find . -name "builtins.link*.bc" -printf "%s\n" | paste -sd+ | bc
101316928

This PR reduces bitcode file sizes by 0.27%

https://github.com/llvm/llvm-project/pull/130871


More information about the cfe-commits mailing list