mirror of https://github.com/golang/go.git
runtime/race: update race runtime
This updates the runtime to HEAD to keep it aligned and fixes some bugs. http://llvm.org/viewvc/llvm-project?view=revision&revision=285454 fixes the crash on darwin related to unaligned data section (#17065). http://llvm.org/viewvc/llvm-project?view=revision&revision=285451 enables core dumps by default (#16527). http://llvm.org/viewvc/llvm-project?view=revision&revision=285455 adds a hook to obtain number of races reported so far (#15972). Can now be obtained with: //go:nosplit func RaceReportCount() int { var n uint64 racecall(&__tsan_report_count, uintptr(unsafe.Pointer(&n)), 0, 0, 0) return int(n) } Fixes #16527. Fixes #17065. Update #15972. Change-Id: I8f869cb6275c9521a47303f3810a9965e9314357 Reviewed-on: https://go-review.googlesource.com/32160 Run-TryBot: Dmitry Vyukov <dvyukov@google.com> TryBot-Result: Gobot Gobot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
This commit is contained in:
parent
7ba36f4adb
commit
042264ef1b
|
|
@ -1061,8 +1061,7 @@ func (t *tester) raceTest(dt *distTest) error {
|
|||
// The race builder should catch any error here, but doesn't.
|
||||
// TODO(iant): Figure out how to catch this.
|
||||
// t.addCmd(dt, "src", "go", "test", "-race", "-run=TestParallelTest", "cmd/go")
|
||||
// TODO: Remove t.goos != "darwin" when issue 17065 is fixed.
|
||||
if t.cgoEnabled && t.goos != "darwin" {
|
||||
if t.cgoEnabled {
|
||||
env := mergeEnvLists([]string{"GOTRACEBACK=2"}, os.Environ())
|
||||
cmd := t.addCmd(dt, "misc/cgo/test", "go", "test", "-race", "-short", t.runFlag(""))
|
||||
cmd.Env = env
|
||||
|
|
|
|||
|
|
@ -176,6 +176,9 @@ var __tsan_go_ignore_sync_begin byte
|
|||
//go:linkname __tsan_go_ignore_sync_end __tsan_go_ignore_sync_end
|
||||
var __tsan_go_ignore_sync_end byte
|
||||
|
||||
//go:linkname __tsan_report_count __tsan_report_count
|
||||
var __tsan_report_count byte
|
||||
|
||||
// Mimic what cmd/cgo would do.
|
||||
//go:cgo_import_static __tsan_init
|
||||
//go:cgo_import_static __tsan_fini
|
||||
|
|
@ -192,6 +195,7 @@ var __tsan_go_ignore_sync_end byte
|
|||
//go:cgo_import_static __tsan_release_merge
|
||||
//go:cgo_import_static __tsan_go_ignore_sync_begin
|
||||
//go:cgo_import_static __tsan_go_ignore_sync_end
|
||||
//go:cgo_import_static __tsan_report_count
|
||||
|
||||
// These are called from race_amd64.s.
|
||||
//go:cgo_import_static __tsan_read
|
||||
|
|
|
|||
|
|
@ -4,4 +4,4 @@ the LLVM project (http://llvm.org/git/compiler-rt.git).
|
|||
|
||||
To update the .syso files use golang.org/x/build/cmd/racebuild.
|
||||
|
||||
Current runtime is built on rev e35e7c00b5c7e7ee5e24d537b80cb0d34cebb038.
|
||||
Current runtime is built on rev 68e1532492f9b3fce0e9024f3c31411105965b11.
|
||||
|
|
|
|||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading…
Reference in New Issue