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

Side by Side Diff: src/mips/debug-mips.cc

Issue 24108002: MIPS: remove most uses of Isolate::Current in arch specific files. (Closed) Base URL: https://github.com/v8/v8.git@gbl
Patch Set: Created 7 years, 3 months 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
« no previous file with comments | « src/mips/code-stubs-mips.cc ('k') | src/mips/ic-mips.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 // addiu sp, sp, N 53 // addiu sp, sp, N
54 // jr ra 54 // jr ra
55 // nop (in branch delay slot) 55 // nop (in branch delay slot)
56 56
57 // Make sure this constant matches the number if instrucntions we emit. 57 // Make sure this constant matches the number if instrucntions we emit.
58 ASSERT(Assembler::kJSReturnSequenceInstructions == 7); 58 ASSERT(Assembler::kJSReturnSequenceInstructions == 7);
59 CodePatcher patcher(rinfo()->pc(), Assembler::kJSReturnSequenceInstructions); 59 CodePatcher patcher(rinfo()->pc(), Assembler::kJSReturnSequenceInstructions);
60 // li and Call pseudo-instructions emit two instructions each. 60 // li and Call pseudo-instructions emit two instructions each.
61 patcher.masm()->li(v8::internal::t9, 61 patcher.masm()->li(v8::internal::t9,
62 Operand(reinterpret_cast<int32_t>( 62 Operand(reinterpret_cast<int32_t>(
63 Isolate::Current()->debug()->debug_break_return()->entry()))); 63 debug_info_->GetIsolate()->debug()->debug_break_return()->entry())));
64 patcher.masm()->Call(v8::internal::t9); 64 patcher.masm()->Call(v8::internal::t9);
65 patcher.masm()->nop(); 65 patcher.masm()->nop();
66 patcher.masm()->nop(); 66 patcher.masm()->nop();
67 patcher.masm()->nop(); 67 patcher.masm()->nop();
68 68
69 // TODO(mips): Open issue about using breakpoint instruction instead of nops. 69 // TODO(mips): Open issue about using breakpoint instruction instead of nops.
70 // patcher.masm()->bkpt(0); 70 // patcher.masm()->bkpt(0);
71 } 71 }
72 72
73 73
(...skipping 24 matching lines...) Expand all
98 // Patch the code changing the debug break slot code from: 98 // Patch the code changing the debug break slot code from:
99 // nop(DEBUG_BREAK_NOP) - nop(1) is sll(zero_reg, zero_reg, 1) 99 // nop(DEBUG_BREAK_NOP) - nop(1) is sll(zero_reg, zero_reg, 1)
100 // nop(DEBUG_BREAK_NOP) 100 // nop(DEBUG_BREAK_NOP)
101 // nop(DEBUG_BREAK_NOP) 101 // nop(DEBUG_BREAK_NOP)
102 // nop(DEBUG_BREAK_NOP) 102 // nop(DEBUG_BREAK_NOP)
103 // to a call to the debug break slot code. 103 // to a call to the debug break slot code.
104 // li t9, address (lui t9 / ori t9 instruction pair) 104 // li t9, address (lui t9 / ori t9 instruction pair)
105 // call t9 (jalr t9 / nop instruction pair) 105 // call t9 (jalr t9 / nop instruction pair)
106 CodePatcher patcher(rinfo()->pc(), Assembler::kDebugBreakSlotInstructions); 106 CodePatcher patcher(rinfo()->pc(), Assembler::kDebugBreakSlotInstructions);
107 patcher.masm()->li(v8::internal::t9, Operand(reinterpret_cast<int32_t>( 107 patcher.masm()->li(v8::internal::t9, Operand(reinterpret_cast<int32_t>(
108 Isolate::Current()->debug()->debug_break_slot()->entry()))); 108 debug_info_->GetIsolate()->debug()->debug_break_slot()->entry())));
109 patcher.masm()->Call(v8::internal::t9); 109 patcher.masm()->Call(v8::internal::t9);
110 } 110 }
111 111
112 112
113 void BreakLocationIterator::ClearDebugBreakAtSlot() { 113 void BreakLocationIterator::ClearDebugBreakAtSlot() {
114 ASSERT(IsDebugBreakSlot()); 114 ASSERT(IsDebugBreakSlot());
115 rinfo()->PatchCode(original_rinfo()->pc(), 115 rinfo()->PatchCode(original_rinfo()->pc(),
116 Assembler::kDebugBreakSlotInstructions); 116 Assembler::kDebugBreakSlotInstructions);
117 } 117 }
118 118
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
336 const bool Debug::kFrameDropperSupported = false; 336 const bool Debug::kFrameDropperSupported = false;
337 337
338 #undef __ 338 #undef __
339 339
340 340
341 #endif // ENABLE_DEBUGGER_SUPPORT 341 #endif // ENABLE_DEBUGGER_SUPPORT
342 342
343 } } // namespace v8::internal 343 } } // namespace v8::internal
344 344
345 #endif // V8_TARGET_ARCH_MIPS 345 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « src/mips/code-stubs-mips.cc ('k') | src/mips/ic-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698