Bug 225059 - [Cocoa] Improve memory efficiency of Sandbox operations
Summary: [Cocoa] Improve memory efficiency of Sandbox operations
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-04-26 09:58 PDT by Brent Fulgham
Modified: 2021-04-26 14:21 PDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Brent Fulgham 2021-04-26 09:58:56 PDT
We have a number of places in WebKit where we generate sandbox extensions to hand to other processes. These frequently involve creating Vectors of strings that are held for the lifetime of the UIProcess.

We could do a better job by switching from Vector<ASCILiteral> to something like std::initializer_list<ASCIILiteral>. We don't use the various powers of these Vectors beyond being a container that we can iterate through.

We should teach the Sandbox classes to consume these data types, and avoid holding onto this memory during the long stretches of time when they are not used.
Comment 1 Brent Fulgham 2021-04-26 09:59:19 PDT
Based on some review comments Darin left in Bug 225004.
Comment 2 Radar WebKit Bug Importer 2021-04-26 10:00:13 PDT
<rdar://problem/77162420>