1
0
mirror of https://github.com/golang/go synced 2024-11-18 09:34:53 -07:00

cmd/compile: enable Sqrt as a compiler intrinsic on riscv64

Change-Id: I829a02ced9aa73b45079e67194186116b39504b0
Reviewed-on: https://go-review.googlesource.com/c/go/+/227805
Reviewed-by: Josh Bleecher Snyder <josharian@gmail.com>
Reviewed-by: Cherry Zhang <cherryyz@google.com>
Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
This commit is contained in:
Joel Sing 2020-04-13 01:45:12 +10:00
parent 3afa74115b
commit 1eb66be1b9

View File

@ -3536,7 +3536,7 @@ func init() {
func(s *state, n *Node, args []*ssa.Value) *ssa.Value { func(s *state, n *Node, args []*ssa.Value) *ssa.Value {
return s.newValue1(ssa.OpSqrt, types.Types[TFLOAT64], args[0]) return s.newValue1(ssa.OpSqrt, types.Types[TFLOAT64], args[0])
}, },
sys.I386, sys.AMD64, sys.ARM, sys.ARM64, sys.MIPS, sys.MIPS64, sys.PPC64, sys.S390X, sys.Wasm) sys.I386, sys.AMD64, sys.ARM, sys.ARM64, sys.MIPS, sys.MIPS64, sys.PPC64, sys.RISCV64, sys.S390X, sys.Wasm)
addF("math", "Trunc", addF("math", "Trunc",
func(s *state, n *Node, args []*ssa.Value) *ssa.Value { func(s *state, n *Node, args []*ssa.Value) *ssa.Value {
return s.newValue1(ssa.OpTrunc, types.Types[TFLOAT64], args[0]) return s.newValue1(ssa.OpTrunc, types.Types[TFLOAT64], args[0])