-
Notifications
You must be signed in to change notification settings - Fork 17.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
runtime: "runtime: unexpected return pc" when doing CPU profiling on ARM #6681
Labels
Milestone
Comments
Is this a regression? https://golang.org/issue/6015 |
> Is this a regression? https://golang.org/issue/6015 Doesn't look like it. It reproduces with all of: 5ffdb9cc0bfe Tue Oct 29 -- tip 6112d74a00fa Fri Sep 13 -- commit that fixed issue #6015 a5eb738ff649 Fri Aug 02 -- earliest commit that will cross-compile on recent OS X I can do a hg bisect further into the past tomorrow, if that'd be useful. |
Sorry, Dave, I misinterpreted your question as asking whether it was a regression since issue #6015. Dmitry is correct. I checked, and this is a regression from Go 1.1.2. (1.1.2 needs a runtime.Gosched added -- http://play.golang.org/p/q8CxPa5WBa) |
This issue was closed by revision b0db472. Status changed to Fixed. |
This issue was closed by revision b88148b. |
The issue was actually reopened by the revision in #10, which rolled back the fix from #9. I have a new fix on the way. The original fix is still a good idea, just not for Go 1.2. See issue #6699. Status changed to Accepted. |
This issue was closed by revision 2c98a3b. Status changed to Fixed. |
adg
added a commit
that referenced
this issue
May 11, 2015
…ebacks on ARM ««« CL 19910044 / 9eb64f5ef3a6 cmd/5l, runtime: fix divide for profiling tracebacks on ARM Two bugs: 1. The first iteration of the traceback always uses LR when provided, which it is (only) during a profiling signal, but in fact LR is correct only if the stack frame has not been allocated yet. Otherwise an intervening call may have changed LR, and the saved copy in the stack frame should be used. Fix in traceback_arm.c. 2. The division runtime call adds 8 bytes to the stack. In order to keep the traceback routines happy, it must copy the saved LR into the new 0(SP). Change SUB $8, SP into MOVW 0(SP), R11 // r11 is temporary, for use by linker MOVW.W R11, -8(SP) to update SP and 0(SP) atomically, so that the traceback always sees a saved LR at 0(SP). Fixes #6681. R=golang-dev, r CC=golang-dev https://golang.org/cl/19910044 »»» R=golang-dev CC=golang-dev https://golang.org/cl/20170048
CL https://golang.org/cl/12899 mentions this issue. |
rsc
added a commit
that referenced
this issue
Jul 30, 2015
Instead of pushing the denominator argument on the stack, the denominator is now passed in m. This fixes a variety of bugs related to trying to take stack traces backwards from the middle of the software div/mod routines. Some of those bugs have been kludged around in the past, but others have not. Instead of trying to patch up after breaking the stack, this CL stops breaking the stack. This is an update of https://golang.org/cl/19810043, which was rolled back in https://golang.org/cl/20350043. The problem in the original CL was that there were divisions at bad times, when m was not available. These were divisions by constant denominators, either in C code or in assembly. The Go compiler knows how to generate division by multiplication for constant denominators, but the C compiler did not. There is no longer any C code, so that's taken care of. There was one problematic DIV in runtime.usleep (assembly) but https://golang.org/cl/12898 took care of that one. So now this approach is safe. Reject DIV/MOD in NOSPLIT functions to keep them from coming back. Fixes #6681. Fixes #6699. Fixes #10486. Change-Id: I09a13c76ad08ba75b3bd5d46a3eb78e66a84ab38 Reviewed-on: https://go-review.googlesource.com/12899 Reviewed-by: Ian Lance Taylor <iant@golang.org>
This issue was closed.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
The text was updated successfully, but these errors were encountered: