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

Unified Diff: runtime/vm/raw_object_snapshot.cc

Issue 1857273002: Fix detection if a function was compiled, (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Comments Created 4 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 | « runtime/vm/raw_object.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/raw_object_snapshot.cc
diff --git a/runtime/vm/raw_object_snapshot.cc b/runtime/vm/raw_object_snapshot.cc
index 7c861e21d9b899202ade1251ef9852659973e44f..e8fcf69a2f044ac590e51f3e12dafd0929b68fad 100644
--- a/runtime/vm/raw_object_snapshot.cc
+++ b/runtime/vm/raw_object_snapshot.cc
@@ -733,10 +733,11 @@ RawFunction* Function::ReadFrom(SnapshotReader* reader,
func.set_optimized_call_site_count(0);
} else {
func.set_usage_counter(reader->Read<int32_t>());
- func.set_deoptimization_counter(reader->Read<int16_t>());
+ func.set_deoptimization_counter(reader->Read<int8_t>());
func.set_optimized_instruction_count(reader->Read<uint16_t>());
func.set_optimized_call_site_count(reader->Read<uint16_t>());
}
+ func.set_was_compiled(false);
// Set all the object fields.
READ_OBJECT_FIELDS(func,
@@ -814,7 +815,7 @@ void RawFunction::WriteTo(SnapshotWriter* writer,
} else {
writer->Write<int32_t>(0);
}
- writer->Write<int16_t>(ptr()->deoptimization_counter_);
+ writer->Write<int8_t>(ptr()->deoptimization_counter_);
writer->Write<uint16_t>(ptr()->optimized_instruction_count_);
writer->Write<uint16_t>(ptr()->optimized_call_site_count_);
}
« no previous file with comments | « runtime/vm/raw_object.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698