I am trying to do this to make it easier for LLD to support EH frames
for multiple archs. At present, DwarfFDESymbolsUseAbsDiff (first added
[here][1]) is only enabled for x86 archs. Rather than making LLD support
both abs-diff EH frame relocations as well as regular ones, I'm hoping
we can make MC emit EH frame relocs in the same format across archs.
However, naively toggling the flag gives us an [assertion error][4] when
running MC (and deleting the assertion results in a crash). So I
reverted [the commit that added the assertion][2] and removed some
functionality. This gets me the desired output for aarch64, but causes
[this test][3] to fail instead.
From reading commit #2's message, I suspect reverting it isn't the right
approach. Rafael authored that commit, but he's no longer around;
however the commit does reference r249303 which was also worked on by
@m.ostapenko and a mononymous "andy". I'm not sure who Andy is, so just
adding Maxim for now. Any pointers would be greatly appreciated :)
[1]: https://github.com/llvm/llvm-project/commit/618def651b59bd42c05bbd91d825af2fb2145683
[2]: https://github.com/llvm/llvm-project/commit/06c064824ef29425db785a31fed03821777fbf12
[3]: https://github.com/llvm/llvm-project/blob/main/llvm/test/CodeGen/AArch64/arm64_32.ll
[4]: https://github.com/llvm/llvm-project/blob/2a6669060f3533d144b12d1ec0faafe2de537994/llvm/lib/Target/AArch64/MCTargetDesc/AArch64MachObjectWriter.cpp#L325