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

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

Issue 785443002: Fix gc on MIPS (live registers were spilled in reversed order). (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years 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 | Annotate | Revision Log
« no previous file with comments | « runtime/vm/assembler_x64.cc ('k') | runtime/vm/flow_graph_compiler_arm64.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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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_ARM. 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_ARM.
6 #if defined(TARGET_ARCH_ARM) 6 #if defined(TARGET_ARCH_ARM)
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 1446 matching lines...) Expand 10 before | Expand all | Expand 10 after
1457 Register reg = static_cast<Register>(reg_idx); 1457 Register reg = static_cast<Register>(reg_idx);
1458 if (locs->live_registers()->ContainsRegister(reg)) { 1458 if (locs->live_registers()->ContainsRegister(reg)) {
1459 __ Push(reg); 1459 __ Push(reg);
1460 } 1460 }
1461 } 1461 }
1462 } 1462 }
1463 1463
1464 1464
1465 void FlowGraphCompiler::RestoreLiveRegisters(LocationSummary* locs) { 1465 void FlowGraphCompiler::RestoreLiveRegisters(LocationSummary* locs) {
1466 // General purpose registers have the highest register number at the 1466 // General purpose registers have the highest register number at the
1467 // lowest address. The order in which the registers are popped must match the 1467 // lowest address.
1468 // order in which the registers are pushed in SaveLiveRegisters.
1469 for (intptr_t reg_idx = kNumberOfCpuRegisters - 1; reg_idx >= 0; --reg_idx) { 1468 for (intptr_t reg_idx = kNumberOfCpuRegisters - 1; reg_idx >= 0; --reg_idx) {
1470 Register reg = static_cast<Register>(reg_idx); 1469 Register reg = static_cast<Register>(reg_idx);
1471 if (locs->live_registers()->ContainsRegister(reg)) { 1470 if (locs->live_registers()->ContainsRegister(reg)) {
1472 __ Pop(reg); 1471 __ Pop(reg);
1473 } 1472 }
1474 } 1473 }
1475 1474
1476 const intptr_t fpu_regs_count = locs->live_registers()->FpuRegisterCount(); 1475 const intptr_t fpu_regs_count = locs->live_registers()->FpuRegisterCount();
1477 if (fpu_regs_count > 0) { 1476 if (fpu_regs_count > 0) {
1478 // Fpu registers have the lowest register number at the lowest address. 1477 // Fpu registers have the lowest register number at the lowest address.
(...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after
1840 DRegister dreg = EvenDRegisterOf(reg); 1839 DRegister dreg = EvenDRegisterOf(reg);
1841 __ vldrd(dreg, Address(SP, kDoubleSize, Address::PostIndex)); 1840 __ vldrd(dreg, Address(SP, kDoubleSize, Address::PostIndex));
1842 } 1841 }
1843 1842
1844 1843
1845 #undef __ 1844 #undef __
1846 1845
1847 } // namespace dart 1846 } // namespace dart
1848 1847
1849 #endif // defined TARGET_ARCH_ARM 1848 #endif // defined TARGET_ARCH_ARM
OLDNEW
« no previous file with comments | « runtime/vm/assembler_x64.cc ('k') | runtime/vm/flow_graph_compiler_arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698