Skip to content

Commit e6b93b5

Browse files
committed
Add comment about expansion
Created using spr 1.3.5
2 parents 08e7d9e + 3264085 commit e6b93b5

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

llvm/lib/Target/Sparc/SparcInstrVIS.td

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -279,8 +279,8 @@ def XMULXHI : VISInst<0b100010110, "xmulxhi", I64Regs>;
279279
} // Predicates = [IsVIS3]
280280

281281
// FP immediate patterns.
282-
def fpimm0 : PatLeaf<(fpimm), [{return N->isExactlyValue(+0.0);}]>;
283-
def fpnegimm0 : PatLeaf<(fpimm), [{return N->isExactlyValue(-0.0);}]>;
282+
def fpimm0 : FPImmLeaf<fAny, [{return Imm.isExactlyValue(+0.0);}]>;
283+
def fpnegimm0 : FPImmLeaf<fAny, [{return Imm.isExactlyValue(-0.0);}]>;
284284

285285
// VIS instruction patterns.
286286
let Predicates = [HasVIS] in {
@@ -299,6 +299,7 @@ def : Pat<(i64 (mulhu i64:$lhs, i64:$rhs)), (UMULXHI $lhs, $rhs)>;
299299
// Signed "MULXHI".
300300
// Based on the formula presented in OSA2011 §7.140, but with bitops to select
301301
// the values to be added.
302+
// TODO: This expansion should probably be moved to DAG legalization phase.
302303
def : Pat<(i64 (mulhs i64:$lhs, i64:$rhs)),
303304
(SUBrr (UMULXHI $lhs, $rhs),
304305
(ADDrr (ANDrr (SRAXri $lhs, 63), $rhs),

0 commit comments

Comments
 (0)