Update AsyncModuleExecution{Fulfilled,Rejected} to latest spec steps
Categories
(Core :: JavaScript Engine, task, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox104 | --- | fixed |
People
(Reporter: jonco, Assigned: jonco)
References
(Blocks 1 open bug)
Details
Attachments
(3 files)
Following on from bug 1777972, I'd like to update AsyncModuleExecutionFulfilled and AsyncModuleExecutionRejected to the latest spec and add the spec steps in comments so we can easily check our implementation.
One issue I came across was that the spec now leaves AsyncEvaluation field set to true after evaluation has finished. That's a problem for our current implementation because we use a runtime-wide counter to assign an order to async evaluating modules, and to prevent overflow this counter is reset when the last module finishes evaluation and sets this field to false.
Assignee | ||
Comment 1•2 years ago
|
||
(In reply to Jon Coppeard (:jonco) from comment #0)
the spec now leaves AsyncEvaluation field set to true after evaluation has finished
It turns out this doesn't happen everywhere so I'm now a bit confused as to how this works.
Updated•2 years ago
|
Assignee | ||
Comment 2•2 years ago
|
||
GatherAvailableModuleAncestors is also now local to Modules.cpp.
Assignee | ||
Comment 3•2 years ago
|
||
Currently our implementation sets the async evaluating flag to false at the end
of execution. This patch does not change this yet as it's a convenient point to
reset the moduleAsyncEvaluatingPostOrder counter, so this diverges from the
spec.
I'll file a followup bug to address this.
Depends on D151716
Assignee | ||
Comment 4•2 years ago
|
||
As for the previous patch, we still set async evaluating to false after execution.
Depends on D151717
Comment 6•2 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/3e7850e36813
https://hg.mozilla.org/mozilla-central/rev/685b4d3a7811
https://hg.mozilla.org/mozilla-central/rev/8f537ef57b2e
Description
•