@@ -400,23 +400,14 @@ For the web embedding, `memory.atomic.wait32` is equivalent in behavior to execu
400
400
1 . Return an ` i32 ` value as described in the above table:
401
401
("ok" -> ` 0 ` , "not-equal" -> ` 1 ` , "timed-out" -> ` 2 ` ).
402
402
403
- ` memory.atomic.wait64 ` has no equivalent in ECMAScript as it is currently specified, as there is
404
- no ` Int64Array ` type, and an ECMAScript ` Number ` cannot represent all values of a
405
- 64-bit integer. That said, the behavior can be approximated as follows:
403
+ Similarly, ` memory.atomic.wait64 ` is equivalent in behavior to executing the following:
406
404
407
405
1 . Let ` memory ` be a ` WebAssembly.Memory ` object for this module.
408
406
1 . Let ` buffer ` be ` memory ` ([ ` Get ` ] [ ] (` memory ` , ` "buffer" ` )).
409
- 1 . Let ` int64array ` be ` Int64Array ` [ ] ( `buffer` ) , where ` Int64Array ` is a
410
- typed-array constructor that allows 64-bit integer views with an element size
411
- of ` 8 ` .
407
+ 1 . Let ` int64array ` be ` BigInt64Array ` [ ] ( `buffer` )
412
408
1 . Let ` result ` be [ ` Atomics.wait ` ] [ ] (` int64array ` , ` address ` , ` expected ` , ` timeout ` / 1e6),
413
409
where ` address ` , ` expected ` , and ` timeout ` are the operands to the ` wait ` operator
414
- as described above. The [ ` Atomics.wait ` ] [ ] operation is modified:
415
- 1 . ` ValidateSharedIntegerTypedArray ` will fail if the typed-array type is not an
416
- ` Int64Array ` .
417
- 1 . ` value ` is not converted to an ` Int32 ` , but kept in a 64-bit integer
418
- representation.
419
- 1 . ` indexedPosition ` is (` i ` x 8) + ` offset `
410
+ as described above.
420
411
1 . Return an ` i32 ` value as described in the above table:
421
412
("ok" -> ` 0 ` , "not-equal" -> ` 1 ` , "timed-out" -> ` 2 ` ).
422
413
0 commit comments