]>
Cypherpunks repositories - gostls13.git/commit
math: optimize the floating-point pipeline on loong64
Using the FSEL instruction on loong64 to eliminate branches and reduce
pipeline interruptions.
On the Loongson CPU 3A6000, there is a 0.09% performance improvement, as follows:
goos: linux
goarch: loong64
pkg: math/big
cpu: Loongson-3A6000-HV @ 2500.00MHz
│ old.bench │ new.bench │
│ sec/op │ sec/op vs base │
Exp 7.748m ± 0% 7.740m ± 0% -0.10% (p=0.001 n=10)
Exp2 7.747m ± 0% 7.741m ± 0% -0.09% (p=0.002 n=10)
geomean 7.747m 7.740m -0.09%
Change-Id: If62f2e81bf345c83a1fa9350ace131240cfa3b9b
Reviewed-on: https://go-review.googlesource.com/c/go/+/693458
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
Reviewed-by: abner chenc <chenguoqi@loongson.cn>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Meidan Li <limeidan@loongson.cn>