diff options
author | Ian Lance Taylor <ian@gcc.gnu.org> | 2019-02-19 15:32:34 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@gcc.gnu.org> | 2019-02-19 15:32:34 +0000 |
commit | 6bd37418a378bec4916ad70403375af00df91938 (patch) | |
tree | 6cc264135130829edd8bf0fa234f727d4f929cc6 /gcc | |
parent | 23c4471ee530a7a752ca8c7eff111aaa39e8d118 (diff) | |
download | gcc-6bd37418a378bec4916ad70403375af00df91938.zip gcc-6bd37418a378bec4916ad70403375af00df91938.tar.gz gcc-6bd37418a378bec4916ad70403375af00df91938.tar.bz2 |
runtime: abort stack scan in cases that we cannot unwind the stack
In signal-triggered stack scan, if the signal is delivered at
certain bad time (e.g. in vdso, or in the middle of setcontext?),
the unwinder may not be able to unwind the whole stack, while it
still reports _URC_END_OF_STACK. So we cannot rely on _URC_END_OF_STACK
to tell if it successfully scanned the stack. Instead, we check
the last Go frame to see it actually reached the end of the stack.
For Go-created stack, this is runtime.kickoff. For C-created
stack, we need to record the outermost Go frame when it enters
the Go side.
Also we cannot unwind the stack if the signal is delivered in the
middle of runtime.gogo, halfway through a goroutine switch, where
the g and the stack don't match. Give up in this case as well.
Reviewed-on: https://go-review.googlesource.com/c/159098
From-SVN: r269018
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/go/gofrontend/MERGE | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/go/gofrontend/MERGE b/gcc/go/gofrontend/MERGE index d9ee0ba..07437d4 100644 --- a/gcc/go/gofrontend/MERGE +++ b/gcc/go/gofrontend/MERGE @@ -1,4 +1,4 @@ -9605c2efd99aa9c744652a9153e208e0653b8596 +672572130ba7a7b277a4c9c8f93576fc42accf63 The first line of this file holds the git revision number of the last merge done from the gofrontend repository. |