Worklets should read from Preferences for JS ContextOptions
Categories
(Core :: DOM: Core & HTML, task)
Tracking
()
People
(Reporter: rhunt, Assigned: jandem)
References
Details
Attachments
(1 file)
48 bytes,
text/x-phabricator-request
|
RyanVM
:
approval-mozilla-esr115+
|
Details | Review |
See bug 1851468. It looks like WorkletThread does not use xpc::SetPrefableContextOptions
or equivalent when creating a JSContext. This means that JS/wasm features cannot be changed via preference for worklets.
Comment 1•2 years ago
|
||
It is confusing, but worklets are handled by DOM: Core & HTML.
Comment 2•2 years ago
|
||
Currently bug 1851468 switches exceptions feature to Default. It will be nice to revert it back with this patch.
Assignee | ||
Comment 3•2 years ago
|
||
SetPrefableContextOptions
currently has to be called on the main thread, so store
the options in StartModuleLoadRunnable
and copy them on the worklet thread.
This doesn't update the options when the prefs are changed, but we've been moving
to read-on-startup for prefs so we probably don't need that.
Updated•2 years ago
|
Updated•2 years ago
|
Comment 5•2 years ago
|
||
bugherder |
Assignee | ||
Comment 6•2 years ago
|
||
Comment on attachment 9352198 [details]
Bug 1851854 - Use SetPrefableContextOptions for worklet JS ContextOptions. r?mccr8!
ESR Uplift Approval Request
- If this is not a sec:{high,crit} bug, please state case for ESR consideration: It's a small and safe patch that fixes some of our JS prefs to also apply to worklets. For example, if someone disables WebAssembly, without this patch we'd still have it enabled for worklets, and this is a footgun.
- User impact if declined: See above. Some prefs not applying to worklets.
- Fix Landed on Version: 119
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky):
Comment 7•2 years ago
|
||
Comment on attachment 9352198 [details]
Bug 1851854 - Use SetPrefableContextOptions for worklet JS ContextOptions. r?mccr8!
I assume we'd want to get this to Beta for 118 also?
Assignee | ||
Comment 8•2 years ago
|
||
To clarify:
- Bug 1851468 fixed a regression introduced in Firefox 117 for the Wasm exception handling feature.
- The patch in this bug fixes the more general (and older) worklet issue of (some) JS prefs not being applied to worklet threads.
Comment 9•2 years ago
|
||
Comment on attachment 9352198 [details]
Bug 1851854 - Use SetPrefableContextOptions for worklet JS ContextOptions. r?mccr8!
Removing the beta uplift approval given the context given by Jan.
Updated•2 years ago
|
Comment 10•1 years ago
|
||
Comment on attachment 9352198 [details]
Bug 1851854 - Use SetPrefableContextOptions for worklet JS ContextOptions. r?mccr8!
Approved for 115.4esr
Comment 11•1 years ago
|
||
uplift |
Updated•1 years ago
|
Description
•