diff options
Diffstat (limited to 'src/cmd/compile/internal/ssa/rewriteMIPS64.go')
-rw-r--r-- | src/cmd/compile/internal/ssa/rewriteMIPS64.go | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/cmd/compile/internal/ssa/rewriteMIPS64.go b/src/cmd/compile/internal/ssa/rewriteMIPS64.go index d78f6089af..541bdd694a 100644 --- a/src/cmd/compile/internal/ssa/rewriteMIPS64.go +++ b/src/cmd/compile/internal/ssa/rewriteMIPS64.go @@ -339,6 +339,8 @@ func rewriteValueMIPS64(v *Value) bool { return rewriteValueMIPS64_OpMIPS64MOVHstorezero(v) case OpMIPS64MOVVload: return rewriteValueMIPS64_OpMIPS64MOVVload(v) + case OpMIPS64MOVVnop: + return rewriteValueMIPS64_OpMIPS64MOVVnop(v) case OpMIPS64MOVVreg: return rewriteValueMIPS64_OpMIPS64MOVVreg(v) case OpMIPS64MOVVstore: @@ -594,6 +596,9 @@ func rewriteValueMIPS64(v *Value) bool { case OpSqrt: v.Op = OpMIPS64SQRTD return true + case OpSqrt32: + v.Op = OpMIPS64SQRTF + return true case OpStaticCall: v.Op = OpMIPS64CALLstatic return true @@ -3584,6 +3589,21 @@ func rewriteValueMIPS64_OpMIPS64MOVVload(v *Value) bool { } return false } +func rewriteValueMIPS64_OpMIPS64MOVVnop(v *Value) bool { + v_0 := v.Args[0] + // match: (MOVVnop (MOVVconst [c])) + // result: (MOVVconst [c]) + for { + if v_0.Op != OpMIPS64MOVVconst { + break + } + c := auxIntToInt64(v_0.AuxInt) + v.reset(OpMIPS64MOVVconst) + v.AuxInt = int64ToAuxInt(c) + return true + } + return false +} func rewriteValueMIPS64_OpMIPS64MOVVreg(v *Value) bool { v_0 := v.Args[0] // match: (MOVVreg x) |