Chromium Code Reviews| 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/heap/heap.h" | 5 #include "src/heap/heap.h" |
| 6 | 6 |
| 7 #include "src/accessors.h" | 7 #include "src/accessors.h" |
| 8 #include "src/api.h" | 8 #include "src/api.h" |
| 9 #include "src/base/bits.h" | 9 #include "src/base/bits.h" |
| 10 #include "src/base/once.h" | 10 #include "src/base/once.h" |
| (...skipping 2768 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2779 | 2779 |
| 2780 Object* megamorphic = *TypeFeedbackVector::MegamorphicSentinel(isolate()); | 2780 Object* megamorphic = *TypeFeedbackVector::MegamorphicSentinel(isolate()); |
| 2781 dummy_vector->Set(load_ic_slot, megamorphic, SKIP_WRITE_BARRIER); | 2781 dummy_vector->Set(load_ic_slot, megamorphic, SKIP_WRITE_BARRIER); |
| 2782 dummy_vector->Set(keyed_load_ic_slot, megamorphic, SKIP_WRITE_BARRIER); | 2782 dummy_vector->Set(keyed_load_ic_slot, megamorphic, SKIP_WRITE_BARRIER); |
| 2783 dummy_vector->Set(store_ic_slot, megamorphic, SKIP_WRITE_BARRIER); | 2783 dummy_vector->Set(store_ic_slot, megamorphic, SKIP_WRITE_BARRIER); |
| 2784 dummy_vector->Set(keyed_store_ic_slot, megamorphic, SKIP_WRITE_BARRIER); | 2784 dummy_vector->Set(keyed_store_ic_slot, megamorphic, SKIP_WRITE_BARRIER); |
| 2785 | 2785 |
| 2786 set_dummy_vector(*dummy_vector); | 2786 set_dummy_vector(*dummy_vector); |
| 2787 } | 2787 } |
| 2788 | 2788 |
| 2789 { | |
| 2790 Handle<FixedArray> cleared_optimized_code_map = | |
| 2791 factory->NewFixedArray(SharedFunctionInfo::kEntriesStart, TENURED); | |
| 2792 DCHECK(SharedFunctionInfo::kEntriesStart == 1 && | |
|
Michael Starzinger
2015/11/13 12:14:22
nit: Could be turned into a STATIC_ASSERT instead.
mvstanton
2015/11/17 20:32:12
Done.
| |
| 2793 SharedFunctionInfo::kSharedCodeIndex == 0); | |
| 2794 cleared_optimized_code_map->set(SharedFunctionInfo::kSharedCodeIndex, | |
|
Michael Starzinger
2015/11/13 12:14:22
The field is already initialized to undefined, bec
mvstanton
2015/11/17 20:32:12
Done.
| |
| 2795 *factory->undefined_value(), | |
| 2796 SKIP_WRITE_BARRIER); | |
| 2797 set_cleared_optimized_code_map(*cleared_optimized_code_map); | |
| 2798 } | |
| 2799 | |
| 2789 set_detached_contexts(empty_fixed_array()); | 2800 set_detached_contexts(empty_fixed_array()); |
| 2790 set_retained_maps(ArrayList::cast(empty_fixed_array())); | 2801 set_retained_maps(ArrayList::cast(empty_fixed_array())); |
| 2791 | 2802 |
| 2792 set_weak_object_to_code_table( | 2803 set_weak_object_to_code_table( |
| 2793 *WeakHashTable::New(isolate(), 16, USE_DEFAULT_MINIMUM_CAPACITY, | 2804 *WeakHashTable::New(isolate(), 16, USE_DEFAULT_MINIMUM_CAPACITY, |
| 2794 TENURED)); | 2805 TENURED)); |
| 2795 | 2806 |
| 2796 set_script_list(Smi::FromInt(0)); | 2807 set_script_list(Smi::FromInt(0)); |
| 2797 | 2808 |
| 2798 Handle<SeededNumberDictionary> slow_element_dictionary = | 2809 Handle<SeededNumberDictionary> slow_element_dictionary = |
| (...skipping 3389 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 6188 } | 6199 } |
| 6189 | 6200 |
| 6190 | 6201 |
| 6191 // static | 6202 // static |
| 6192 int Heap::GetStaticVisitorIdForMap(Map* map) { | 6203 int Heap::GetStaticVisitorIdForMap(Map* map) { |
| 6193 return StaticVisitorBase::GetVisitorId(map); | 6204 return StaticVisitorBase::GetVisitorId(map); |
| 6194 } | 6205 } |
| 6195 | 6206 |
| 6196 } // namespace internal | 6207 } // namespace internal |
| 6197 } // namespace v8 | 6208 } // namespace v8 |
| OLD | NEW |