From 4d226dfee9d08a1e39cab5fe03b4d820b4a75d56 Mon Sep 17 00:00:00 2001 From: Russ Cox Date: Wed, 14 Jan 2015 21:47:49 -0500 Subject: runtime: move write barrier code into mbarrier.go I also added new comments at the top of mbarrier.go, but the rest of the code is just copy-and-paste. Change-Id: Iaeb2b12f8b1eaa33dbff5c2de676ca902bfddf2e Reviewed-on: https://go-review.googlesource.com/2990 Reviewed-by: Austin Clements --- src/runtime/stack1.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/runtime/stack1.go') diff --git a/src/runtime/stack1.go b/src/runtime/stack1.go index 743e1073c6..0f31a32e7f 100644 --- a/src/runtime/stack1.go +++ b/src/runtime/stack1.go @@ -22,7 +22,6 @@ const ( const ( uintptrMask = 1<<(8*ptrSize) - 1 - poisonGC = uintptrMask & 0xf969696969696969 poisonStack = uintptrMask & 0x6868686868686868 // Goroutine preemption request. @@ -389,7 +388,7 @@ func adjustpointers(scanp unsafe.Pointer, cbv *bitvector, adjinfo *adjustinfo, f case _BitsPointer: p := *(*unsafe.Pointer)(add(scanp, i*ptrSize)) up := uintptr(p) - if f != nil && 0 < up && up < _PageSize && debug.invalidptr != 0 || up == poisonGC || up == poisonStack { + if f != nil && 0 < up && up < _PageSize && debug.invalidptr != 0 || up == poisonStack { // Looks like a junk value in a pointer slot. // Live analysis wrong? getg().m.traceback = 2 -- cgit v1.3-5-g9baa