diff options
author | R?my Oudompheng <oudomphe@phare.normalesup.org> | 2013-06-14 11:14:45 +0200 |
---|---|---|
committer | R?my Oudompheng <oudomphe@phare.normalesup.org> | 2013-06-14 11:14:45 +0200 |
commit | bb665158525bb95362213b246d29ae8a00e9f819 (patch) | |
tree | 25efc98e913710b016848493336bad57742c5673 /src/cmd/gc/builtin.c | |
parent | f817b1751f23350f3d1d8d37f813e269cd7631fd (diff) | |
download | go-bb665158525bb95362213b246d29ae8a00e9f819.tar.gz |
cmd/gc: instrument arrays properly in race detector.
The previous implementation would only record access to
the address of the array but the memory access to the whole
memory range must be recorded instead.
R=golang-dev, dvyukov, r
CC=golang-dev
https://codereview.appspot.com/8053044
Diffstat (limited to 'src/cmd/gc/builtin.c')
-rw-r--r-- | src/cmd/gc/builtin.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/cmd/gc/builtin.c b/src/cmd/gc/builtin.c index 9053dfe10..baa7d7845 100644 --- a/src/cmd/gc/builtin.c +++ b/src/cmd/gc/builtin.c @@ -113,6 +113,8 @@ char *runtimeimport = "func @\"\".racefuncexit ()\n" "func @\"\".raceread (? uintptr)\n" "func @\"\".racewrite (? uintptr)\n" + "func @\"\".racereadrange (@\"\".addr·1 uintptr, @\"\".size·2 uintptr)\n" + "func @\"\".racewriterange (@\"\".addr·1 uintptr, @\"\".size·2 uintptr)\n" "\n" "$$\n"; char *unsafeimport = |