OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 #ifndef V8_MIPS_CODE_STUBS_MIPS64_H_ | 5 #ifndef V8_MIPS_CODE_STUBS_MIPS64_H_ |
6 #define V8_MIPS_CODE_STUBS_MIPS64_H_ | 6 #define V8_MIPS_CODE_STUBS_MIPS64_H_ |
7 | 7 |
8 #include "src/mips64/frames-mips64.h" | 8 #include "src/mips64/frames-mips64.h" |
9 | 9 |
10 namespace v8 { | 10 namespace v8 { |
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
134 if (Assembler::IsBeq(second_instruction)) { | 134 if (Assembler::IsBeq(second_instruction)) { |
135 return INCREMENTAL_COMPACTION; | 135 return INCREMENTAL_COMPACTION; |
136 } | 136 } |
137 | 137 |
138 DCHECK(Assembler::IsBne(second_instruction)); | 138 DCHECK(Assembler::IsBne(second_instruction)); |
139 | 139 |
140 return STORE_BUFFER_ONLY; | 140 return STORE_BUFFER_ONLY; |
141 } | 141 } |
142 | 142 |
143 static void Patch(Code* stub, Mode mode) { | 143 static void Patch(Code* stub, Mode mode) { |
144 MacroAssembler masm(NULL, | 144 MacroAssembler masm(stub->GetIsolate(), stub->instruction_start(), |
145 stub->instruction_start(), | 145 stub->instruction_size(), CodeObjectRequired::kNo); |
146 stub->instruction_size()); | |
147 switch (mode) { | 146 switch (mode) { |
148 case STORE_BUFFER_ONLY: | 147 case STORE_BUFFER_ONLY: |
149 DCHECK(GetMode(stub) == INCREMENTAL || | 148 DCHECK(GetMode(stub) == INCREMENTAL || |
150 GetMode(stub) == INCREMENTAL_COMPACTION); | 149 GetMode(stub) == INCREMENTAL_COMPACTION); |
151 PatchBranchIntoNop(&masm, 0); | 150 PatchBranchIntoNop(&masm, 0); |
152 PatchBranchIntoNop(&masm, 2 * Assembler::kInstrSize); | 151 PatchBranchIntoNop(&masm, 2 * Assembler::kInstrSize); |
153 break; | 152 break; |
154 case INCREMENTAL: | 153 case INCREMENTAL: |
155 DCHECK(GetMode(stub) == STORE_BUFFER_ONLY); | 154 DCHECK(GetMode(stub) == STORE_BUFFER_ONLY); |
156 PatchNopIntoBranch(&masm, 0); | 155 PatchNopIntoBranch(&masm, 0); |
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
341 | 340 |
342 DEFINE_NULL_CALL_INTERFACE_DESCRIPTOR(); | 341 DEFINE_NULL_CALL_INTERFACE_DESCRIPTOR(); |
343 DEFINE_PLATFORM_CODE_STUB(NameDictionaryLookup, PlatformCodeStub); | 342 DEFINE_PLATFORM_CODE_STUB(NameDictionaryLookup, PlatformCodeStub); |
344 }; | 343 }; |
345 | 344 |
346 | 345 |
347 } // namespace internal | 346 } // namespace internal |
348 } // namespace v8 | 347 } // namespace v8 |
349 | 348 |
350 #endif // V8_MIPS_CODE_STUBS_MIPS64_H_ | 349 #endif // V8_MIPS_CODE_STUBS_MIPS64_H_ |
OLD | NEW |