| 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 // Declares a Simulator for MIPS instructions if we are not generating a native | 5 // Declares a Simulator for MIPS instructions if we are not generating a native |
| 6 // MIPS binary. This Simulator allows us to run and debug MIPS code generation | 6 // MIPS binary. This Simulator allows us to run and debug MIPS code generation |
| 7 // on regular desktop machines. | 7 // on regular desktop machines. |
| 8 // Dart calls into generated code by "calling" the InvokeDartCode stub, | 8 // Dart calls into generated code by "calling" the InvokeDartCode stub, |
| 9 // which will start execution in the Simulator or forwards to the real entry | 9 // which will start execution in the Simulator or forwards to the real entry |
| 10 // on a MIPS HW platform. | 10 // on a MIPS HW platform. |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 int32_t parameter2, | 108 int32_t parameter2, |
| 109 int32_t parameter3, | 109 int32_t parameter3, |
| 110 bool fp_return = false, | 110 bool fp_return = false, |
| 111 bool fp_args = false); | 111 bool fp_args = false); |
| 112 | 112 |
| 113 // Runtime and native call support. | 113 // Runtime and native call support. |
| 114 enum CallKind { | 114 enum CallKind { |
| 115 kRuntimeCall, | 115 kRuntimeCall, |
| 116 kLeafRuntimeCall, | 116 kLeafRuntimeCall, |
| 117 kLeafFloatRuntimeCall, | 117 kLeafFloatRuntimeCall, |
| 118 kBootstrapNativeCall, |
| 118 kNativeCall | 119 kNativeCall |
| 119 }; | 120 }; |
| 120 static uword RedirectExternalReference(uword function, | 121 static uword RedirectExternalReference(uword function, |
| 121 CallKind call_kind, | 122 CallKind call_kind, |
| 122 int argument_count); | 123 int argument_count); |
| 123 | 124 |
| 124 void Longjmp(uword pc, | 125 void Longjmp(uword pc, |
| 125 uword sp, | 126 uword sp, |
| 126 uword fp, | 127 uword fp, |
| 127 RawObject* raw_exception, | 128 RawObject* raw_exception, |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 209 } | 210 } |
| 210 | 211 |
| 211 friend class SimulatorDebugger; | 212 friend class SimulatorDebugger; |
| 212 friend class SimulatorSetjmpBuffer; | 213 friend class SimulatorSetjmpBuffer; |
| 213 DISALLOW_COPY_AND_ASSIGN(Simulator); | 214 DISALLOW_COPY_AND_ASSIGN(Simulator); |
| 214 }; | 215 }; |
| 215 | 216 |
| 216 } // namespace dart | 217 } // namespace dart |
| 217 | 218 |
| 218 #endif // VM_SIMULATOR_MIPS_H_ | 219 #endif // VM_SIMULATOR_MIPS_H_ |
| OLD | NEW |