[llvm] [BOLT] Support runtime library hook via DT_INIT_ARRAY (PR #167467)
Vasily Leonenko via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 25 09:34:14 PST 2025
================
@@ -5,7 +5,7 @@
# RUN: llvm-mc -filetype=obj -triple x86_64-unknown-unknown %s -o %t.o
# Delete our BB symbols so BOLT doesn't mark them as entry points
# RUN: llvm-strip --strip-unneeded %t.o
-# RUN: ld.lld %t.o -o %t.exe -q -shared -fini=_fini
+# RUN: ld.lld %t.o -o %t.exe -q -shared -fini=_fini -init=_init
----------------
vleonen wrote:
Right. Prior to this PR BOLT silently produced instrumented binary, but as there is no ELF entry point (as it is shared library), no DT_INIT - this binary could not initialize instrumentation runtime.
https://github.com/llvm/llvm-project/pull/167467
More information about the llvm-commits
mailing list