Skip to content

Commit

Permalink
Fix ptr/nonptr bitmask for globals.
Browse files Browse the repository at this point in the history
  • Loading branch information
randall77 committed Sep 19, 2017
1 parent eabef37 commit ac8f264
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion gocore/object.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ func (p *Program) readObjects() {
for _, s := range [2]string{"data", "bss"} {
min := core.Address(m.r.Field(s).Uintptr())
max := core.Address(m.r.Field("e" + s).Uintptr())
gc := core.Address(m.r.Field("gc" + s).Uintptr())
gc := m.r.Field("gc" + s + "mask").Field("bytedata").Address()
n := max.Sub(min) / ptrSize
for i := int64(0); i < n; i++ {
if p.proc.ReadUint8(gc.Add(i/8))>>uint(i%8)&1 != 0 {
Expand Down

0 comments on commit ac8f264

Please sign in to comment.