• Keith Randall's avatar
    runtime: print stack of G during a signal · 4b78c957
    Keith Randall authored
    Sequence of operations:
    - Go code does a systemstack call
    - during the systemstack call, receive a signal
    - signal requests a traceback of all goroutines
    
    The orignal G is still marked as _Grunning, so the traceback code
    refuses to print its stack.
    
    Fix by allowing traceback of Gs whose caller is on the same M as G is.
    G can't be modifying its stack if that is the case.
    
    Fixes #10546
    
    Change-Id: I2bcea48c0197fbf78ab6fa080027cd80181083ad
    Reviewed-on: https://go-review.googlesource.com/9435Reviewed-by: 's avatarIan Lance Taylor <iant@golang.org>
    4b78c957
traceback.go 21 KB