You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It looks like gentraceback() is called from scanstack() (not sure why). It gets confused because the JIT code is calling back into Go, so it can't fully reconstruct the traceback.
Any idea on how to work around this? My JIT code uses some stack (it's actually forced to do so, to pass arguments and save registers while calling back into Go).
The text was updated successfully, but these errors were encountered:
rasky
changed the title
runtime: "missing stackmap" for JIT-generated code
runtime: "unexpected return pc" with JIT-generated code
Apr 25, 2017
So you're JITing code that runs on the Go stack? Not cgo or anything?
All stack frames on the Go stack must have stack frame descriptors registered with the runtime, so the garbage collector knows how to find pointers in them. It will barf if it can't find a descriptor for the frame. You'd need to register descriptors somehow. The runtime has some support for that in the form of plugin loading.
I'd rather not classify this as an issue, there's nothing here for the Go team to fix, for now at least. We don't support JITed code :) I'm going to close this and advise taking this discussion to golang-dev.
While experimenting writing a JIT in Go (1.8), I found that the runtime complaints about the fact that my JIT-generated code does not have a stackmap.
This seems to happen in some background goroutine doing GC work. This is the full traceback:
It looks like
gentraceback()
is called fromscanstack()
(not sure why). It gets confused because the JIT code is calling back into Go, so it can't fully reconstruct the traceback.Any idea on how to work around this? My JIT code uses some stack (it's actually forced to do so, to pass arguments and save registers while calling back into Go).
The text was updated successfully, but these errors were encountered: