[PATCH] D118136: [Sparc] Implement BFD_RELOC_NONE

Rainer Orth via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 27 04:41:58 PST 2022


ro added a comment.

In D118136#3270096 <https://reviews.llvm.org/D118136#3270096>, @MaskRay wrote:

> The changes look good. `adjustFixupValue` may or may not need `FK_NONE`, depending on how it is called in various targets.

I've removed the handling and found no ill effect.

> Can you add a test like `test/MC/RISCV/reloc-directive.s` ?

Done now: I'd initially been lazy, following several other targets that didn't have testcases either.



================
Comment at: llvm/lib/Target/Sparc/MCTargetDesc/SparcELFObjectWriter.cpp:74
     llvm_unreachable("Unimplemented fixup -> relocation");
+  case FK_NONE:                  return ELF::R_SPARC_NONE;
   case FK_Data_1:                return ELF::R_SPARC_8;
----------------
I didn't: while `clang-format-diff.py` does make that change,
it causes that single case to diverge from all others.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D118136/new/

https://reviews.llvm.org/D118136



More information about the llvm-commits mailing list