aboutsummaryrefslogtreecommitdiff
path: root/src/testing/testing.go
diff options
context:
space:
mode:
authorCharlie Vieth <charlie.vieth@gmail.com>2022-03-12 17:27:42 -0500
committerGopher Robot <gobot@golang.org>2022-05-11 13:52:09 +0000
commit536282763f7357edd81d85993c12fd977fecd378 (patch)
tree25c20f32a0909f7ef7714164ab295ec4bc152520 /src/testing/testing.go
parent636c5f02082e4be5ef2d9a66c99c9e31b72246a3 (diff)
downloadgo-536282763f7357edd81d85993c12fd977fecd378.tar.xz
go/build: replace ioutil.ReadDir with os.ReadDir
Change go/build.readDir to use os.ReadDir instead of ioutil.ReadDir. This addresses a TODO and improves performance on Darwin and Linux. Darwin: Apple M1 name old time/op new time/op delta ImportVendor-10 39.8µs ± 1% 37.0µs ± 1% -6.91% (p=0.000 n=10+10) Linux: Intel(R) Core(TM) i9-9900K CPU @ 3.60GHz name old time/op new time/op delta ImportVendor-16 22.9µs ±11% 21.2µs ± 5% -7.47% (p=0.001 n=10+9) Updates #45557 Change-Id: Ib1bd2e66210e714e499a035847d6261b61b7e2c6 Reviewed-on: https://go-review.googlesource.com/c/go/+/392074 Run-TryBot: Ian Lance Taylor <iant@google.com> Reviewed-by: Daniel Martí <mvdan@mvdan.cc> Reviewed-by: Ian Lance Taylor <iant@google.com> Reviewed-by: Dmitri Shuralyov <dmitshur@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Auto-Submit: Ian Lance Taylor <iant@google.com>
Diffstat (limited to 'src/testing/testing.go')
0 files changed, 0 insertions, 0 deletions