[lld] [lld][ELF] Allow Arm PC-relative relocations in pic or shared library (PR #77304)

Fangrui Song via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 10 11:22:52 PST 2024


MaskRay wrote:

> That's code in the kernel, so not preemptible, though if the code is still wrong for other reasons it's not a problem to fix it to support newer toolchains, there's normally some amount of that across the tree on each LLVM bump.

Thanks for the comment. Linux kernel uses `-shared -Bsymbolic` to make defined symbols non-preemptible. Perhaps FreeBSD kernel uses something similar. Then placing `R_ARM_PCA` into `isRelExpr` should create no risk.

https://github.com/llvm/llvm-project/pull/77304


More information about the llvm-commits mailing list