diff options
| author | j178 <sherlockjoe8@gmail.com> | 2023-08-18 12:04:35 +0800 |
|---|---|---|
| committer | Gopher Robot <gobot@golang.org> | 2023-08-18 23:40:44 +0000 |
| commit | ba7ba9bcc0e755f2c072d308e1c9f79bb2564e03 (patch) | |
| tree | 66ee955003e8e630c33c2325df5e2ed0edb370b7 /src/encoding | |
| parent | 8789b5d72fe5a3f6c341d6f1b1f0097b5514657f (diff) | |
| download | go-ba7ba9bcc0e755f2c072d308e1c9f79bb2564e03.tar.xz | |
errors: optimize Is and As by reusing reflection of target
goos: darwin
goarch: amd64
pkg: errors
cpu: Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz
│ old │ new │
│ sec/op │ sec/op vs base │
Is-12 133.4n ± 0% 126.8n ± 3% -4.91% (p=0.001 n=10)
As-12 464.1n ± 1% 307.2n ± 0% -33.80% (p=0.000 n=10)
geomean 248.8n 197.4n -20.66%
│ old │ new │
│ B/op │ B/op vs base │
Is-12 24.00 ± 0% 24.00 ± 0% ~ (p=1.000 n=10) ¹
As-12 40.00 ± 0% 40.00 ± 0% ~ (p=1.000 n=10) ¹
geomean 30.98 30.98 +0.00%
¹ all samples are equal
│ old │ new │
│ allocs/op │ allocs/op vs base │
Is-12 1.000 ± 0% 1.000 ± 0% ~ (p=1.000 n=10) ¹
As-12 2.000 ± 0% 2.000 ± 0% ~ (p=1.000 n=10) ¹
geomean 1.414 1.414 +0.00%
¹ all samples are equal
Change-Id: I0844f3ab77e63b5f773594157dcffaffffd5e70d
Reviewed-on: https://go-review.googlesource.com/c/go/+/520756
Run-TryBot: Ian Lance Taylor <iant@google.com>
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@google.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
Diffstat (limited to 'src/encoding')
0 files changed, 0 insertions, 0 deletions
