OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 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 #if V8_TARGET_ARCH_MIPS64 | 5 #if V8_TARGET_ARCH_MIPS64 |
6 | 6 |
7 #include "src/ic/handler-compiler.h" | 7 #include "src/ic/handler-compiler.h" |
8 | 8 |
9 #include "src/api-arguments.h" | 9 #include "src/api-arguments.h" |
10 #include "src/field-type.h" | 10 #include "src/field-type.h" |
(...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
310 ExternalReference::Type type = ExternalReference::DIRECT_API_CALL; | 310 ExternalReference::Type type = ExternalReference::DIRECT_API_CALL; |
311 ExternalReference ref = ExternalReference(&fun, type, masm->isolate()); | 311 ExternalReference ref = ExternalReference(&fun, type, masm->isolate()); |
312 __ li(api_function_address, Operand(ref)); | 312 __ li(api_function_address, Operand(ref)); |
313 | 313 |
314 // Jump to stub. | 314 // Jump to stub. |
315 CallApiCallbackStub stub(isolate, is_store, call_data_undefined, | 315 CallApiCallbackStub stub(isolate, is_store, call_data_undefined, |
316 !optimization.is_constant_call()); | 316 !optimization.is_constant_call()); |
317 __ TailCallStub(&stub); | 317 __ TailCallStub(&stub); |
318 } | 318 } |
319 | 319 |
320 | |
321 static void StoreIC_PushArgs(MacroAssembler* masm) { | |
322 __ Push(StoreDescriptor::ReceiverRegister(), StoreDescriptor::NameRegister(), | |
323 StoreDescriptor::ValueRegister(), | |
324 StoreWithVectorDescriptor::SlotRegister(), | |
325 StoreWithVectorDescriptor::VectorRegister()); | |
326 } | |
327 | |
328 | |
329 void ElementHandlerCompiler::GenerateStoreSlow(MacroAssembler* masm) { | |
330 StoreIC_PushArgs(masm); | |
331 | |
332 // The slow case calls into the runtime to complete the store without causing | |
333 // an IC miss that would otherwise cause a transition to the generic stub. | |
334 __ TailCallRuntime(Runtime::kKeyedStoreIC_Slow); | |
335 } | |
336 | |
337 | |
338 #undef __ | 320 #undef __ |
339 #define __ ACCESS_MASM(masm()) | 321 #define __ ACCESS_MASM(masm()) |
340 | 322 |
341 | 323 |
342 void NamedStoreHandlerCompiler::GenerateRestoreName(Label* label, | 324 void NamedStoreHandlerCompiler::GenerateRestoreName(Label* label, |
343 Handle<Name> name) { | 325 Handle<Name> name) { |
344 if (!label->is_unused()) { | 326 if (!label->is_unused()) { |
345 __ bind(label); | 327 __ bind(label); |
346 __ li(this->name(), Operand(name)); | 328 __ li(this->name(), Operand(name)); |
347 } | 329 } |
(...skipping 334 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
682 // Return the generated code. | 664 // Return the generated code. |
683 return GetCode(kind(), name); | 665 return GetCode(kind(), name); |
684 } | 666 } |
685 | 667 |
686 | 668 |
687 #undef __ | 669 #undef __ |
688 } // namespace internal | 670 } // namespace internal |
689 } // namespace v8 | 671 } // namespace v8 |
690 | 672 |
691 #endif // V8_TARGET_ARCH_MIPS64 | 673 #endif // V8_TARGET_ARCH_MIPS64 |
OLD | NEW |