[lld] [ARM][LLD] Fix buildbot failure due to ununsed variable [NFC] (PR #202925)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 10 03:49:54 PDT 2026
llvmorg-github-actions[bot] wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-lld
Author: Peter Smith (smithp35)
<details>
<summary>Changes</summary>
The variable was used in an assert, have altered the code to use in an a non-assert context.
---
Full diff: https://github.com/llvm/llvm-project/pull/202925.diff
1 Files Affected:
- (modified) lld/ELF/Relocations.cpp (+1-2)
``````````diff
diff --git a/lld/ELF/Relocations.cpp b/lld/ELF/Relocations.cpp
index 0338754c9c32f..0d45236e6d11e 100644
--- a/lld/ELF/Relocations.cpp
+++ b/lld/ELF/Relocations.cpp
@@ -1801,8 +1801,7 @@ static bool isThunkSectionCompatible(InputSection *source, Thunk &thunk) {
// Thunks in a different Overlay Output Section can't be reused
// as we can't guarantee that the Overlay will be in memory.
- return (source->getOutputSection() == targetOS->getOutputSection() ||
- !targetOS->inOverlay);
+ return (sourceOS == targetOS || !targetOS->inOverlay);
}
std::pair<Thunk *, bool> ThunkCreator::getThunk(InputSection *isec,
``````````
</details>
https://github.com/llvm/llvm-project/pull/202925
More information about the llvm-commits
mailing list