1
0
mirror of https://github.com/golang/go synced 2024-11-25 11:27:56 -07:00
go/misc/cgo
Dave Cheney d073677569 cgo/misc/test: burn CPU to improve sleep accuracy
Fixes #4008.

Run a background goroutine that wastes CPU to trick the
power management into raising the CPU frequency which,
by side effect, makes sleep more accurate on arm.

=== RUN TestParallelSleep
--- PASS: TestParallelSleep (1.30 seconds)
_cgo_gotypes.go:772:    sleep(1) slept for 1.000458s

R=minux.ma, r
CC=golang-dev
https://golang.org/cl/6498060
2012-08-31 20:17:59 +10:00
..
gmp misc/cgo/gmp: update for Go 1 2012-03-21 00:51:48 +08:00
life misc/cgo/life: remove -lmsvcrt to fix windows/amd64 build 2012-08-17 09:10:01 +08:00
stdio misc/cgo/{life,stdio}, test/run.go: use test/run.go to do the cgo tests 2012-08-07 09:38:35 +08:00
test cgo/misc/test: burn CPU to improve sleep accuracy 2012-08-31 20:17:59 +10:00
testso cmd/go: add env command, use to fix misc/cgo/testso 2012-03-08 14:28:44 -05:00