Skip to content

Commit 03610af

Browse files
committed
[RISCV] Remove Inst bits from Pseudo tablegen class. NFC
Pseudods shouldn't have encoding information so these bits should never be used.
1 parent 40b0619 commit 03610af

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

llvm/lib/Target/RISCV/RISCVInstrFormats.td

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,9 +281,10 @@ class RVInst64<dag outs, dag ins, string opcodestr, string argstr,
281281

282282
// Pseudo instructions
283283
class Pseudo<dag outs, dag ins, list<dag> pattern, string opcodestr = "", string argstr = "">
284-
: RVInst<outs, ins, opcodestr, argstr, pattern, InstFormatPseudo> {
284+
: RVInstCommon<outs, ins, opcodestr, argstr, pattern, InstFormatPseudo> {
285285
let isPseudo = 1;
286286
let isCodeGenOnly = 1;
287+
let Size = 4;
287288
}
288289

289290
class PseudoQuietFCMP<DAGOperand Ty>

llvm/lib/Target/RISCV/RISCVInstrInfoF.td

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -503,13 +503,13 @@ def fpimm0 : PatLeaf<(fpimm), [{ return N->isExactlyValue(+0.0); }]>;
503503

504504
/// Generic pattern classes
505505
class PatSetCC<DAGOperand Ty, SDPatternOperator OpNode, CondCode Cond,
506-
RVInst Inst, ValueType vt>
506+
RVInstCommon Inst, ValueType vt>
507507
: Pat<(XLenVT (OpNode (vt Ty:$rs1), Ty:$rs2, Cond)), (Inst $rs1, $rs2)>;
508508
multiclass PatSetCC_m<SDPatternOperator OpNode, CondCode Cond,
509-
RVInst Inst, ExtInfo Ext> {
509+
RVInstCommon Inst, ExtInfo Ext> {
510510
let Predicates = Ext.Predicates in
511511
def Ext.Suffix : PatSetCC<Ext.PrimaryTy, OpNode, Cond,
512-
!cast<RVInst>(Inst#Ext.Suffix), Ext.PrimaryVT>;
512+
!cast<RVInstCommon>(Inst#Ext.Suffix), Ext.PrimaryVT>;
513513
}
514514

515515
class PatFprFpr<SDPatternOperator OpNode, RVInstR Inst,

0 commit comments

Comments
 (0)