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 #ifndef V8_HEAP_HEAP_H_ | 5 #ifndef V8_HEAP_HEAP_H_ |
6 #define V8_HEAP_HEAP_H_ | 6 #define V8_HEAP_HEAP_H_ |
7 | 7 |
8 #include <cmath> | 8 #include <cmath> |
9 | 9 |
10 #include "src/allocation.h" | 10 #include "src/allocation.h" |
(...skipping 1280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1291 | 1291 |
1292 inline void DoScavengeObject(Map* map, HeapObject** slot, HeapObject* obj) { | 1292 inline void DoScavengeObject(Map* map, HeapObject** slot, HeapObject* obj) { |
1293 scavenging_visitors_table_.GetVisitor(map)(map, slot, obj); | 1293 scavenging_visitors_table_.GetVisitor(map)(map, slot, obj); |
1294 } | 1294 } |
1295 | 1295 |
1296 void QueueMemoryChunkForFree(MemoryChunk* chunk); | 1296 void QueueMemoryChunkForFree(MemoryChunk* chunk); |
1297 void FreeQueuedChunks(); | 1297 void FreeQueuedChunks(); |
1298 | 1298 |
1299 int gc_count() const { return gc_count_; } | 1299 int gc_count() const { return gc_count_; } |
1300 | 1300 |
1301 bool RecentIdleNotifcationHappened(); | 1301 bool RecentIdleNotificationHappened(); |
1302 | 1302 |
1303 // Completely clear the Instanceof cache (to stop it keeping objects alive | 1303 // Completely clear the Instanceof cache (to stop it keeping objects alive |
1304 // around a GC). | 1304 // around a GC). |
1305 inline void CompletelyClearInstanceofCache(); | 1305 inline void CompletelyClearInstanceofCache(); |
1306 | 1306 |
1307 // The roots that have an index less than this are always in old space. | 1307 // The roots that have an index less than this are always in old space. |
1308 static const int kOldSpaceRoots = 0x20; | 1308 static const int kOldSpaceRoots = 0x20; |
1309 | 1309 |
1310 uint32_t HashSeed() { | 1310 uint32_t HashSeed() { |
1311 uint32_t seed = static_cast<uint32_t>(hash_seed()->value()); | 1311 uint32_t seed = static_cast<uint32_t>(hash_seed()->value()); |
(...skipping 1282 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2594 DisallowHeapAllocation no_allocation; // i.e. no gc allowed. | 2594 DisallowHeapAllocation no_allocation; // i.e. no gc allowed. |
2595 | 2595 |
2596 private: | 2596 private: |
2597 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); | 2597 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); |
2598 }; | 2598 }; |
2599 #endif // DEBUG | 2599 #endif // DEBUG |
2600 } | 2600 } |
2601 } // namespace v8::internal | 2601 } // namespace v8::internal |
2602 | 2602 |
2603 #endif // V8_HEAP_HEAP_H_ | 2603 #endif // V8_HEAP_HEAP_H_ |
OLD | NEW |