Hi,
A few 'print' statements in runtime for diagnosing result in panic like the
following, what could be the root cause? any alternatives to display g's
value?
Thanks a lot.
1 g := getg() // existing code
2 print(g, g.stack.lo, g.stack.hi) // new line
runtime: newstack at runtime.printlock+0x7c sp=0x400074cc40
stack=[0x40008d8000, 0x40008da000]
morebuf={pc:0x51bf8 sp:0x400074cc40 lr:0x0}
sched={pc:0x3dfdc sp:0x400074cc40 lr:0x51bf8 ctxt:0x0}
runtime.sigtrampgo(0x11, 0x400074cda0, 0x400074ce20)
runtime.sigtrampgo(0x11, 0x40003dcda0, 0x40003dce20)
........
fatal error: runtime: stack split at bad time
runtime: newstack at runtime.printlock+0x7c sp=0x4000442c40
stack=[0x4000818000, 0x400081a000]
morebuf={pc:0x51bf8 sp:0x4000442c40 lr:0x0}
sched={pc:0x3dfdc sp:0x4000442c40 lr:0x51bf8 ctxt:0x0}
runtime.sigtrampgo(0x11, 0x4000442da0, 0x4000442e20)
--
You received this message because you are subscribed to the Google Groups
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/golang-nuts/8e384613-ceea-47c6-a66f-69016d264021%40googlegroups.com.