You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit a5999be
Browse filesBrowse the repository at this point in the historyBrowse files
IOW, share them per process, instead of duplicating them for each
NativeModule. Detailed changes:
- The WasmImportWrapperCache is promoted from having an instance per
NativeModule to having an instance per WasmEngine. It also gets its
own code space for storing wrappers.
- Wrapper compilation functions now return a WasmCompilationResult
instead of an already-published WasmCode, so that callers can decide
where to put the WasmCode. That is done, specifically, by the
WasmImportWrapperCache.
- WasmCode objects used for wrappers now don't have a NativeModule,
i.e. their native_module_ == nullptr.
- Whereas wrappers previously had their lifetime implicitly tied to the
NativeModule that owned them, we must now accurately track their
refcount.
- To this end, WasmDispatchTables get an off-heap WasmDispatchTableData,
which keeps track of all wrappers referenced by the table. Storing
this information off-heap is necessary so that it's still available
when the table's finalizer is invoked (at which time the table itself
can no longer be accessed).
Using shared wrappers for WasmJSFunctions is left for a future patch.
Bug: 42204526
Change-Id: I59d044b5d461a0e7ae8937e7965bd7e44f58b402
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/5783527
Reviewed-by: Matthias Liedtke <[email protected]>
Reviewed-by: Michael Lippautz <[email protected]>
Commit-Queue: Jakob Kummerow <[email protected]>
Cr-Commit-Position: refs/heads/main@{#95828}
0 commit comments