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

Unified Diff: runtime/vm/simulator_dbc.cc

Issue 2479463003: DBC: Fix fast-path allocation with type arguments (Closed)
Patch Set: Created 4 years, 1 month 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 | « no previous file | tests/language/language.status » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/simulator_dbc.cc
diff --git a/runtime/vm/simulator_dbc.cc b/runtime/vm/simulator_dbc.cc
index 8e84784dd0200ac9e7d682bf3eb25178ad36d946..c02e1bfcaa5dfe5e11de27f647c661240756c608 100644
--- a/runtime/vm/simulator_dbc.cc
+++ b/runtime/vm/simulator_dbc.cc
@@ -2802,12 +2802,12 @@ RawObject* Simulator::Call(const Code& code,
RawObject* type_args = SP[0];
const intptr_t type_args_offset = Bytecode::DecodeD(*pc);
*reinterpret_cast<uword*>(start + Instance::tags_offset()) = tags;
- *reinterpret_cast<RawObject**>(start + type_args_offset) = type_args;
for (intptr_t current_offset = sizeof(RawInstance);
current_offset < instance_size;
current_offset += kWordSize) {
*reinterpret_cast<RawObject**>(start + current_offset) = null_value;
}
+ *reinterpret_cast<RawObject**>(start + type_args_offset) = type_args;
FP[rA] = reinterpret_cast<RawObject*>(start + kHeapObjectTag);
SP -= 1; // Consume the type arguments on the stack.
pc += 4;
« no previous file with comments | « no previous file | tests/language/language.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698