mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
cmd/compile: implement float min/max in hardware for amd64 and arm64
Update #59488 Change-Id: I89f5ea494cbcc887f6fae8560e57bcbd8749be86 Reviewed-on: https://go-review.googlesource.com/c/go/+/514596 Reviewed-by: Keith Randall <khr@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Run-TryBot: Keith Randall <khr@golang.org> Reviewed-by: Cherry Mui <cherryyz@google.com>
This commit is contained in:
parent
ca36301228
commit
319504ce43
11 changed files with 298 additions and 3 deletions
|
|
@ -285,6 +285,12 @@ var genericOps = []opData{
|
|||
{name: "Abs", argLength: 1}, // absolute value arg0
|
||||
{name: "Copysign", argLength: 2}, // copy sign from arg0 to arg1
|
||||
|
||||
// Float min/max implementation, if hardware is available.
|
||||
{name: "Min64F", argLength: 2}, // min(arg0,arg1)
|
||||
{name: "Min32F", argLength: 2}, // min(arg0,arg1)
|
||||
{name: "Max64F", argLength: 2}, // max(arg0,arg1)
|
||||
{name: "Max32F", argLength: 2}, // max(arg0,arg1)
|
||||
|
||||
// 3-input opcode.
|
||||
// Fused-multiply-add, float64 only.
|
||||
// When a*b+c is exactly zero (before rounding), then the result is +0 or -0.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue