Add branch/jump/call/l32r instructions and fixups support. Add R_XTENSA_32/R_XTENSA_SLOT0_OP
relocations in object files generation. Modify tests to support new instructions.
Add tests for relocations and fixups.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Patch is updated according to LLVM upstream version and latest Xtensa backend version.
Correct instruction descriptions, format descriptions and instruction operands according to common style for *.td files. The llvm_unreachable is substituted to report_fatal_error.
llvm/lib/Target/Xtensa/AsmParser/XtensaAsmParser.cpp | ||
---|---|---|
502 | Whatever patch includes this whitespace should be fixed. | |
llvm/lib/Target/Xtensa/MCTargetDesc/XtensaAsmBackend.cpp | ||
97 | Whitespace, and unnecessary parens. | |
llvm/test/MC/Xtensa/relocations.s | ||
14 ↗ | (On Diff #335960) | Some assembly files have 1 leading space, some have 0, some have multiple. Please be consistent. |
@jrtc27 ,thank you very much for comments.
llvm/lib/Target/Xtensa/AsmParser/XtensaAsmParser.cpp | ||
---|---|---|
502 | Whitespace is removed | |
llvm/lib/Target/Xtensa/MCTargetDesc/XtensaAsmBackend.cpp | ||
97 | Whitespace and parentheses are removed | |
llvm/test/MC/Xtensa/relocations.s | ||
14 ↗ | (On Diff #335960) | I removed leading spaces from tests. |
Test file "xtensa-valid.s" is splitted to several files according to instructions groups.
The patch is too big, I wasn't able to review it thoroughly.
llvm/lib/Target/Xtensa/Disassembler/XtensaDisassembler.cpp | ||
---|---|---|
107 | (minor) I believe Address should be uint64_t (here and in other methods below). | |
121 | (minor) All these method can accept const MCDisassebler *Decoder instead of const void *. | |
llvm/lib/Target/Xtensa/MCTargetDesc/XtensaELFObjectWriter.cpp | ||
50 | (note for the future?) This should take into account IsPCRel flag. | |
llvm/lib/Target/Xtensa/MCTargetDesc/XtensaInstPrinter.cpp | ||
101–104 | Either all of 'if's should have braces or none. |
Whatever patch includes this whitespace should be fixed.