-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Panic when running Wasm gc program #9669
Comments
Nick is on vacation right now so this may need to wait until he's back. |
Thanks for filing an issue and providing a As I just mentioned in another issue, at this moment the default collector (DRC) does not yet transitively decrement reference counts, so many acyclic garbage objects will be leaked (in this case, the array objects referenced from This acyclic leakage is not fundamental nor intended long term, it just reflects that this is a young, WIP implementation. (Cycles will always leak with this collector, on the other hand, since it is a simple reference-counting collector and does not include a cycle collector.) |
Ah but I see that I didn't read closely enough, and that this is finding a stack map issue, which the panic is a symptom of. This is a separate issue, unrelated to the leakage. |
I ran into what appears to be the same issue. It only seems to occur for the Minimized test case:
|
The minimized test case is super helpful, thanks! I've been running |
Err whoops I've actually been trying to minimize #9714, not this issue's test case. |
I'm not completely sure this is the same issue, but this small module fails in the same way. (module
(type $0 (sub (struct)))
(type $1 (func (result (ref eq))))
(global $global$0 (ref eq) (struct.new_default $0))
(export "" (func $0))
(func $0 (result (ref eq))
(local $0 (ref eq))
(local.set $0
(struct.new_default $0)
)
(drop
(global.get $global$0)
)
(local.get $0)
)
) |
Thanks so much for working on implementing the gc proposal! When I tested it on my own small language I ran into a panic and managed to minify the example down to:
Test Case
Minimal reproduction:
Panics with:
Versions and Environment
Wasmtime version or commit: 27.0.0
Operating system: Verified on Windows and Mac
Architecture: x86_64 and arm64
The text was updated successfully, but these errors were encountered: