| 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/ast/scopeinfo.h" | 9 #include "src/ast/scopeinfo.h" |
| 10 #include "src/base/bits.h" | 10 #include "src/base/bits.h" |
| (...skipping 2853 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2864 set_array_protector(*cell); | 2864 set_array_protector(*cell); |
| 2865 | 2865 |
| 2866 cell = factory->NewPropertyCell(); | 2866 cell = factory->NewPropertyCell(); |
| 2867 cell->set_value(the_hole_value()); | 2867 cell->set_value(the_hole_value()); |
| 2868 set_empty_property_cell(*cell); | 2868 set_empty_property_cell(*cell); |
| 2869 | 2869 |
| 2870 set_weak_stack_trace_list(Smi::FromInt(0)); | 2870 set_weak_stack_trace_list(Smi::FromInt(0)); |
| 2871 | 2871 |
| 2872 set_noscript_shared_function_infos(Smi::FromInt(0)); | 2872 set_noscript_shared_function_infos(Smi::FromInt(0)); |
| 2873 | 2873 |
| 2874 // Will be filled in by Interpreter::Initialize(). | |
| 2875 set_interpreter_table( | |
| 2876 *interpreter::Interpreter::CreateUninitializedInterpreterTable( | |
| 2877 isolate())); | |
| 2878 | |
| 2879 // Initialize keyed lookup cache. | 2874 // Initialize keyed lookup cache. |
| 2880 isolate_->keyed_lookup_cache()->Clear(); | 2875 isolate_->keyed_lookup_cache()->Clear(); |
| 2881 | 2876 |
| 2882 // Initialize context slot cache. | 2877 // Initialize context slot cache. |
| 2883 isolate_->context_slot_cache()->Clear(); | 2878 isolate_->context_slot_cache()->Clear(); |
| 2884 | 2879 |
| 2885 // Initialize descriptor cache. | 2880 // Initialize descriptor cache. |
| 2886 isolate_->descriptor_lookup_cache()->Clear(); | 2881 isolate_->descriptor_lookup_cache()->Clear(); |
| 2887 | 2882 |
| 2888 // Initialize compilation cache. | 2883 // Initialize compilation cache. |
| (...skipping 1709 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4598 // Iterate over local handles in handle scopes. | 4593 // Iterate over local handles in handle scopes. |
| 4599 isolate_->handle_scope_implementer()->Iterate(v); | 4594 isolate_->handle_scope_implementer()->Iterate(v); |
| 4600 isolate_->IterateDeferredHandles(v); | 4595 isolate_->IterateDeferredHandles(v); |
| 4601 v->Synchronize(VisitorSynchronization::kHandleScope); | 4596 v->Synchronize(VisitorSynchronization::kHandleScope); |
| 4602 | 4597 |
| 4603 // Iterate over the builtin code objects and code stubs in the | 4598 // Iterate over the builtin code objects and code stubs in the |
| 4604 // heap. Note that it is not necessary to iterate over code objects | 4599 // heap. Note that it is not necessary to iterate over code objects |
| 4605 // on scavenge collections. | 4600 // on scavenge collections. |
| 4606 if (mode != VISIT_ALL_IN_SCAVENGE) { | 4601 if (mode != VISIT_ALL_IN_SCAVENGE) { |
| 4607 isolate_->builtins()->IterateBuiltins(v); | 4602 isolate_->builtins()->IterateBuiltins(v); |
| 4603 v->Synchronize(VisitorSynchronization::kBuiltins); |
| 4604 isolate_->interpreter()->IterateDispatchTable(v); |
| 4605 v->Synchronize(VisitorSynchronization::kDispatchTable); |
| 4608 } | 4606 } |
| 4609 v->Synchronize(VisitorSynchronization::kBuiltins); | |
| 4610 | 4607 |
| 4611 // Iterate over global handles. | 4608 // Iterate over global handles. |
| 4612 switch (mode) { | 4609 switch (mode) { |
| 4613 case VISIT_ONLY_STRONG: | 4610 case VISIT_ONLY_STRONG: |
| 4614 isolate_->global_handles()->IterateStrongRoots(v); | 4611 isolate_->global_handles()->IterateStrongRoots(v); |
| 4615 break; | 4612 break; |
| 4616 case VISIT_ALL_IN_SCAVENGE: | 4613 case VISIT_ALL_IN_SCAVENGE: |
| 4617 isolate_->global_handles()->IterateNewSpaceStrongAndDependentRoots(v); | 4614 isolate_->global_handles()->IterateNewSpaceStrongAndDependentRoots(v); |
| 4618 break; | 4615 break; |
| 4619 case VISIT_ALL_IN_SWEEP_NEWSPACE: | 4616 case VISIT_ALL_IN_SWEEP_NEWSPACE: |
| (...skipping 1595 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6215 } | 6212 } |
| 6216 | 6213 |
| 6217 | 6214 |
| 6218 // static | 6215 // static |
| 6219 int Heap::GetStaticVisitorIdForMap(Map* map) { | 6216 int Heap::GetStaticVisitorIdForMap(Map* map) { |
| 6220 return StaticVisitorBase::GetVisitorId(map); | 6217 return StaticVisitorBase::GetVisitorId(map); |
| 6221 } | 6218 } |
| 6222 | 6219 |
| 6223 } // namespace internal | 6220 } // namespace internal |
| 6224 } // namespace v8 | 6221 } // namespace v8 |
| OLD | NEW |