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

Side by Side Diff: runtime/vm/assembler_x64.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 | « no previous file | runtime/vm/flow_graph_compiler_arm.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" 5 #include "vm/globals.h"
6 #if defined(TARGET_ARCH_X64) 6 #if defined(TARGET_ARCH_X64)
7 7
8 #include "vm/assembler.h" 8 #include "vm/assembler.h"
9 #include "vm/cpu.h" 9 #include "vm/cpu.h"
10 #include "vm/heap.h" 10 #include "vm/heap.h"
(...skipping 3191 matching lines...) Expand 10 before | Expand all | Expand 10 after
3202 XmmRegister xmm_reg = static_cast<XmmRegister>(reg_idx); 3202 XmmRegister xmm_reg = static_cast<XmmRegister>(reg_idx);
3203 if (RegisterSet::Contains(xmm_register_set, xmm_reg)) { 3203 if (RegisterSet::Contains(xmm_register_set, xmm_reg)) {
3204 movups(Address(RSP, offset), xmm_reg); 3204 movups(Address(RSP, offset), xmm_reg);
3205 offset += kFpuRegisterSize; 3205 offset += kFpuRegisterSize;
3206 } 3206 }
3207 } 3207 }
3208 ASSERT(offset == (xmm_regs_count * kFpuRegisterSize)); 3208 ASSERT(offset == (xmm_regs_count * kFpuRegisterSize));
3209 } 3209 }
3210 3210
3211 // Store general purpose registers with the highest register number at the 3211 // Store general purpose registers with the highest register number at the
3212 // lowest address. 3212 // lowest address. The order in which the registers are pushed must match the
3213 // order in which the registers are encoded in the safe point's stack map.
3213 for (intptr_t reg_idx = 0; reg_idx < kNumberOfCpuRegisters; ++reg_idx) { 3214 for (intptr_t reg_idx = 0; reg_idx < kNumberOfCpuRegisters; ++reg_idx) {
3214 Register reg = static_cast<Register>(reg_idx); 3215 Register reg = static_cast<Register>(reg_idx);
3215 if (RegisterSet::Contains(cpu_register_set, reg)) { 3216 if (RegisterSet::Contains(cpu_register_set, reg)) {
3216 pushq(reg); 3217 pushq(reg);
3217 } 3218 }
3218 } 3219 }
3219 } 3220 }
3220 3221
3221 3222
3222 void Assembler::PopRegisters(intptr_t cpu_register_set, 3223 void Assembler::PopRegisters(intptr_t cpu_register_set,
(...skipping 625 matching lines...) Expand 10 before | Expand all | Expand 10 after
3848 3849
3849 3850
3850 const char* Assembler::FpuRegisterName(FpuRegister reg) { 3851 const char* Assembler::FpuRegisterName(FpuRegister reg) {
3851 ASSERT((0 <= reg) && (reg < kNumberOfXmmRegisters)); 3852 ASSERT((0 <= reg) && (reg < kNumberOfXmmRegisters));
3852 return xmm_reg_names[reg]; 3853 return xmm_reg_names[reg];
3853 } 3854 }
3854 3855
3855 } // namespace dart 3856 } // namespace dart
3856 3857
3857 #endif // defined TARGET_ARCH_X64 3858 #endif // defined TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/flow_graph_compiler_arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698