Wasm64: Implement basic functionality
Categories
(Core :: JavaScript: WebAssembly, enhancement, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox95 | --- | fixed |
People
(Reporter: lth, Assigned: lth)
References
(Blocks 1 open bug)
Details
Attachments
(9 files, 1 obsolete file)
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review | |
48 bytes,
text/x-phabricator-request
|
Details | Review |
Implement all instructions with basic explicit bounds checking, memories still being limited to 4GB but pointers and offsets being 64 bits. (Initially we'll limit the offsets to 32 bits, as they are now.)
Assignee | ||
Updated•3 years ago
|
Assignee | ||
Comment 1•3 years ago
|
||
Scaffolding: Add assertions everywhere execution currently depends on
a memory being a memory32. These assertions will disappear by and by.
Add some useful predicates and guard memory64 on !huge-memory.
Depends on D124808
Assignee | ||
Comment 2•3 years ago
|
||
Implement 64-bit memory.grow and memory.size.
Introduce the suffixes M32 and M64 on instance call signatures to
disambiguate them properly. Rewrite existing ad-hoc suffixes
(typically just '32') to use the new ones.
Differentiate 64-bit instance call methods from ditto 32-bit with the
'_m32' and '_m64' syntax. Rewrite some existing '_i32' and '_i64'
cases to use the new syntax.
Depends on D124887
Updated•3 years ago
|
Assignee | ||
Comment 3•3 years ago
|
||
Bulk memory operations need better / more test cases but are otherwise considered done.
Assignee | ||
Comment 4•3 years ago
|
||
Depends on D124888
Updated•3 years ago
|
Assignee | ||
Comment 5•3 years ago
|
||
Depends on D124888
Assignee | ||
Comment 6•3 years ago
|
||
Assignee | ||
Comment 7•3 years ago
|
||
Depends on D125524
Updated•3 years ago
|
Updated•3 years ago
|
Updated•3 years ago
|
Assignee | ||
Comment 8•3 years ago
|
||
Whether a memory is huge depends not just on whether huge memory
has been enabled in the process, but whether the memory's index
type allows the use of huge-memory optimization. (And in the
future it may depend on eg whether the memory, if it is i64,
has a declared maximum.) This fundamentally means that the
is-huge-memory attribute cannot be computed before compilation
starts but must be computed once the memory has been declared.
To make this simple, we parameterize IsHugeMemoryEnabled() by
the index type, and plumb the index type through the code where
we need it (not too many places). Features::hugeMemory can now
be removed.
The main issue with this is that IsHugeMemoryEnabled() becomes
fairly hot, yet it takes a multi-reader / single-writer lock
(that is never contended for writes, so should be fairly close
to optimal). If this becomes a bottleneck, we can read and
cache the value, or we can turn the lock into some relaxed
atomic, since the lock only controls a couple of bools and
everything would fit in a single word.
Assignee | ||
Comment 9•3 years ago
|
||
Depends on D124887
Assignee | ||
Comment 10•3 years ago
|
||
Depends on D126187
Assignee | ||
Comment 11•3 years ago
|
||
Depends on D125524
Assignee | ||
Comment 12•3 years ago
|
||
Status as of latest queue: Functionally complete and passes all tests on x64 + arm64. Missing Ion support for memory instructions on x86 and arm32.
Updated•3 years ago
|
Updated•3 years ago
|
Updated•3 years ago
|
Updated•3 years ago
|
Updated•3 years ago
|
Updated•3 years ago
|
Updated•3 years ago
|
Updated•3 years ago
|
Updated•3 years ago
|
Updated•3 years ago
|
Comment 13•3 years ago
|
||
Pushed by lhansen@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/5315e548b651 Memory64 - Huge-memory status depends on index type. r=yury https://hg.mozilla.org/integration/autoland/rev/63ce829d63b4 Memory64 - Preliminaries. r=yury https://hg.mozilla.org/integration/autoland/rev/d13d8c76693a Memory64 - Allow larger-than-4GB allocations. r=yury https://hg.mozilla.org/integration/autoland/rev/359e414a1d7f Memory64 - Expose the index type via js-types. r=yury https://hg.mozilla.org/integration/autoland/rev/b9d32ef0ad83 Memory64 - Bulk memory operations. r=yury https://hg.mozilla.org/integration/autoland/rev/6089b4360edc Memory64 - Non-atomic-RMW baseline operations. r=yury https://hg.mozilla.org/integration/autoland/rev/1ab8383d17ee Memory64 - Atomic-rmw baseline operations. r=yury https://hg.mozilla.org/integration/autoland/rev/27db0e6a7010 Memory64 - Ion operations. r=yury https://hg.mozilla.org/integration/autoland/rev/25456db35c17 Memory64 - Test cases and testing code. r=yury
Comment 14•3 years ago
|
||
Backed our for causing spidermonkey bustages on WasmMemory.cpp. CLOSED TREE
Backout link : https://hg.mozilla.org/integration/autoland/rev/b01a275e79a1d6b0ad5cc23a8ea96a539b0d451e
Link to failure log : https://treeherder.mozilla.org/logviewer?job_id=355128092&repo=autoland&lineNumber=8987
Assignee | ||
Comment 15•3 years ago
|
||
That was a weird bug after so many try runs, but just a header file missing.
Comment 16•3 years ago
|
||
Pushed by lhansen@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/83e52246d0ea Memory64 - Huge-memory status depends on index type. r=yury https://hg.mozilla.org/integration/autoland/rev/339e37a04ca1 Memory64 - Preliminaries. r=yury https://hg.mozilla.org/integration/autoland/rev/caca657178e4 Memory64 - Allow larger-than-4GB allocations. r=yury https://hg.mozilla.org/integration/autoland/rev/b658cfe4b173 Memory64 - Expose the index type via js-types. r=yury https://hg.mozilla.org/integration/autoland/rev/13ee9674ee35 Memory64 - Bulk memory operations. r=yury https://hg.mozilla.org/integration/autoland/rev/fb02656bb788 Memory64 - Non-atomic-RMW baseline operations. r=yury https://hg.mozilla.org/integration/autoland/rev/44b0c0bed8a6 Memory64 - Atomic-rmw baseline operations. r=yury https://hg.mozilla.org/integration/autoland/rev/3e40bdd11ab5 Memory64 - Ion operations. r=yury https://hg.mozilla.org/integration/autoland/rev/80388e7f335c Memory64 - Test cases and testing code. r=yury
Comment 17•3 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/83e52246d0ea
https://hg.mozilla.org/mozilla-central/rev/339e37a04ca1
https://hg.mozilla.org/mozilla-central/rev/caca657178e4
https://hg.mozilla.org/mozilla-central/rev/b658cfe4b173
https://hg.mozilla.org/mozilla-central/rev/13ee9674ee35
https://hg.mozilla.org/mozilla-central/rev/fb02656bb788
https://hg.mozilla.org/mozilla-central/rev/44b0c0bed8a6
https://hg.mozilla.org/mozilla-central/rev/3e40bdd11ab5
https://hg.mozilla.org/mozilla-central/rev/80388e7f335c
Description
•