[libcxx-commits] [libcxx] [libc++] Add CMake option to enable execute-only code generation on AArch64 (PR #140552)
Csanád Hajdú via libcxx-commits
libcxx-commits at lists.llvm.org
Mon May 19 08:34:49 PDT 2025
Il-Capitano wrote:
> Is there a reason to not do this unconditionally?
Execute-only code generation for AArch64 is fairly new, and currently planned to have limited use. Also older tools may not correctly handle merging the `SHF_AARCH64_PURECODE` ELF section flag that LLVM puts on `.text` (LLD 20 and before doesn't for example. It produces a valid non-execute-only output though, just that the section flag may be incorrectly kept).
If you don't use a very recent version of Clang, LLD, and a compatible libc implementation, you won't be able to take advantage of this feature, and may get unexpected behaviour from tools. In general, this configuration is intended for assembling a complete toolchain, where you control everything.
https://github.com/llvm/llvm-project/pull/140552
More information about the libcxx-commits
mailing list