golang/src/math
Lynn Boger 330bc95093 math/big: improve use of addze in mulAddVWW on ppc64x
Improve the use of addze to avoid unnecessary register
moves on ppc64x.

goos: linux
goarch: ppc64le
pkg: math/big
cpu: POWER10
                 │   old.out    │               new.out               │
                 │    sec/op    │    sec/op     vs base               │
MulAddVWW/1         4.524n ± 3%   4.248n ±  0%   -6.10% (p=0.002 n=6)
MulAddVWW/2         5.634n ± 0%   5.283n ±  0%   -6.24% (p=0.002 n=6)
MulAddVWW/3         6.406n ± 0%   5.918n ±  0%   -7.63% (p=0.002 n=6)
MulAddVWW/4         6.484n ± 0%   5.859n ±  0%   -9.64% (p=0.002 n=6)
MulAddVWW/5         7.363n ± 0%   6.766n ±  0%   -8.11% (p=0.002 n=6)
MulAddVWW/10       10.920n ± 0%   9.856n ±  0%   -9.75% (p=0.002 n=6)
MulAddVWW/100       83.46n ± 0%   66.95n ±  0%  -19.78% (p=0.002 n=6)
MulAddVWW/1000      856.0n ± 0%   681.6n ±  0%  -20.38% (p=0.002 n=6)
MulAddVWW/10000     8.589µ ± 1%   6.774µ ±  0%  -21.14% (p=0.002 n=6)
MulAddVWW/100000    86.22µ ± 0%   67.71µ ± 43%  -21.48% (p=0.065 n=6)
geomean             73.34n        63.62n        -13.26%


