aboutsummaryrefslogtreecommitdiff
path: root/lldb/packages/Python/lldbsuite/test
diff options
context:
space:
mode:
authoralx32 <103613512+alx32@users.noreply.github.com>2024-10-10 08:22:48 -0700
committerGitHub <noreply@github.com>2024-10-10 08:22:48 -0700
commit97a43242246bf4a55e68bddf3e6a0500c07803cc (patch)
tree74277046e74b250f8242613b4e51c2fc30de75b6 /lldb/packages/Python/lldbsuite/test
parentfc467b477545c9f8ef4dc36ecee4dcd2a7457787 (diff)
downloadllvm-97a43242246bf4a55e68bddf3e6a0500c07803cc.zip
llvm-97a43242246bf4a55e68bddf3e6a0500c07803cc.tar.gz
llvm-97a43242246bf4a55e68bddf3e6a0500c07803cc.tar.bz2
[lld-macho] Fix ICF differentiation of safe_thunks relocs (#111811)
In `--icf=safe_thunks` mode, the linker differentiates `keepUnique` functions by creating thunks during a post-processing step after Identical Code Folding (ICF). While this ensures that `keepUnique` functions themselves are not incorrectly merged, it overlooks functions that reference these `keepUnique` symbols. If two functions are identical except for references to different `keepUnique` functions, the current ICF algorithm incorrectly considers them identical because it doesn't account for the future differentiation introduced by thunks. This leads to incorrect deduplication of functions that should remain distinct. To address this issue, we modify the ICF comparison to explicitly check for references to `keepUnique` functions during deduplication. By doing so, functions that reference different `keepUnique` symbols are correctly identified as distinct, preventing erroneous merging and ensuring the correctness of the linked output.
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test')
0 files changed, 0 insertions, 0 deletions