Remove the MInst::TrapFf constructor from the riscv64 backend (#5515)

Remove the MInst::TrapFf instruction in the riscv64 backend. It was only used in two places in the emit case for FloatRound, and was easily replaced with a combination of FpuRRR and TrapIf.
This commit is contained in:
Trevor Elliott
2023-01-04 13:34:46 -08:00
committed by GitHub
parent 4bc4fae571
commit 5d429e46e8
3 changed files with 34 additions and 85 deletions

View File

@@ -108,19 +108,11 @@
(cc IntCC)
(trap_code TrapCode))
(TrapFf
(cc FloatCC)
(x Reg)
(y Reg)
(ty Type)
(tmp WritableReg)
(trap_code TrapCode))
(Jal
;; (rd WritableReg) don't use
(dest BranchTarget))
(CondBr
(CondBr
(taken BranchTarget)
(not_taken BranchTarget)
(kind IntegerCompare))
@@ -2069,15 +2061,6 @@
(negated Reg (neg $I64 extended)))
(max $I64 extended negated)))
(decl gen_trapff (FloatCC Reg Reg Type TrapCode) InstOutput)
(rule
(gen_trapff cc a b ty trap_code)
(let
((tmp WritableReg (temp_writable_reg $I64)))
(side_effect (SideEffectNoResult.Inst (MInst.TrapFf cc a b ty tmp trap_code)))))
(decl gen_trapif (Reg TrapCode) InstOutput)
(rule
(gen_trapif test trap_code)