Change-Id: I95d6ac49ff6b64aa678e6896f57af9d85c923aad
Reviewed-on: https://go-review.googlesource.com/c/go/+/579235
Reviewed-by: Carlos Amedee <carlos@golang.org>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Paul Murphy <murp@ibm.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
2024-04-16 17:59:58 +00:00
..
big math/big: improve use of addze in mulAddVWW on ppc64x 2024-04-16 17:59:58 +00:00
bits all: drop old +build lines 2023-10-19 23:33:27 +00:00
cmplx math: add available godoc link 2023-10-19 11:59:09 +00:00
rand math/rand, math/rand/v2: rename receiver variables 2024-03-04 17:32:49 +00:00
abs.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
acos_s390x.s math: use s390x mnemonics rather than binary encodings 2018-08-20 17:42:08 +00:00
acosh.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
acosh_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
all_test.go math: add test that covers riscv64 fnm{add,sub} codegen 2023-07-07 17:39:26 +00:00
arith_s390x.go math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
arith_s390x_test.go math: use SIMD to accelerate additional scalar math functions on s390x 2017-05-08 19:52:30 +00:00
asin.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
asin_s390x.s math: use s390x mnemonics rather than binary encodings 2018-08-20 17:42:08 +00:00
asinh.go all: fix mismatched symbols 2023-06-13 20:02:49 +00:00
asinh_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
atan.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
atan2.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
atan2_s390x.s math: correct Atan2(±y,+∞) = ±0 on s390x 2020-03-25 04:06:34 +00:00
atan_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
atanh.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
atanh_s390x.s all: replace leading spaces with tabs in assembly 2023-03-23 20:52:57 +00:00
bits.go all: replace `` and '' with “ (U+201C) and ” (U+201D) in doc comments 2022-04-05 17:52:29 +00:00
cbrt.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
cbrt_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
const.go math: show value of integer constants in comments 2022-09-21 14:07:39 +00:00
const_test.go math: add MaxUint, MinInt, MaxInt 2021-05-03 22:44:33 +00:00
copysign.go math: improve documentation of Copysign 2022-04-14 17:42:53 +00:00
cosh_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
dim.go math: document that Min/Max differ from min/max 2023-06-15 19:45:12 +00:00
dim_amd64.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
dim_arm64.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
dim_asm.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
dim_noasm.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
dim_riscv64.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
dim_s390x.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
erf.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
erf_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
erfc_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
erfinv.go math: add available godoc link 2023-10-19 11:59:09 +00:00
example_test.go math: add Remainder example 2021-10-07 18:09:53 +00:00
exp.go math: add available godoc link 2023-10-19 11:59:09 +00:00
exp2_asm.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
exp2_noasm.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
exp_amd64.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
exp_amd64.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
exp_arm64.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
exp_asm.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
exp_noasm.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
exp_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
expm1.go math: add available godoc link 2023-10-19 11:59:09 +00:00
expm1_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
export_s390x_test.go math: use SIMD to accelerate additional scalar math functions on s390x 2017-05-08 19:52:30 +00:00
export_test.go math: use constant rather than variable for exported test threshold 2018-12-13 06:33:18 +00:00
floor.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
floor_386.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
floor_amd64.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
floor_arm64.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
floor_asm.go math: add round assembly implementations on riscv64 2024-02-23 08:34:12 +00:00
floor_noasm.go math: add round assembly implementations on riscv64 2024-02-23 08:34:12 +00:00
floor_ppc64x.s all: drop old +build lines 2023-10-19 23:33:27 +00:00
floor_riscv64.s math: add round assembly implementations on riscv64 2024-02-23 08:34:12 +00:00
floor_s390x.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
floor_wasm.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
fma.go math: fix portable FMA when x*y < 0 and x*y == -z 2023-07-05 22:05:30 +00:00
frexp.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
gamma.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
huge_test.go math: enable huge argument tests on s390x 2023-07-31 16:23:41 +00:00
hypot.go math: add available godoc link 2023-10-19 11:59:09 +00:00
hypot_386.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
hypot_amd64.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
hypot_asm.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
hypot_noasm.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
j0.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
j1.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
jn.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
ldexp.go math: add available godoc link 2023-10-19 11:59:09 +00:00
lgamma.go math: add available godoc link 2023-10-19 11:59:09 +00:00
log.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
log1p.go math: add available godoc link 2023-10-19 11:59:09 +00:00
log1p_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
log10.go math: add available godoc link 2023-10-19 11:59:09 +00:00
log10_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
log_amd64.s all: replace leading spaces with tabs in assembly 2023-03-23 20:52:57 +00:00
log_asm.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
log_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
log_stub.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
logb.go math: fix function name in comment 2022-11-07 19:46:45 +00:00
mod.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
modf.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
modf_arm64.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
modf_asm.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
modf_noasm.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
modf_ppc64x.s all: drop old +build lines 2023-10-19 23:33:27 +00:00
nextafter.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
pow.go math: handle int64 overflows for odd integer exponents in Pow(-0, y) 2023-01-24 19:10:58 +00:00
pow10.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
pow_s390x.s all: fix spelling errors 2023-06-14 00:03:57 +00:00
remainder.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
signbit.go all: use "reports whether" consistently in the few places that didn't 2018-11-02 22:47:58 +00:00
sin.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
sin_s390x.s math: huge argument handling for sin/cos in s390x 2023-07-31 04:25:54 +00:00
sincos.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
sinh.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
sinh_s390x.s all: fix typos 2021-08-17 13:54:10 +00:00
sqrt.go cmd/compile,math: remove all sqrt assembly code 2022-08-15 17:07:57 +00:00
stubs.go all: go fix -fix=buildtag std cmd (except for bootstrap deps, vendor) 2021-10-28 18:17:57 +00:00
stubs_s390x.s math: avoid assembly stubs 2021-04-15 15:48:19 +00:00
tan.go all: fix some lint issues 2022-05-08 17:27:54 +00:00
tan_s390x.s math: support to handle huge arguments in tan function on s390x 2023-07-27 23:30:00 +00:00
tanh.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
tanh_s390x.s math: use new mnemonics for 'rotate then insert' on s390x 2019-04-16 15:34:41 +00:00
trig_reduce.go all: gofmt main repo 2022-04-11 16:34:30 +00:00
unsafe.go math: document sign bit correspondence for floating-point/bits conversions 2018-12-06 22:27:54 +00:00