BugReportNeedsFixPerformancecompiler/runtimehelp wanted
Description
Go version
go version go1.24.1 linux/amd64
Output of go env in your module/workspace:
-
What did you do?
go build -gcflags=-S
func mymin(a, b float64) float64 {
if a < b {
return a
} else {
return b
}
}
What did you see happen?
0x0000 00000 (bar.go:4) UCOMISD X0, X1
0x0004 00004 (bar.go:4) JLS 7
0x0006 00006 (bar.go:5) RET
0x0007 00007 (bar.go:7) MOVUPS X1, X0
0x000a 00010 (bar.go:7) RET
What did you expect to see?
I think
MINSD X1, X0
RET
but maybe
MINSD X0, X1
MOVUPS X1, X0
RET
AT&T argument order has me thoroughly confused at times.