Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(235)

Unified Diff: src/snapshot/code-serializer.h

Issue 2305903002: [wasm] reuse the first compiled module (Closed)
Patch Set: GC before cloning Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/runtime/runtime-wasm.cc ('k') | src/snapshot/code-serializer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/snapshot/code-serializer.h
diff --git a/src/snapshot/code-serializer.h b/src/snapshot/code-serializer.h
index e82a7d5dd6d5787582263f850981e0988d3f8b22..b3c54d1c8479182e991990d5482d4cc7189032d5 100644
--- a/src/snapshot/code-serializer.h
+++ b/src/snapshot/code-serializer.h
@@ -36,6 +36,7 @@ class CodeSerializer : public Serializer {
UNREACHABLE();
}
+ virtual bool ElideObject(Object* obj) { return false; }
void SerializeGeneric(HeapObject* heap_object, HowToCode how_to_code,
WhereToPoint where_to_point);
@@ -73,6 +74,8 @@ class WasmCompiledModuleSerializer : public CodeSerializer {
}
}
+ bool ElideObject(Object* obj) override { return obj->IsWeakCell(); };
+
private:
WasmCompiledModuleSerializer(Isolate* isolate, uint32_t source_hash)
: CodeSerializer(isolate, source_hash) {}
« no previous file with comments | « src/runtime/runtime-wasm.cc ('k') | src/snapshot/code-serializer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698