| 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 #include <map> | 9 #include <map> |
| 10 | 10 |
| (...skipping 501 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 512 | 512 |
| 513 static const int kTraceRingBufferSize = 512; | 513 static const int kTraceRingBufferSize = 512; |
| 514 static const int kStacktraceBufferSize = 512; | 514 static const int kStacktraceBufferSize = 512; |
| 515 | 515 |
| 516 static const double kMinHeapGrowingFactor; | 516 static const double kMinHeapGrowingFactor; |
| 517 static const double kMaxHeapGrowingFactor; | 517 static const double kMaxHeapGrowingFactor; |
| 518 static const double kMaxHeapGrowingFactorMemoryConstrained; | 518 static const double kMaxHeapGrowingFactorMemoryConstrained; |
| 519 static const double kMaxHeapGrowingFactorIdle; | 519 static const double kMaxHeapGrowingFactorIdle; |
| 520 static const double kTargetMutatorUtilization; | 520 static const double kTargetMutatorUtilization; |
| 521 | 521 |
| 522 // Sloppy mode arguments object size. | |
| 523 static const int kSloppyArgumentsObjectSize = | |
| 524 JSObject::kHeaderSize + 2 * kPointerSize; | |
| 525 | |
| 526 // Strict mode arguments has no callee so it is smaller. | |
| 527 static const int kStrictArgumentsObjectSize = | |
| 528 JSObject::kHeaderSize + 1 * kPointerSize; | |
| 529 | |
| 530 // Indicies for direct access into argument objects. | |
| 531 static const int kArgumentsLengthIndex = 0; | |
| 532 | |
| 533 // callee is only valid in sloppy mode. | |
| 534 static const int kArgumentsCalleeIndex = 1; | |
| 535 | |
| 536 static const int kNoGCFlags = 0; | 522 static const int kNoGCFlags = 0; |
| 537 static const int kReduceMemoryFootprintMask = 1; | 523 static const int kReduceMemoryFootprintMask = 1; |
| 538 static const int kAbortIncrementalMarkingMask = 2; | 524 static const int kAbortIncrementalMarkingMask = 2; |
| 539 static const int kFinalizeIncrementalMarkingMask = 4; | 525 static const int kFinalizeIncrementalMarkingMask = 4; |
| 540 | 526 |
| 541 // Making the heap iterable requires us to abort incremental marking. | 527 // Making the heap iterable requires us to abort incremental marking. |
| 542 static const int kMakeHeapIterableMask = kAbortIncrementalMarkingMask; | 528 static const int kMakeHeapIterableMask = kAbortIncrementalMarkingMask; |
| 543 | 529 |
| 544 // The roots that have an index less than this are always in old space. | 530 // The roots that have an index less than this are always in old space. |
| 545 static const int kOldSpaceRoots = 0x20; | 531 static const int kOldSpaceRoots = 0x20; |
| (...skipping 2084 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2630 | 2616 |
| 2631 private: | 2617 private: |
| 2632 friend class NewSpace; | 2618 friend class NewSpace; |
| 2633 DISALLOW_COPY_AND_ASSIGN(InlineAllocationObserver); | 2619 DISALLOW_COPY_AND_ASSIGN(InlineAllocationObserver); |
| 2634 }; | 2620 }; |
| 2635 | 2621 |
| 2636 } // namespace internal | 2622 } // namespace internal |
| 2637 } // namespace v8 | 2623 } // namespace v8 |
| 2638 | 2624 |
| 2639 #endif // V8_HEAP_HEAP_H_ | 2625 #endif // V8_HEAP_HEAP_H_ |
| OLD | NEW |