[PATCH] D131771: [RISCV] : Add support for immediate operands.
EverRest via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Aug 12 06:10:40 PDT 2022
MarkGoncharovAl created this revision.
MarkGoncharovAl added reviewers: 255, 13rac1.
Herald added subscribers: sunshaoce, VincentWu, luke957, vkmr, frasercrmck, evandro, mstojanovic, luismarques, apazos, sameer.abuasal, s.egerton, Jim, benna, psnobl, jocewei, PkmX, the_o, brucehoult, MartinMosbeck, rogfer01, edward-jones, zzheng, jrtc27, shiva0217, kito-cheng, niosHD, sabuasal, simoncook, johnrusso, rbar, asb, hiraditya, arichardson.
Herald added a project: All.
MarkGoncharovAl requested review of this revision.
Herald added subscribers: llvm-commits, pcwang-thead, eopXD, courbet, MaskRay.
Herald added a project: LLVM.
Launching on RISCV machine llvm-exegesis to measure latency, I faced with troubles like: 'Operand is not set: ... <MCOperand INVALID>>; ... OpInfo.OperandType: 0'
(explanation: OperandType 0 means Unknown type).
Find out that this problem occurs with instructions:
C_ADDI
C_ADDIW
C_ADDI_HINT_IMM_ZERO
C_ANDI
C_FLD
C_FLW
C_LD
C_LW
C_SLLI
C_SRAI
C_SRLI
SHFLI
UNSHFLI
VADC_VIM
VADD_VI
VAND_VI
VMADC_VI
VMADC_VIM
VMERGE_VIM
VMSEQ_VI
VMSGTU_VI
VMSGT_VI
VMSLEU_VI
VMSLE_VI
VMSNE_VI
VOR_VI
VRSUB_VI
VSADDU_VI
VSADD_VI
VSETVLI
VXOR_VI
llvm-exegesis uses operand type information provided in tablegen files to initialize immediate arguments of the instruction. Some of them (listed above) simply don't have such information. Thus we should set into relevant immediate operands their specific type. Also create verification methods for them.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D131771
Files:
llvm/lib/Target/RISCV/AsmParser/RISCVAsmParser.cpp
llvm/lib/Target/RISCV/MCTargetDesc/RISCVBaseInfo.h
llvm/lib/Target/RISCV/RISCVInstrInfo.cpp
llvm/lib/Target/RISCV/RISCVInstrInfoC.td
llvm/lib/Target/RISCV/RISCVInstrInfoV.td
llvm/lib/Target/RISCV/RISCVInstrInfoZb.td
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D131771.452165.patch
Type: text/x-patch
Size: 10397 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220812/738e400f/attachment.bin>
More information about the llvm-commits
mailing list