[lld] [lld][AArch64][ELF][PAC] Support AUTH relocations and AUTH ELF marking (PR #72714)
Daniil Kovalev via llvm-commits
llvm-commits at lists.llvm.org
Mon Dec 11 22:07:31 PST 2023
================
@@ -566,6 +570,7 @@ constexpr const char *knownZFlags[] = {
"origin",
"pac-plt",
"pack-relative-relocs",
+ "pack-relative-auth-relocs",
----------------
kovdan01 wrote:
Hmm, since we place auth packed relocs to a separate section other than usual relr section, this should not cause compatibility issues.
It looks like it would be better use `--pack-dyn-relocs` then, like it's already done for android packed relocs. They don't rely on `-z pack-relative-relocs`.
```
static std::pair<bool, bool> getPackDynRelocs(opt::InputArgList &args) {
StringRef s = args.getLastArgValue(OPT_pack_dyn_relocs, "none");
if (s == "android")
return {true, false};
if (s == "relr")
return {false, true};
if (s == "android+relr")
return {true, true};
if (s != "none")
error("unknown --pack-dyn-relocs format: " + s);
return {false, false};
}
```
https://github.com/llvm/llvm-project/pull/72714
More information about the llvm-commits
mailing list