]> Cypherpunks repositories - gostls13.git/commit
runtime: print a message on bad morestack
authorAustin Clements <austin@google.com>
Thu, 13 Oct 2016 14:44:57 +0000 (10:44 -0400)
committerAustin Clements <austin@google.com>
Mon, 17 Oct 2016 18:56:09 +0000 (18:56 +0000)
commit687d9d5d78f8a2d09b2052e73be0c83740e17fda
treed8aa74b0a3aea918b939be3aad6fda4c5d4e0946
parent0ba3c607dfcc90072191375d57c4059be1ae96c7
runtime: print a message on bad morestack

If morestack runs on the g0 or gsignal stack, it currently performs
some abort operation that typically produces a signal (e.g., it does
an INT $3 on x86). This is useful if you're running in a debugger, but
if you're not, the runtime tries to trap this signal, which is likely
to send the program into a deeper spiral of collapse and lead to very
confusing diagnostic output.

Help out people trying to debug without a debugger by making morestack
print an informative message before blowing up.

Change-Id: I2814c64509b137bfe20a00091d8551d18c2c4749
Reviewed-on: https://go-review.googlesource.com/31133
Run-TryBot: Austin Clements <austin@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Rick Hudson <rlh@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/runtime/asm_386.s
src/runtime/asm_amd64.s
src/runtime/asm_amd64p32.s
src/runtime/asm_arm.s
src/runtime/asm_arm64.s
src/runtime/asm_mips64x.s
src/runtime/asm_ppc64x.s
src/runtime/asm_s390x.s
src/runtime/proc.go