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

Side by Side Diff: runtime/vm/clustered_snapshot.cc

Issue 2316513005: Separate size stats for rodata and instructions. (Closed)
Patch Set: 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 unified diff | Download patch
« no previous file with comments | « no previous file | runtime/vm/snapshot.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/clustered_snapshot.h" 5 #include "vm/clustered_snapshot.h"
6 6
7 #include "platform/assert.h" 7 #include "platform/assert.h"
8 #include "vm/bootstrap.h" 8 #include "vm/bootstrap.h"
9 #include "vm/class_finalizer.h" 9 #include "vm/class_finalizer.h"
10 #include "vm/dart.h" 10 #include "vm/dart.h"
(...skipping 4950 matching lines...) Expand 10 before | Expand all | Expand 10 after
4961 num_base_objects = 0; 4961 num_base_objects = 0;
4962 } 4962 }
4963 4963
4964 WriteIsolateFullSnapshot(num_base_objects); 4964 WriteIsolateFullSnapshot(num_base_objects);
4965 4965
4966 if (Snapshot::IncludesCode(kind_)) { 4966 if (Snapshot::IncludesCode(kind_)) {
4967 instructions_writer_->Write(); 4967 instructions_writer_->Write();
4968 4968
4969 OS::Print("VMIsolate(CodeSize): %" Pd "\n", VmIsolateSnapshotSize()); 4969 OS::Print("VMIsolate(CodeSize): %" Pd "\n", VmIsolateSnapshotSize());
4970 OS::Print("Isolate(CodeSize): %" Pd "\n", IsolateSnapshotSize()); 4970 OS::Print("Isolate(CodeSize): %" Pd "\n", IsolateSnapshotSize());
4971 OS::Print("ReadOnlyData(CodeSize): %" Pd "\n",
4972 instructions_writer_->data_size());
4971 OS::Print("Instructions(CodeSize): %" Pd "\n", 4973 OS::Print("Instructions(CodeSize): %" Pd "\n",
4972 instructions_writer_->binary_size()); 4974 instructions_writer_->text_size());
4973 intptr_t total = VmIsolateSnapshotSize() + 4975 intptr_t total = VmIsolateSnapshotSize() +
4974 IsolateSnapshotSize() + 4976 IsolateSnapshotSize() +
4975 instructions_writer_->binary_size(); 4977 instructions_writer_->data_size() +
4978 instructions_writer_->text_size();
4976 OS::Print("Total(CodeSize): %" Pd "\n", total); 4979 OS::Print("Total(CodeSize): %" Pd "\n", total);
4977 } 4980 }
4978 } 4981 }
4979 4982
4980 4983
4981 RawApiError* IsolateSnapshotReader::ReadFullSnapshot() { 4984 RawApiError* IsolateSnapshotReader::ReadFullSnapshot() {
4982 Deserializer deserializer(thread_, 4985 Deserializer deserializer(thread_,
4983 kind_, 4986 kind_,
4984 buffer_, 4987 buffer_,
4985 size_, 4988 size_,
(...skipping 26 matching lines...) Expand all
5012 5015
5013 deserializer.ReadVMSnapshot(); 5016 deserializer.ReadVMSnapshot();
5014 5017
5015 Dart::set_instructions_snapshot_buffer(instructions_buffer_); 5018 Dart::set_instructions_snapshot_buffer(instructions_buffer_);
5016 Dart::set_data_snapshot_buffer(data_buffer_); 5019 Dart::set_data_snapshot_buffer(data_buffer_);
5017 5020
5018 return ApiError::null(); 5021 return ApiError::null();
5019 } 5022 }
5020 5023
5021 } // namespace dart 5024 } // namespace dart
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/snapshot.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698