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 #include "src/v8.h" | 5 #include "src/v8.h" |
6 | 6 |
7 #if V8_TARGET_ARCH_ARM | 7 #if V8_TARGET_ARCH_ARM |
8 | 8 |
9 #include "src/codegen.h" | 9 #include "src/codegen.h" |
10 #include "src/ic/ic.h" | 10 #include "src/ic/ic.h" |
(...skipping 715 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
726 void KeyedStoreIC::GenerateMiss(MacroAssembler* masm) { | 726 void KeyedStoreIC::GenerateMiss(MacroAssembler* masm) { |
727 // Push receiver, key and value for runtime call. | 727 // Push receiver, key and value for runtime call. |
728 __ Push(ReceiverRegister(), NameRegister(), ValueRegister()); | 728 __ Push(ReceiverRegister(), NameRegister(), ValueRegister()); |
729 | 729 |
730 ExternalReference ref = | 730 ExternalReference ref = |
731 ExternalReference(IC_Utility(kKeyedStoreIC_Miss), masm->isolate()); | 731 ExternalReference(IC_Utility(kKeyedStoreIC_Miss), masm->isolate()); |
732 __ TailCallExternalReference(ref, 3, 1); | 732 __ TailCallExternalReference(ref, 3, 1); |
733 } | 733 } |
734 | 734 |
735 | 735 |
736 void StoreIC::GenerateSlow(MacroAssembler* masm) { | |
737 // Push receiver, key and value for runtime call. | |
738 __ Push(ReceiverRegister(), NameRegister(), ValueRegister()); | |
739 | |
740 // The slow case calls into the runtime to complete the store without causing | |
741 // an IC miss that would otherwise cause a transition to the generic stub. | |
742 ExternalReference ref = | |
743 ExternalReference(IC_Utility(kStoreIC_Slow), masm->isolate()); | |
744 __ TailCallExternalReference(ref, 3, 1); | |
745 } | |
746 | |
747 | |
748 void KeyedStoreIC::GenerateSlow(MacroAssembler* masm) { | |
749 // Push receiver, key and value for runtime call. | |
750 __ Push(ReceiverRegister(), NameRegister(), ValueRegister()); | |
751 | |
752 // The slow case calls into the runtime to complete the store without causing | |
753 // an IC miss that would otherwise cause a transition to the generic stub. | |
754 ExternalReference ref = | |
755 ExternalReference(IC_Utility(kKeyedStoreIC_Slow), masm->isolate()); | |
756 __ TailCallExternalReference(ref, 3, 1); | |
757 } | |
758 | |
759 | |
760 static void KeyedStoreGenerateGenericHelper( | 736 static void KeyedStoreGenerateGenericHelper( |
761 MacroAssembler* masm, Label* fast_object, Label* fast_double, Label* slow, | 737 MacroAssembler* masm, Label* fast_object, Label* fast_double, Label* slow, |
762 KeyedStoreCheckMap check_map, KeyedStoreIncrementLength increment_length, | 738 KeyedStoreCheckMap check_map, KeyedStoreIncrementLength increment_length, |
763 Register value, Register key, Register receiver, Register receiver_map, | 739 Register value, Register key, Register receiver, Register receiver_map, |
764 Register elements_map, Register elements) { | 740 Register elements_map, Register elements) { |
765 Label transition_smi_elements; | 741 Label transition_smi_elements; |
766 Label finish_object_store, non_double_value, transition_double_elements; | 742 Label finish_object_store, non_double_value, transition_double_elements; |
767 Label fast_double_without_map_check; | 743 Label fast_double_without_map_check; |
768 | 744 |
769 // Fast case: Do the store, could be either Object or double. | 745 // Fast case: Do the store, could be either Object or double. |
(...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1142 patcher.EmitCondition(ne); | 1118 patcher.EmitCondition(ne); |
1143 } else { | 1119 } else { |
1144 DCHECK(Assembler::GetCondition(branch_instr) == ne); | 1120 DCHECK(Assembler::GetCondition(branch_instr) == ne); |
1145 patcher.EmitCondition(eq); | 1121 patcher.EmitCondition(eq); |
1146 } | 1122 } |
1147 } | 1123 } |
1148 } | 1124 } |
1149 } // namespace v8::internal | 1125 } // namespace v8::internal |
1150 | 1126 |
1151 #endif // V8_TARGET_ARCH_ARM | 1127 #endif // V8_TARGET_ARCH_ARM |
OLD | NEW |