-
Notifications
You must be signed in to change notification settings - Fork 17.5k
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
x/mobile: bind with go1.22.5,1.22.6 leads to: fatal error: runtime: stack split at bad time #68760
Comments
cc @cherrymui @golang/runtime |
This is presumably a bug in https://go.googlesource.com/go/+/3560cf0afb3c29300a6c88ccd98256949ca7a6f6, which is in go1.22.5. @xcolwell could you test with this commit reverted? Something like this should do the trick:
Then build with the toolchain in |
@prattmic that worked. I changed the installed go to the patched on with the below, and verified that the gomobile build worked when using the patched go, and failed when using 1.22.5.
As a summary of what the mobile code looks like, we have a gomobile lib that lets us register callbacks from Kotlin. There is a sequence like below. When the Kotlin callback is called from within the gomobile lib, the first function call back into the gomobile lib crashes with the error.
|
Can confirm. We see the same error but in go1.23: celzero/firestack#84 |
Go version
go version go1.22.5 darwin/arm64
Output of
go env
in your module/workspace:What did you do?
Build a native aar for Android as:
The code has interface callbacks that call from Go -> Kotlin -> Go.
What did you see happen?
Works up to go 1.22.4. On 1.22.5, the interface callback raises the error below. This happens in a Kotlin interface implementation called from Go, that is making another call to Go.
What did you expect to see?
No error.
The text was updated successfully, but these errors were encountered: