Stream: git-wasmtime

Topic: wasmtime / PR #5858 wasi-threads: fix use of `wait` in test


view this post on Zulip Wasmtime GitHub notifications bot (Feb 23 2023 at 00:08):

abrown opened PR #5858 from fix-threads-test to main:

As @yamt points out [here], the wait/notify pairing used in this manual WAT test was not effective. The wait always immediately returned, meaning that the main thread essentially spins until a counter is atomically incremented. This is fine for test correctness, but was not the original intent, which was lost in a refactoring. This change uses the $i local to keep track of the counter value we expect to see for the wait, so that the wait/notify pair actually waits as expected.

[here]: https://github.com/bytecodealliance/wasmtime/pull/5484#discussion_r1101200012

<!--

Please ensure that the following steps are all taken care of before submitting
the PR.

Please ensure all communication adheres to the code of conduct.
-->

view this post on Zulip Wasmtime GitHub notifications bot (Feb 23 2023 at 15:23):

alexcrichton submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Feb 23 2023 at 16:16):

alexcrichton merged PR #5858.


Last updated: Oct 23 2024 at 20:03 UTC