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 1613 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1624 | 1624 |
1625 #ifdef VERIFY_HEAP | 1625 #ifdef VERIFY_HEAP |
1626 if (FLAG_verify_heap) VerifyNonPointerSpacePointers(this); | 1626 if (FLAG_verify_heap) VerifyNonPointerSpacePointers(this); |
1627 #endif | 1627 #endif |
1628 | 1628 |
1629 gc_state_ = SCAVENGE; | 1629 gc_state_ = SCAVENGE; |
1630 | 1630 |
1631 // Implements Cheney's copying algorithm | 1631 // Implements Cheney's copying algorithm |
1632 LOG(isolate_, ResourceEvent("scavenge", "begin")); | 1632 LOG(isolate_, ResourceEvent("scavenge", "begin")); |
1633 | 1633 |
1634 // Clear descriptor cache. | |
1635 isolate_->descriptor_lookup_cache()->Clear(); | |
1636 | |
1637 // Used for updating survived_since_last_expansion_ at function end. | 1634 // Used for updating survived_since_last_expansion_ at function end. |
1638 intptr_t survived_watermark = PromotedSpaceSizeOfObjects(); | 1635 intptr_t survived_watermark = PromotedSpaceSizeOfObjects(); |
1639 | 1636 |
1640 scavenge_collector_->SelectScavengingVisitorsTable(); | 1637 scavenge_collector_->SelectScavengingVisitorsTable(); |
1641 | 1638 |
1642 array_buffer_tracker()->PrepareDiscoveryInNewSpace(); | 1639 array_buffer_tracker()->PrepareDiscoveryInNewSpace(); |
1643 | 1640 |
1644 // Flip the semispaces. After flipping, to space is empty, from space has | 1641 // Flip the semispaces. After flipping, to space is empty, from space has |
1645 // live objects. | 1642 // live objects. |
1646 new_space_.Flip(); | 1643 new_space_.Flip(); |
(...skipping 4643 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6290 } | 6287 } |
6291 | 6288 |
6292 | 6289 |
6293 // static | 6290 // static |
6294 int Heap::GetStaticVisitorIdForMap(Map* map) { | 6291 int Heap::GetStaticVisitorIdForMap(Map* map) { |
6295 return StaticVisitorBase::GetVisitorId(map); | 6292 return StaticVisitorBase::GetVisitorId(map); |
6296 } | 6293 } |
6297 | 6294 |
6298 } // namespace internal | 6295 } // namespace internal |
6299 } // namespace v8 | 6296 } // namespace v8 |
OLD | NEW |