aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/chan.go
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@golang.org>2015-10-21 11:04:42 -0700
committerIan Lance Taylor <iant@golang.org>2015-10-21 19:17:46 +0000
commit73f329f47236c6952235db395802810156a7bd65 (patch)
tree4f26e4e00e448a5d005535cca4b660f8b0922ffb /src/runtime/chan.go
parentc27925094640f0d151da92663d19d511d8dfdc31 (diff)
downloadgo-73f329f47236c6952235db395802810156a7bd65.tar.gz
go-73f329f47236c6952235db395802810156a7bd65.zip
runtime, syscall: add calls to msan functions
Add explicit memory sanitizer instrumentation to the runtime and syscall packages. The compiler does not instrument the runtime package. It does instrument the syscall package, but we need to add a couple of cases that it can't see. Change-Id: I2d66073f713fe67e33a6720460d2bb8f72f31394 Reviewed-on: https://go-review.googlesource.com/16164 Reviewed-by: David Crawshaw <crawshaw@golang.org>
Diffstat (limited to 'src/runtime/chan.go')
-rw-r--r--src/runtime/chan.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/runtime/chan.go b/src/runtime/chan.go
index cfee12a551..96ac306624 100644
--- a/src/runtime/chan.go
+++ b/src/runtime/chan.go
@@ -108,6 +108,9 @@ func chansend(t *chantype, c *hchan, ep unsafe.Pointer, block bool, callerpc uin
if raceenabled {
raceReadObjectPC(t.elem, ep, callerpc, funcPC(chansend))
}
+ if msanenabled {
+ msanread(ep, t.elem.size)
+ }
if c == nil {
if !block {