]> Cypherpunks repositories - gostls13.git/commitdiff
runtime/race: update race runtime
authorDmitry Vyukov <dvyukov@google.com>
Fri, 28 Oct 2016 15:12:39 +0000 (17:12 +0200)
committerDmitry Vyukov <dvyukov@google.com>
Sun, 30 Oct 2016 16:15:54 +0000 (16:15 +0000)
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>
src/cmd/dist/test.go
src/runtime/race.go
src/runtime/race/README
src/runtime/race/race_darwin_amd64.syso
src/runtime/race/race_freebsd_amd64.syso
src/runtime/race/race_linux_amd64.syso
src/runtime/race/race_windows_amd64.syso

index 3aef0afb232053627b25ef52d50bc35a86ffd02a..7629547279961a35c45b04c788c0f405a7ab9c25 100644 (file)
@@ -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
index 6f24e09925edd6102dfbe4d35b36d5f444ea4f23..c8af8f6f50b44563f3b628948d2c5533e410c103 100644 (file)
@@ -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
index 95e241c072c2b47cbd6e4b37a4b2b38cfda9107f..398b22f71e80b7dbeccacd418952ff0be8055205 100644 (file)
@@ -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.
index c19740fb8f2cad61854cfc0a9049400fd010d819..89c7f5790191ca09e3a2f134ff142068c2d3c541 100644 (file)
Binary files a/src/runtime/race/race_darwin_amd64.syso and b/src/runtime/race/race_darwin_amd64.syso differ
index df1bc26861af9090a26b35d4bf1422ae19c2d6d9..6312ce8f35d8d1c2e43898609d55109e6a7c6168 100644 (file)
Binary files a/src/runtime/race/race_freebsd_amd64.syso and b/src/runtime/race/race_freebsd_amd64.syso differ
index 174033041ed4a6f584e7b74f13194244dea7e9cc..3795520c9b25e69378b6a37053cb2a0a313a383f 100644 (file)
Binary files a/src/runtime/race/race_linux_amd64.syso and b/src/runtime/race/race_linux_amd64.syso differ
index fd93959af5eb78d1903adaa712ab21224cf8580e..b85f5d6e9bec0a12ff5af6bada0ffa9f14f62ae1 100644 (file)
Binary files a/src/runtime/race/race_windows_amd64.syso and b/src/runtime/race/race_windows_amd64.syso differ