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

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

Issue 2072823002: VM: Fix frame size computation for optimized DBC code (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 6 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 | « runtime/vm/flow_graph_allocator.cc ('k') | runtime/vm/intermediate_language_dbc.cc » ('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/globals.h" // Needed here to get TARGET_ARCH_DBC. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_DBC.
6 #if defined(TARGET_ARCH_DBC) 6 #if defined(TARGET_ARCH_DBC)
7 7
8 #include "vm/flow_graph_compiler.h" 8 #include "vm/flow_graph_compiler.h"
9 9
10 #include "vm/ast_printer.h" 10 #include "vm/ast_printer.h"
(...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after
230 __ Push(locs->in(0).reg()); 230 __ Push(locs->in(0).reg());
231 __ Push(locs->in(1).reg()); 231 __ Push(locs->in(1).reg());
232 } 232 }
233 __ PushConstant(dst_type); 233 __ PushConstant(dst_type);
234 __ PushConstant(dst_name); 234 __ PushConstant(dst_name);
235 __ AssertAssignable(__ AddConstant(test_cache)); 235 __ AssertAssignable(__ AddConstant(test_cache));
236 RecordSafepoint(locs); 236 RecordSafepoint(locs);
237 AddCurrentDescriptor(RawPcDescriptors::kOther, deopt_id, token_pos); 237 AddCurrentDescriptor(RawPcDescriptors::kOther, deopt_id, token_pos);
238 if (is_optimizing()) { 238 if (is_optimizing()) {
239 // Assert assignable keeps the instance on the stack as the result, 239 // Assert assignable keeps the instance on the stack as the result,
240 // all other arguments are popped. Since there may have been a GC during 240 // all other arguments are popped.
241 // the runtime call, we have to reload the instance. 241 ASSERT(locs->out(0).reg() == locs->in(0).reg());
242 __ PopLocal(locs->out(0).reg()); 242 __ Drop1();
243 } 243 }
244 } 244 }
245 245
246 246
247 void FlowGraphCompiler::EmitInstructionEpilogue(Instruction* instr) { 247 void FlowGraphCompiler::EmitInstructionEpilogue(Instruction* instr) {
248 if (!is_optimizing()) { 248 if (!is_optimizing()) {
249 Definition* defn = instr->AsDefinition(); 249 Definition* defn = instr->AsDefinition();
250 if ((defn != NULL) && 250 if ((defn != NULL) &&
251 (defn->tag() != Instruction::kPushArgument) && 251 (defn->tag() != Instruction::kPushArgument) &&
252 (defn->tag() != Instruction::kStoreIndexed) && 252 (defn->tag() != Instruction::kStoreIndexed) &&
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
496 void ParallelMoveResolver::RestoreFpuScratch(FpuRegister reg) { 496 void ParallelMoveResolver::RestoreFpuScratch(FpuRegister reg) {
497 UNIMPLEMENTED(); 497 UNIMPLEMENTED();
498 } 498 }
499 499
500 500
501 #undef __ 501 #undef __
502 502
503 } // namespace dart 503 } // namespace dart
504 504
505 #endif // defined TARGET_ARCH_DBC 505 #endif // defined TARGET_ARCH_DBC
OLDNEW
« no previous file with comments | « runtime/vm/flow_graph_allocator.cc ('k') | runtime/vm/intermediate_language_dbc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698