@@ -51,13 +51,13 @@ of [atomic instructions][atomics]. In Rust parlance this means that
51
51
[ ` AtomicUsize ` ] and friends will actually compile to atomic operations, whereas
52
52
today they're [ simply lowered to single-threaded equivalents] [ wasm-singlethread ]
53
53
(as there's no threads!). While essential, these aren't too too thrilling just
54
- yet until you hit [ ` wait ` and ` wake ` ] [ wait-and-wake ] .
54
+ yet until you hit [ ` wait ` and ` notify ` ] [ wait-and-notify ] .
55
55
56
56
Atomic modifications allow us to perform some level of synchronization, but
57
57
full synchronization often requires actual blocking of a thread until another is
58
- finished. This is where the ` i32.atomic.wait ` and ` atomic.wake ` instructions
58
+ finished. This is where the ` i32.atomic.wait ` and ` atomic.notify ` instructions
59
59
come into play. First we can block a thread (atomically) using
60
- [ ` i32.atomic.wait ` ] , and then another thread can execute [ ` atomic.wake ` ] to wake
60
+ [ ` i32.atomic.wait ` ] , and then another thread can execute [ ` atomic.notify ` ] to wake
61
61
up a thread blocked on the same address. I believe this is similar to [ futexes]
62
62
on Linux, although I've never used them myself!
63
63
@@ -632,9 +632,9 @@ Discord](https://discord.gg/6SHrCn), or follow along on GitHub with either
632
632
[ ray-patches ] : https://github.com/alexcrichton/raytracer/compare/master...update-deps
633
633
[ firefox-spec-bug ] : https://bugzilla.mozilla.org/show_bug.cgi?id=1496582
634
634
[ dlmalloc ] : https://github.com/alexcrichton/dlmalloc-rs
635
- [ wait-and-wake ] : https://github.com/WebAssembly/threads/blob/master/proposals/threads/Overview.md#wait-and-wake -operators
635
+ [ wait-and-notify ] : https://github.com/WebAssembly/threads/blob/master/proposals/threads/Overview.md#wait-and-notify -operators
636
636
[ `i32.atomic.wait` ] : https://github.com/WebAssembly/threads/blob/master/proposals/threads/Overview.md#wait
637
- [ `atomic.wake ` ] : https://github.com/WebAssembly/threads/blob/master/proposals/threads/Overview.md#wake
637
+ [ `atomic.notify ` ] : https://github.com/WebAssembly/threads/blob/master/proposals/threads/Overview.md#notify
638
638
[ `ArrayBuffer` ] : https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer
639
639
[ `Arc` ] : https://doc.rust-lang.org/std/sync/struct.Arc.html
640
640
[ `start` ] : http://webassembly.github.io/spec/core/syntax/modules.html#start-function
0 commit comments