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

Unified Diff: src/snapshot/serialize.cc

Issue 1092253003: Fix serialization statistics for external strings. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 8 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/snapshot/serialize.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/snapshot/serialize.cc
diff --git a/src/snapshot/serialize.cc b/src/snapshot/serialize.cc
index 9aac959a10b92e5631d97efb744fc38028c8c0af..3fbf5908e0e6f696eedb6fcd3503ecc44e33e8f4 100644
--- a/src/snapshot/serialize.cc
+++ b/src/snapshot/serialize.cc
@@ -1246,10 +1246,10 @@ Serializer::~Serializer() {
#ifdef OBJECT_PRINT
-void Serializer::CountInstanceType(HeapObject* obj) {
- int instance_type = obj->map()->instance_type();
+void Serializer::CountInstanceType(Map* map, int size) {
+ int instance_type = map->instance_type();
instance_type_count_[instance_type]++;
- instance_type_size_[instance_type] += obj->Size();
+ instance_type_size_[instance_type] += size;
}
#endif // OBJECT_PRINT
@@ -1696,7 +1696,7 @@ void Serializer::ObjectSerializer::SerializePrologue(AllocationSpace space,
#ifdef OBJECT_PRINT
if (FLAG_serialization_statistics) {
- serializer_->CountInstanceType(object_);
+ serializer_->CountInstanceType(map, size);
}
#endif // OBJECT_PRINT
« no previous file with comments | « src/snapshot/serialize.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698