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

Unified Diff: runtime/vm/clustered_snapshot.cc

Issue 2686813006: Reapply "Use CodeSourceMap for stack traces (still JIT only)." (Closed)
Patch Set: Created 3 years, 10 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 | « runtime/tests/vm/dart/inline_stack_frame_test.dart ('k') | runtime/vm/code_descriptors.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/clustered_snapshot.cc
diff --git a/runtime/vm/clustered_snapshot.cc b/runtime/vm/clustered_snapshot.cc
index 162df5aba3a525e12cbdd3af297aad8795c69983..7c7a061b631cc525b181394d4baf3f20048c9b5d 100644
--- a/runtime/vm/clustered_snapshot.cc
+++ b/runtime/vm/clustered_snapshot.cc
@@ -1571,7 +1571,8 @@ class CodeSerializationCluster : public SerializationCluster {
if (s->kind() == Snapshot::kAppJIT) {
s->Push(code->ptr()->deopt_info_array_);
s->Push(code->ptr()->static_calls_target_table_);
- NOT_IN_PRODUCT(s->Push(code->ptr()->inlined_id_to_function_));
+ s->Push(code->ptr()->inlined_id_to_function_);
+ s->Push(code->ptr()->code_source_map_);
NOT_IN_PRODUCT(s->Push(code->ptr()->return_address_metadata_));
}
}
@@ -1624,7 +1625,8 @@ class CodeSerializationCluster : public SerializationCluster {
if (s->kind() == Snapshot::kAppJIT) {
s->WriteRef(code->ptr()->deopt_info_array_);
s->WriteRef(code->ptr()->static_calls_target_table_);
- NOT_IN_PRODUCT(s->WriteRef(code->ptr()->inlined_id_to_function_));
+ s->WriteRef(code->ptr()->inlined_id_to_function_);
+ s->WriteRef(code->ptr()->code_source_map_);
NOT_IN_PRODUCT(s->WriteRef(code->ptr()->return_address_metadata_));
}
@@ -1696,23 +1698,24 @@ class CodeDeserializationCluster : public DeserializationCluster {
reinterpret_cast<RawArray*>(d->ReadRef());
code->ptr()->static_calls_target_table_ =
reinterpret_cast<RawArray*>(d->ReadRef());
+ code->ptr()->inlined_id_to_function_ =
+ reinterpret_cast<RawArray*>(d->ReadRef());
+ code->ptr()->code_source_map_ =
+ reinterpret_cast<RawCodeSourceMap*>(d->ReadRef());
#if defined(PRODUCT)
- code->ptr()->inlined_id_to_function_ = Array::null();
code->ptr()->return_address_metadata_ = Object::null();
#else
- code->ptr()->inlined_id_to_function_ =
- reinterpret_cast<RawArray*>(d->ReadRef());
code->ptr()->return_address_metadata_ = d->ReadRef();
#endif
} else {
code->ptr()->deopt_info_array_ = Array::null();
code->ptr()->static_calls_target_table_ = Array::null();
code->ptr()->inlined_id_to_function_ = Array::null();
+ code->ptr()->code_source_map_ = CodeSourceMap::null();
code->ptr()->return_address_metadata_ = Object::null();
}
code->ptr()->var_descriptors_ = LocalVarDescriptors::null();
- code->ptr()->code_source_map_ = CodeSourceMap::null();
code->ptr()->comments_ = Array::null();
code->ptr()->compile_timestamp_ = 0;
@@ -4545,6 +4548,8 @@ SerializationCluster* Serializer::NewClusterForClass(intptr_t cid) {
return new (Z) ObjectPoolSerializationCluster();
case kPcDescriptorsCid:
return new (Z) RODataSerializationCluster(kPcDescriptorsCid);
+ case kCodeSourceMapCid:
+ return new (Z) RODataSerializationCluster(kCodeSourceMapCid);
case kStackMapCid:
return new (Z) RODataSerializationCluster(kStackMapCid);
case kExceptionHandlersCid:
@@ -4910,6 +4915,7 @@ DeserializationCluster* Deserializer::ReadCluster() {
case kObjectPoolCid:
return new (Z) ObjectPoolDeserializationCluster();
case kPcDescriptorsCid:
+ case kCodeSourceMapCid:
case kStackMapCid:
return new (Z) RODataDeserializationCluster();
case kExceptionHandlersCid:
« no previous file with comments | « runtime/tests/vm/dart/inline_stack_frame_test.dart ('k') | runtime/vm/code_descriptors.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698