Add another threadType for wasm tier1/tier2 compile task
Categories
(Core :: JavaScript Engine, task, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox89 | --- | fixed |
People
(Reporter: allstars.chh, Assigned: allstars.chh)
References
Details
Attachments
(1 file)
Right now wasm tier1 and tiew2 compile task share the same thread type: THREAD_TYPE_WASM.
However, they have different priorities when being executed,
https://searchfox.org/mozilla-central/rev/d9f6cded535d202a9ade4a530e653e659bcb5bbd/js/src/vm/HelperThreads.cpp#2656
https://searchfox.org/mozilla-central/rev/d9f6cded535d202a9ade4a530e653e659bcb5bbd/js/src/vm/HelperThreads.cpp#2661
When we dispatch these tasks to the external thread pool (TaskController), we need a way to know either it's from tier1 or tier2 compile task, so we can apply different priorities on them.
I'll add another thread type for this.
Presumably I'll use
THREAD_TYPE_WASM_COMPILE_TIER1,
THREAD_TYPE_WASM_COMPILE_TIER2,
and
rename THREAD_TYPE_WASM_TIER2 to THREAD_TYPE_WASM_GENERATOR_TIER2.
Comment 1•4 years ago
|
||
Looking forward to seeing the results of this, the current "priority" setup has some ugly side effects, see bug 1429953. To do better, we probably need more threads than cores, and a real priority scheme with proper preemption.
Assignee | ||
Comment 2•4 years ago
|
||
Add THREAD_TYPE_WASM_COMPILE_TIER1, THREAD_TYPE_WASM_COMPILE_TIER2 for
tier1/tier2 compile task respectively.
Rename THREAD_TYPE_WASM_TIER2 to THREAD_TYPE_WASM_GENERATOR_TIER2.
Comment 4•4 years ago
|
||
bugherder |
Description
•