diff options
| author | Dmitriy Vyukov <dvyukov@google.com> | 2013-06-13 16:38:44 +0400 |
|---|---|---|
| committer | Dmitriy Vyukov <dvyukov@google.com> | 2013-06-13 16:38:44 +0400 |
| commit | e2d95c1f24cd32607458ba5d5bef689f2ee7b00e (patch) | |
| tree | a7e4c17cd8104c1d4d22728973d27a469b2bb304 /src/pkg/runtime/slice.c | |
| parent | 591d58a3bb9ea3afea0c898564d972b822212674 (diff) | |
| download | go-e2d95c1f24cd32607458ba5d5bef689f2ee7b00e.tar.xz | |
runtime/race: remove now unused step parameter from range access functions
R=golang-dev, dave
CC=golang-dev
https://golang.org/cl/10259043
Diffstat (limited to 'src/pkg/runtime/slice.c')
| -rw-r--r-- | src/pkg/runtime/slice.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/pkg/runtime/slice.c b/src/pkg/runtime/slice.c index fe1290d63c..3adbe51837 100644 --- a/src/pkg/runtime/slice.c +++ b/src/pkg/runtime/slice.c @@ -82,12 +82,12 @@ runtime·appendslice(SliceType *t, Slice x, Slice y, Slice ret) pc = runtime·getcallerpc(&t); // read x[:len] if(m > x.cap) - runtime·racereadrangepc(x.array, x.len*w, w, pc, runtime·appendslice); + runtime·racereadrangepc(x.array, x.len*w, pc, runtime·appendslice); // read y - runtime·racereadrangepc(y.array, y.len*w, w, pc, runtime·appendslice); + runtime·racereadrangepc(y.array, y.len*w, pc, runtime·appendslice); // write x[len(x):len(x)+len(y)] if(m <= x.cap) - runtime·racewriterangepc(ret.array+ret.len*w, y.len*w, w, pc, runtime·appendslice); + runtime·racewriterangepc(ret.array+ret.len*w, y.len*w, pc, runtime·appendslice); } // A very common case is appending bytes. Small appends can avoid the overhead of memmove. @@ -138,10 +138,10 @@ runtime·appendstr(SliceType *t, Slice x, String y, Slice ret) pc = runtime·getcallerpc(&t); // read x[:len] if(m > x.cap) - runtime·racereadrangepc(x.array, x.len, 1, pc, runtime·appendstr); + runtime·racereadrangepc(x.array, x.len, pc, runtime·appendstr); // write x[len(x):len(x)+len(y)] if(m <= x.cap) - runtime·racewriterangepc(ret.array+ret.len, y.len, 1, pc, runtime·appendstr); + runtime·racewriterangepc(ret.array+ret.len, y.len, pc, runtime·appendstr); } // Small appends can avoid the overhead of memmove. @@ -176,7 +176,7 @@ runtime·growslice(SliceType *t, Slice old, int64 n, Slice ret) if(raceenabled) { pc = runtime·getcallerpc(&t); - runtime·racereadrangepc(old.array, old.len*t->elem->size, t->elem->size, pc, runtime·growslice); + runtime·racereadrangepc(old.array, old.len*t->elem->size, pc, runtime·growslice); } growslice1(t, old, cap, &ret); @@ -234,8 +234,8 @@ runtime·copy(Slice to, Slice fm, uintptr width, intgo ret) if(raceenabled) { pc = runtime·getcallerpc(&to); - runtime·racewriterangepc(to.array, ret*width, width, pc, runtime·copy); - runtime·racereadrangepc(fm.array, ret*width, width, pc, runtime·copy); + runtime·racewriterangepc(to.array, ret*width, pc, runtime·copy); + runtime·racereadrangepc(fm.array, ret*width, pc, runtime·copy); } if(ret == 1 && width == 1) { // common case worth about 2x to do here @@ -277,7 +277,7 @@ runtime·slicestringcopy(Slice to, String fm, intgo ret) if(raceenabled) { pc = runtime·getcallerpc(&to); - runtime·racewriterangepc(to.array, ret, 1, pc, runtime·slicestringcopy); + runtime·racewriterangepc(to.array, ret, pc, runtime·slicestringcopy); } runtime·memmove(to.array, fm.str, ret); |
