bytecodealliance / bytecodealliance/wasmtime

Preview1 adapter still imports realtime clocks and timer polls during Go canonical allocation

Open
#14,318 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
18.6k
Forks
1.8k
Avg merge
1d 19h
Merged PRs (30d)
121

Description

Go components can still trap with `cannot leave component instance` when garbage collection runs during `cabi_realloc`.

The pause introduced in #13563 covers monotonic clock reads, but GC also reads wall time and polls timers when restarting the scheduler. Those operations still call host imports, which are forbidden during `cabi_realloc`.

Reproduced with the Wasmtime 48.0.2 adapter and Go 1.26.3/1.27.1. The [regression test](https://github.com/bytecodealliance/componentize-go/pull/78) fails without the fix and passes with it.

Fix: #14319. Follow-up to https://github.com/bytecodealliance/componentize-go/issues/56.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.