]> Cypherpunks repositories - gostls13.git/commit
runtime: make gcDumpObject useful on stack frames
authorAustin Clements <austin@google.com>
Fri, 9 Sep 2016 14:22:10 +0000 (10:22 -0400)
committerAustin Clements <austin@google.com>
Mon, 3 Oct 2016 21:59:54 +0000 (21:59 +0000)
commit38f1df66ff231458a81cb07e7b147f30854b45d4
tree8785e744cbe14e0a70ebc1d0543a939966a75e63
parent6879dbde4e6dceceb272b83fc6682e97b9de2fa1
runtime: make gcDumpObject useful on stack frames

gcDumpObject is often used on a stack pointer (for example, when
checkmark finds an unmarked object on the stack), but since stack
spans don't have an elemsize, it doesn't print any of the memory from
the frame. Make it at least slightly more useful by printing
everything between obj and obj+off (inclusive). While we're here, also
print out the span state.

Change-Id: I51be064ea8791b4a365865bfdc7afa7b5aaecfbd
Reviewed-on: https://go-review.googlesource.com/30142
Run-TryBot: Austin Clements <austin@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Rick Hudson <rlh@golang.org>
src/runtime/mgcmark.go
src/runtime/mheap.go