| 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/ic/ic.h" | 5 #include "src/ic/ic.h" |
| 6 | 6 |
| 7 #include <iostream> | 7 #include <iostream> |
| 8 | 8 |
| 9 #include "src/accessors.h" | 9 #include "src/accessors.h" |
| 10 #include "src/api-arguments-inl.h" | 10 #include "src/api-arguments-inl.h" |
| (...skipping 2614 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2625 RETURN_RESULT_OR_FAILURE(isolate, ic.Store(receiver, key, value)); | 2625 RETURN_RESULT_OR_FAILURE(isolate, ic.Store(receiver, key, value)); |
| 2626 } else { | 2626 } else { |
| 2627 DCHECK(vector->IsKeyedStoreIC(vector_slot)); | 2627 DCHECK(vector->IsKeyedStoreIC(vector_slot)); |
| 2628 KeyedStoreICNexus nexus(vector, vector_slot); | 2628 KeyedStoreICNexus nexus(vector, vector_slot); |
| 2629 KeyedStoreIC ic(IC::NO_EXTRA_FRAME, isolate, &nexus); | 2629 KeyedStoreIC ic(IC::NO_EXTRA_FRAME, isolate, &nexus); |
| 2630 ic.UpdateState(receiver, key); | 2630 ic.UpdateState(receiver, key); |
| 2631 RETURN_RESULT_OR_FAILURE(isolate, ic.Store(receiver, key, value)); | 2631 RETURN_RESULT_OR_FAILURE(isolate, ic.Store(receiver, key, value)); |
| 2632 } | 2632 } |
| 2633 } | 2633 } |
| 2634 | 2634 |
| 2635 | |
| 2636 // Used from ic-<arch>.cc. | 2635 // Used from ic-<arch>.cc. |
| 2637 RUNTIME_FUNCTION(Runtime_KeyedStoreIC_Miss) { | 2636 RUNTIME_FUNCTION(Runtime_KeyedStoreIC_Miss) { |
| 2638 HandleScope scope(isolate); | 2637 HandleScope scope(isolate); |
| 2639 DCHECK_EQ(5, args.length()); | 2638 DCHECK_EQ(5, args.length()); |
| 2640 // Runtime functions don't follow the IC's calling convention. | 2639 // Runtime functions don't follow the IC's calling convention. |
| 2641 Handle<Object> value = args.at(0); | 2640 Handle<Object> value = args.at(0); |
| 2642 Handle<Smi> slot = args.at<Smi>(1); | 2641 Handle<Smi> slot = args.at<Smi>(1); |
| 2643 Handle<TypeFeedbackVector> vector = args.at<TypeFeedbackVector>(2); | 2642 Handle<TypeFeedbackVector> vector = args.at<TypeFeedbackVector>(2); |
| 2644 Handle<Object> receiver = args.at(3); | 2643 Handle<Object> receiver = args.at(3); |
| 2645 Handle<Object> key = args.at(4); | 2644 Handle<Object> key = args.at(4); |
| (...skipping 502 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3148 DCHECK_EQ(LookupIterator::INTERCEPTOR, it.state()); | 3147 DCHECK_EQ(LookupIterator::INTERCEPTOR, it.state()); |
| 3149 it.Next(); | 3148 it.Next(); |
| 3150 ASSIGN_RETURN_FAILURE_ON_EXCEPTION(isolate, result, | 3149 ASSIGN_RETURN_FAILURE_ON_EXCEPTION(isolate, result, |
| 3151 Object::GetProperty(&it)); | 3150 Object::GetProperty(&it)); |
| 3152 } | 3151 } |
| 3153 | 3152 |
| 3154 return *result; | 3153 return *result; |
| 3155 } | 3154 } |
| 3156 } // namespace internal | 3155 } // namespace internal |
| 3157 } // namespace v8 | 3156 } // namespace v8 |
| OLD | NEW |