OLD | NEW |
1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
73 __ push(reg); | 73 __ push(reg); |
74 __ sar(kScratchRegister, Immediate(32)); | 74 __ sar(kScratchRegister, Immediate(32)); |
75 __ Integer32ToSmi(kScratchRegister, kScratchRegister); | 75 __ Integer32ToSmi(kScratchRegister, kScratchRegister); |
76 __ push(kScratchRegister); | 76 __ push(kScratchRegister); |
77 } | 77 } |
78 } | 78 } |
79 | 79 |
80 #ifdef DEBUG | 80 #ifdef DEBUG |
81 __ RecordComment("// Calling from debug break to runtime - come in - over"); | 81 __ RecordComment("// Calling from debug break to runtime - come in - over"); |
82 #endif | 82 #endif |
83 __ xor_(rax, rax); // No arguments (argc == 0). | 83 __ Set(rax, 0); // No arguments (argc == 0). |
84 __ movq(rbx, ExternalReference::debug_break()); | 84 __ movq(rbx, ExternalReference::debug_break()); |
85 | 85 |
86 CEntryStub ceb(1); | 86 CEntryStub ceb(1); |
87 __ CallStub(&ceb); | 87 __ CallStub(&ceb); |
88 | 88 |
89 // Restore the register values from the expression stack. | 89 // Restore the register values from the expression stack. |
90 for (int i = kNumJSCallerSaved - 1; i >= 0; i--) { | 90 for (int i = kNumJSCallerSaved - 1; i >= 0; i--) { |
91 int r = JSCallerSavedCode(i); | 91 int r = JSCallerSavedCode(i); |
92 Register reg = { r }; | 92 Register reg = { r }; |
93 if (FLAG_debug_code) { | 93 if (FLAG_debug_code) { |
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
303 ASSERT(IsDebugBreakSlot()); | 303 ASSERT(IsDebugBreakSlot()); |
304 rinfo()->PatchCode(original_rinfo()->pc(), Assembler::kDebugBreakSlotLength); | 304 rinfo()->PatchCode(original_rinfo()->pc(), Assembler::kDebugBreakSlotLength); |
305 } | 305 } |
306 | 306 |
307 | 307 |
308 #endif // ENABLE_DEBUGGER_SUPPORT | 308 #endif // ENABLE_DEBUGGER_SUPPORT |
309 | 309 |
310 } } // namespace v8::internal | 310 } } // namespace v8::internal |
311 | 311 |
312 #endif // V8_TARGET_ARCH_X64 | 312 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |