| OLD | NEW |
| 1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 | 5 |
| 6 | 6 |
| 7 #include "v8.h" | 7 #include "v8.h" |
| 8 | 8 |
| 9 #if V8_TARGET_ARCH_MIPS | 9 #if V8_TARGET_ARCH_MIPS |
| 10 | 10 |
| (...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 156 // Now that the break point has been handled, resume normal execution by | 156 // Now that the break point has been handled, resume normal execution by |
| 157 // jumping to the target address intended by the caller and that was | 157 // jumping to the target address intended by the caller and that was |
| 158 // overwritten by the address of DebugBreakXXX. | 158 // overwritten by the address of DebugBreakXXX. |
| 159 __ li(t9, Operand( | 159 __ li(t9, Operand( |
| 160 ExternalReference(Debug_Address::AfterBreakTarget(), masm->isolate()))); | 160 ExternalReference(Debug_Address::AfterBreakTarget(), masm->isolate()))); |
| 161 __ lw(t9, MemOperand(t9)); | 161 __ lw(t9, MemOperand(t9)); |
| 162 __ Jump(t9); | 162 __ Jump(t9); |
| 163 } | 163 } |
| 164 | 164 |
| 165 | 165 |
| 166 void Debug::GenerateCallICStubDebugBreak(MacroAssembler* masm) { |
| 167 // Register state for CallICStub |
| 168 // ----------- S t a t e ------------- |
| 169 // -- a1 : function |
| 170 // -- a3 : slot in feedback array (smi) |
| 171 // ----------------------------------- |
| 172 Generate_DebugBreakCallHelper(masm, a1.bit() | a3.bit(), 0); |
| 173 } |
| 174 |
| 175 |
| 166 void Debug::GenerateLoadICDebugBreak(MacroAssembler* masm) { | 176 void Debug::GenerateLoadICDebugBreak(MacroAssembler* masm) { |
| 167 // Calling convention for IC load (from ic-mips.cc). | 177 // Calling convention for IC load (from ic-mips.cc). |
| 168 // ----------- S t a t e ------------- | 178 // ----------- S t a t e ------------- |
| 169 // -- a2 : name | 179 // -- a2 : name |
| 170 // -- ra : return address | 180 // -- ra : return address |
| 171 // -- a0 : receiver | 181 // -- a0 : receiver |
| 172 // -- [sp] : receiver | 182 // -- [sp] : receiver |
| 173 // ----------------------------------- | 183 // ----------------------------------- |
| 174 // Registers a0 and a2 contain objects that need to be pushed on the | 184 // Registers a0 and a2 contain objects that need to be pushed on the |
| 175 // expression stack of the fake JS frame. | 185 // expression stack of the fake JS frame. |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 212 | 222 |
| 213 void Debug::GenerateCompareNilICDebugBreak(MacroAssembler* masm) { | 223 void Debug::GenerateCompareNilICDebugBreak(MacroAssembler* masm) { |
| 214 // Register state for CompareNil IC | 224 // Register state for CompareNil IC |
| 215 // ----------- S t a t e ------------- | 225 // ----------- S t a t e ------------- |
| 216 // -- a0 : value | 226 // -- a0 : value |
| 217 // ----------------------------------- | 227 // ----------------------------------- |
| 218 Generate_DebugBreakCallHelper(masm, a0.bit(), 0); | 228 Generate_DebugBreakCallHelper(masm, a0.bit(), 0); |
| 219 } | 229 } |
| 220 | 230 |
| 221 | 231 |
| 222 void Debug::GenerateCallICDebugBreak(MacroAssembler* masm) { | |
| 223 // Calling convention for IC call (from ic-mips.cc). | |
| 224 // ----------- S t a t e ------------- | |
| 225 // -- a2: name | |
| 226 // ----------------------------------- | |
| 227 Generate_DebugBreakCallHelper(masm, a2.bit(), 0); | |
| 228 } | |
| 229 | |
| 230 | |
| 231 void Debug::GenerateReturnDebugBreak(MacroAssembler* masm) { | 232 void Debug::GenerateReturnDebugBreak(MacroAssembler* masm) { |
| 232 // In places other than IC call sites it is expected that v0 is TOS which | 233 // In places other than IC call sites it is expected that v0 is TOS which |
| 233 // is an object - this is not generally the case so this should be used with | 234 // is an object - this is not generally the case so this should be used with |
| 234 // care. | 235 // care. |
| 235 Generate_DebugBreakCallHelper(masm, v0.bit(), 0); | 236 Generate_DebugBreakCallHelper(masm, v0.bit(), 0); |
| 236 } | 237 } |
| 237 | 238 |
| 238 | 239 |
| 239 void Debug::GenerateCallFunctionStubDebugBreak(MacroAssembler* masm) { | 240 void Debug::GenerateCallFunctionStubDebugBreak(MacroAssembler* masm) { |
| 240 // Register state for CallFunctionStub (from code-stubs-mips.cc). | 241 // Register state for CallFunctionStub (from code-stubs-mips.cc). |
| 241 // ----------- S t a t e ------------- | 242 // ----------- S t a t e ------------- |
| 242 // -- a1 : function | 243 // -- a1 : function |
| 243 // ----------------------------------- | 244 // ----------------------------------- |
| 244 Generate_DebugBreakCallHelper(masm, a1.bit(), 0); | 245 Generate_DebugBreakCallHelper(masm, a1.bit(), 0); |
| 245 } | 246 } |
| 246 | 247 |
| 247 | 248 |
| 248 void Debug::GenerateCallFunctionStubRecordDebugBreak(MacroAssembler* masm) { | |
| 249 // Register state for CallFunctionStub (from code-stubs-mips.cc). | |
| 250 // ----------- S t a t e ------------- | |
| 251 // -- a1 : function | |
| 252 // -- a2 : feedback array | |
| 253 // -- a3 : slot in feedback array | |
| 254 // ----------------------------------- | |
| 255 Generate_DebugBreakCallHelper(masm, a1.bit() | a2.bit() | a3.bit(), 0); | |
| 256 } | |
| 257 | |
| 258 | |
| 259 void Debug::GenerateCallConstructStubDebugBreak(MacroAssembler* masm) { | 249 void Debug::GenerateCallConstructStubDebugBreak(MacroAssembler* masm) { |
| 260 // Calling convention for CallConstructStub (from code-stubs-mips.cc). | 250 // Calling convention for CallConstructStub (from code-stubs-mips.cc). |
| 261 // ----------- S t a t e ------------- | 251 // ----------- S t a t e ------------- |
| 262 // -- a0 : number of arguments (not smi) | 252 // -- a0 : number of arguments (not smi) |
| 263 // -- a1 : constructor function | 253 // -- a1 : constructor function |
| 264 // ----------------------------------- | 254 // ----------------------------------- |
| 265 Generate_DebugBreakCallHelper(masm, a1.bit() , a0.bit()); | 255 Generate_DebugBreakCallHelper(masm, a1.bit() , a0.bit()); |
| 266 } | 256 } |
| 267 | 257 |
| 268 | 258 |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 310 } | 300 } |
| 311 | 301 |
| 312 | 302 |
| 313 const bool Debug::kFrameDropperSupported = false; | 303 const bool Debug::kFrameDropperSupported = false; |
| 314 | 304 |
| 315 #undef __ | 305 #undef __ |
| 316 | 306 |
| 317 } } // namespace v8::internal | 307 } } // namespace v8::internal |
| 318 | 308 |
| 319 #endif // V8_TARGET_ARCH_MIPS | 309 #endif // V8_TARGET_ARCH_MIPS |
| OLD | NEW |