Skip to content

Commit

Permalink
Fix error in Web embedding desc for atomic.notify (#185)
Browse files Browse the repository at this point in the history
In #110 we changed the `count` argument of `atomic.notify` so that it is treated as an unsigned `i32`. Previous to this change, it was interpreted as a signed `i32`, with negative numbers signalling that all threads should be woken. This part of the overview wasn't fully updated - fixing this now.
  • Loading branch information
conrad-watt authored Dec 14, 2021
1 parent 0d115b4 commit 85b562c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions proposals/threads/Overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -436,8 +436,7 @@ For the web embedding, `memory.atomic.notify` is equivalent in behavior to execu
1. Let `memory` be a `WebAssembly.Memory` object for this module.
1. Let `buffer` be `memory`([`Get`][](`memory`, `"buffer"`)).
1. Let `int32array` be [`Int32Array`][](`buffer`).
1. Let `fcount` be `count` if `count` is >= 0, otherwise ``.
1. Let `result` be [`Atomics.notify`][](`int32array`, `address`, `fcount`).
1. Let `result` be [`Atomics.notify`][](`int32array`, `address`, `count`).
1. Return `result` converted to an `i32`.

## Fence operator
Expand Down

0 comments on commit 85b562c

Please sign in to comment.