Bug 231184 - Sandbox complexity and performance improvements
Summary: Sandbox complexity and performance improvements
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Brent Fulgham
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-10-04 11:44 PDT by Brent Fulgham
Modified: 2021-10-12 12:03 PDT (History)
6 users (show)

See Also:


Attachments
Patch (56.94 KB, patch)
2021-10-04 11:49 PDT, Brent Fulgham
no flags Details | Formatted Diff | Diff
Patch for landing (56.73 KB, patch)
2021-10-12 10:34 PDT, Brent Fulgham
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Brent Fulgham 2021-10-04 11:44:53 PDT
The Sandbox team suggested a number of improvements to our sandbox:

1. Minimize regex usage
Better to use enumerate individual names than grouping similar names into regexes. This is a performance improvement.

2. Remove duplicate rules

3. Remove 'defined?' checks for the many things that are supported in all WebKit target OSes.

These will simplify the rules, and should provide some launch time improvement.
Comment 1 Brent Fulgham 2021-10-04 11:45:14 PDT
<rdar://problem/47565664>
Comment 2 Brent Fulgham 2021-10-04 11:49:31 PDT
Created attachment 440083 [details]
Patch
Comment 3 Brent Fulgham 2021-10-04 15:01:40 PDT
Tested on macOS and iOS on device (including streaming video).
Comment 4 Per Arne Vollan 2021-10-12 08:42:32 PDT
Comment on attachment 440083 [details]
Patch

R=me.
Comment 5 Per Arne Vollan 2021-10-12 08:45:38 PDT
Comment on attachment 440083 [details]
Patch

Should we also start collecting telemetry for the properties seldom seen? There might be many obsolete properties by now. That falls outside the scope of this patch, however.
Comment 6 EWS 2021-10-12 09:27:55 PDT
Tools/Scripts/svn-apply failed to apply attachment 440083 [details] to trunk.
Please resolve the conflicts and upload a new patch.
Comment 7 Brent Fulgham 2021-10-12 10:34:54 PDT
Created attachment 440956 [details]
Patch for landing
Comment 8 EWS 2021-10-12 12:03:20 PDT
Committed r283998 (242842@main): <https://commits.webkit.org/242842@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 440956 [details].