[llvm] [BOLT][AArch64] Relax calls and branches with fragment clusters (PR #215825)
Alexandros Lamprineas via llvm-commits
llvm-commits at lists.llvm.org
Thu Sep 10 03:25:54 PDT 2026
labrinea wrote:
> @labrinea
>
> I tested this new stack but it broke for me and generated out-of-range calls, I bisected the problem to commit "refactor branch collection and get rid of relax-plt". It dropped the containment guard from the adjacent-cluster long-thunk reuse:
>
> ```
> if (ReuseCluster) {
> auto It = ReuseCluster->CallThunks.find(TargetSymbol);
> - if (It != ReuseCluster->CallThunks.end() &&
> - llvm::is_contained(*ReuseThunkList, It->second)) {
> + if (It != ReuseCluster->CallThunks.end()) {
> BinaryFunction *Thunk = It->second;
> ```
>
> That guard was the "only reuse if the neighbor actually hosts this thunk" check. Without it, reuse becomes transitive.
Thanks @rafaelauler, this should be fixed now.
https://github.com/llvm/llvm-project/pull/215825
More information about the llvm-commits
mailing list