]> Cypherpunks repositories - gostls13.git/commit
[release-branch.go1.10] cmd/go: if -race, don't run coverage on runtime packages
authorIan Lance Taylor <iant@golang.org>
Sat, 17 Feb 2018 03:08:59 +0000 (19:08 -0800)
committerAndrew Bonventre <andybons@golang.org>
Thu, 29 Mar 2018 06:08:56 +0000 (06:08 +0000)
commit4bc847d8c9565d3b123d74f06878ec93ee02ac63
tree6dcf2b5201b30dd0cef29f44a7235ba36b5763ff
parentc917b3c32b2434ddf035130c36453aadf43f3008
[release-branch.go1.10] cmd/go: if -race, don't run coverage on runtime packages

Don't compile the runtime packages with coverage when using the race
detector. The user can, perhaps accidentally, request coverage for the
runtime by using -coverpkg=all. If using the race detector, the
runtime package coverage will call into the race detector before it
has been initialized. This will cause the program to crash
mysteriously on startup.

Fixes #23882

Change-Id: I9a63867a9138797d8b8afb0856ae21079accdb27
Reviewed-on: https://go-review.googlesource.com/94898
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Andrew Bonventre <andybons@golang.org>
Reviewed-on: https://go-review.googlesource.com/103095
Run-TryBot: Andrew Bonventre <andybons@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/cmd/go/go_test.go
src/cmd/go/internal/test/test.go