[llvm] [BOLT] Support instrumentation hook via DT_FINI_ARRAY (PR #67348)
Vladislav Khmelevsky via llvm-commits
llvm-commits at lists.llvm.org
Mon Sep 25 11:40:02 PDT 2023
================
@@ -5008,7 +5066,7 @@ void RewriteInstance::patchELFDynamic(ELFObjectFile<ELFT> *File) {
}
}
RuntimeLibrary *RtLibrary = BC->getRuntimeLibrary();
- if (RtLibrary && Dyn.getTag() == ELF::DT_FINI) {
+ if (RtLibrary && Dyn.getTag() == ELF::DT_FINI && !BC->FiniArraySection) {
----------------
yota9 wrote:
FINI should be used by default, so extra check probably not needed here
https://github.com/llvm/llvm-project/pull/67348
More information about the llvm-commits
mailing list