On Sat, 20 Jul 2024 00:20:19 GMT, Jiangli Zhou <jian...@openjdk.org> wrote:
> Please review this PR that strips the `.llvm_addrsig` section from JDK and > hotspot `.a` static libraries when building with clang. Please see > https://bugs.openjdk.org/browse/JDK-8336849 description for details. make/common/native/Link.gmk line 114: > 112: # Linking with '-Wl,--icf=safe' using objects created by 'ld > -r' may not work > 113: # and could cause errors like the following: > 114: # ld: --icf=safe conservatively ignores SHT_LLVM_ADDRSIG > [...] with sh_link=0 (likely created using objcopy or ld -r) I'd recommend rephrasing the comment somewhat, like Suggestion: # 'ld -r' might fail to update the .llvm_addrsig section, and this will cause subsequent # calls to lld to fail when linking with this library, so remove that section. (adjust line lengths if > 80) ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/20265#discussion_r1707228847