| OLD | NEW |
| 1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 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/code-stub-assembler.h" | 5 #include "src/code-stub-assembler.h" |
| 6 #include "src/code-factory.h" | 6 #include "src/code-factory.h" |
| 7 #include "src/frames-inl.h" | 7 #include "src/frames-inl.h" |
| 8 #include "src/frames.h" | 8 #include "src/frames.h" |
| 9 #include "src/ic/stub-cache.h" | 9 #include "src/ic/stub-cache.h" |
| 10 | 10 |
| (...skipping 3027 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3038 Bind(&out_of_object_double); | 3038 Bind(&out_of_object_double); |
| 3039 var_double_value.Bind(LoadHeapNumberValue(value)); | 3039 var_double_value.Bind(LoadHeapNumberValue(value)); |
| 3040 Goto(&rebox_double); | 3040 Goto(&rebox_double); |
| 3041 | 3041 |
| 3042 Bind(&rebox_double); | 3042 Bind(&rebox_double); |
| 3043 Return(AllocateHeapNumberWithValue(var_double_value.value())); | 3043 Return(AllocateHeapNumberWithValue(var_double_value.value())); |
| 3044 } | 3044 } |
| 3045 | 3045 |
| 3046 // |handler| is a heap object. Must be code, call it. | 3046 // |handler| is a heap object. Must be code, call it. |
| 3047 Bind(&call_handler); | 3047 Bind(&call_handler); |
| 3048 LoadWithVectorDescriptor descriptor(isolate()); | 3048 typedef LoadWithVectorDescriptor Descriptor; |
| 3049 TailCallStub(descriptor, handler, p->context, p->receiver, p->name, p->slot, | 3049 TailCallStub(Descriptor(isolate()), var_handler.value(), p->context, |
| 3050 p->vector); | 3050 Arg(Descriptor::kReceiver, p->receiver), |
| 3051 Arg(Descriptor::kName, p->name), |
| 3052 Arg(Descriptor::kSlot, p->slot), |
| 3053 Arg(Descriptor::kVector, p->vector)); |
| 3051 } | 3054 } |
| 3052 | 3055 |
| 3053 Bind(&try_polymorphic); | 3056 Bind(&try_polymorphic); |
| 3054 { | 3057 { |
| 3055 // Check polymorphic case. | 3058 // Check polymorphic case. |
| 3056 Comment("LoadIC_try_polymorphic"); | 3059 Comment("LoadIC_try_polymorphic"); |
| 3057 GotoUnless( | 3060 GotoUnless( |
| 3058 WordEqual(LoadMap(feedback), LoadRoot(Heap::kFixedArrayMapRootIndex)), | 3061 WordEqual(LoadMap(feedback), LoadRoot(Heap::kFixedArrayMapRootIndex)), |
| 3059 &try_megamorphic); | 3062 &try_megamorphic); |
| 3060 HandlePolymorphicCase(p, receiver_map, feedback, &if_handler, &var_handler, | 3063 HandlePolymorphicCase(p, receiver_map, feedback, &if_handler, &var_handler, |
| (...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3178 // For all objects but the receiver, check that the cache is empty. | 3181 // For all objects but the receiver, check that the cache is empty. |
| 3179 current_map.Bind(LoadMap(current_js_object.value())); | 3182 current_map.Bind(LoadMap(current_js_object.value())); |
| 3180 Node* enum_length = EnumLength(current_map.value()); | 3183 Node* enum_length = EnumLength(current_map.value()); |
| 3181 Node* zero_constant = SmiConstant(Smi::FromInt(0)); | 3184 Node* zero_constant = SmiConstant(Smi::FromInt(0)); |
| 3182 BranchIf(WordEqual(enum_length, zero_constant), &loop, use_runtime); | 3185 BranchIf(WordEqual(enum_length, zero_constant), &loop, use_runtime); |
| 3183 } | 3186 } |
| 3184 } | 3187 } |
| 3185 | 3188 |
| 3186 } // namespace internal | 3189 } // namespace internal |
| 3187 } // namespace v8 | 3190 } // namespace v8 |
| OLD | NEW |