| OLD | NEW |
| 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_X64. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_X64. |
| 6 #if defined(TARGET_ARCH_X64) | 6 #if defined(TARGET_ARCH_X64) |
| 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 1424 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1435 __ popq(left); | 1435 __ popq(left); |
| 1436 } else { | 1436 } else { |
| 1437 __ cmpl(left, right); | 1437 __ cmpl(left, right); |
| 1438 } | 1438 } |
| 1439 } | 1439 } |
| 1440 | 1440 |
| 1441 | 1441 |
| 1442 // This function must be in sync with FlowGraphCompiler::RecordSafepoint and | 1442 // This function must be in sync with FlowGraphCompiler::RecordSafepoint and |
| 1443 // FlowGraphCompiler::SlowPathEnvironmentFor. | 1443 // FlowGraphCompiler::SlowPathEnvironmentFor. |
| 1444 void FlowGraphCompiler::SaveLiveRegisters(LocationSummary* locs) { | 1444 void FlowGraphCompiler::SaveLiveRegisters(LocationSummary* locs) { |
| 1445 #if defined(DEBUG) |
| 1446 locs->CheckWritableInputs(); |
| 1447 #endif |
| 1448 |
| 1445 // TODO(vegorov): avoid saving non-volatile registers. | 1449 // TODO(vegorov): avoid saving non-volatile registers. |
| 1446 __ PushRegisters(locs->live_registers()->cpu_registers(), | 1450 __ PushRegisters(locs->live_registers()->cpu_registers(), |
| 1447 locs->live_registers()->fpu_registers()); | 1451 locs->live_registers()->fpu_registers()); |
| 1448 } | 1452 } |
| 1449 | 1453 |
| 1450 | 1454 |
| 1451 void FlowGraphCompiler::RestoreLiveRegisters(LocationSummary* locs) { | 1455 void FlowGraphCompiler::RestoreLiveRegisters(LocationSummary* locs) { |
| 1452 __ PopRegisters(locs->live_registers()->cpu_registers(), | 1456 __ PopRegisters(locs->live_registers()->cpu_registers(), |
| 1453 locs->live_registers()->fpu_registers()); | 1457 locs->live_registers()->fpu_registers()); |
| 1454 } | 1458 } |
| (...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1722 __ movups(reg, Address(RSP, 0)); | 1726 __ movups(reg, Address(RSP, 0)); |
| 1723 __ AddImmediate(RSP, Immediate(kFpuRegisterSize), PP); | 1727 __ AddImmediate(RSP, Immediate(kFpuRegisterSize), PP); |
| 1724 } | 1728 } |
| 1725 | 1729 |
| 1726 | 1730 |
| 1727 #undef __ | 1731 #undef __ |
| 1728 | 1732 |
| 1729 } // namespace dart | 1733 } // namespace dart |
| 1730 | 1734 |
| 1731 #endif // defined TARGET_ARCH_X64 | 1735 #endif // defined TARGET_ARCH_X64 |
| OLD | NEW |