Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(548)

Side by Side Diff: src/heap.h

Issue 8084002: Start incremental marking on idle notification. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | src/heap.cc » ('j') | src/heap.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 1739 matching lines...) Expand 10 before | Expand all | Expand 10 after
1750 bool IsIncreasingSurvivalTrend() { 1750 bool IsIncreasingSurvivalTrend() {
1751 return survival_rate_trend() == INCREASING; 1751 return survival_rate_trend() == INCREASING;
1752 } 1752 }
1753 1753
1754 bool IsHighSurvivalRate() { 1754 bool IsHighSurvivalRate() {
1755 return high_survival_rate_period_length_ > 0; 1755 return high_survival_rate_period_length_ > 0;
1756 } 1756 }
1757 1757
1758 void SelectScavengingVisitorsTable(); 1758 void SelectScavengingVisitorsTable();
1759 1759
1760 // Returns true if incremental marking is finished.
1761 bool IdleIncrementalMarking();
1762
1763 // Returns true if no more GC work is left.
1764 bool IdleGlobalGC();
1765
1760 static const int kInitialSymbolTableSize = 2048; 1766 static const int kInitialSymbolTableSize = 2048;
1761 static const int kInitialEvalCacheSize = 64; 1767 static const int kInitialEvalCacheSize = 64;
1762 1768
1763 // Maximum GC pause. 1769 // Maximum GC pause.
1764 int max_gc_pause_; 1770 int max_gc_pause_;
1765 1771
1766 // Maximum size of objects alive after GC. 1772 // Maximum size of objects alive after GC.
1767 intptr_t max_alive_after_gc_; 1773 intptr_t max_alive_after_gc_;
1768 1774
1769 // Minimal interval between two subsequent collections. 1775 // Minimal interval between two subsequent collections.
1770 int min_in_mutator_; 1776 int min_in_mutator_;
1771 1777
1772 // Size of objects alive after last GC. 1778 // Size of objects alive after last GC.
1773 intptr_t alive_after_last_gc_; 1779 intptr_t alive_after_last_gc_;
1774 1780
1775 double last_gc_end_timestamp_; 1781 double last_gc_end_timestamp_;
1776 1782
1777 MarkCompactCollector mark_compact_collector_; 1783 MarkCompactCollector mark_compact_collector_;
1778 1784
1779 StoreBuffer store_buffer_; 1785 StoreBuffer store_buffer_;
1780 1786
1781 Marking marking_; 1787 Marking marking_;
1782 1788
1783 IncrementalMarking incremental_marking_; 1789 IncrementalMarking incremental_marking_;
1784 1790
1791 enum IdleWork {
1792 IDLE_INCREMENTAL_MARKING,
1793 IDLE_GLOBAL_GC
1794 };
1795
1796 IdleWork idle_work_;
1797
1785 int number_idle_notifications_; 1798 int number_idle_notifications_;
1786 unsigned int last_idle_notification_gc_count_; 1799 unsigned int last_idle_notification_gc_count_;
1787 bool last_idle_notification_gc_count_init_; 1800 bool last_idle_notification_gc_count_init_;
1788 1801
1789 // Shared state read by the scavenge collector and set by ScavengeObject. 1802 // Shared state read by the scavenge collector and set by ScavengeObject.
1790 PromotionQueue promotion_queue_; 1803 PromotionQueue promotion_queue_;
1791 1804
1792 // Flag is set when the heap has been configured. The heap can be repeatedly 1805 // Flag is set when the heap has been configured. The heap can be repeatedly
1793 // configured through the API until it is setup. 1806 // configured through the API until it is setup.
1794 bool configured_; 1807 bool configured_;
(...skipping 689 matching lines...) Expand 10 before | Expand all | Expand 10 after
2484 2497
2485 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); 2498 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer);
2486 }; 2499 };
2487 #endif // DEBUG || LIVE_OBJECT_LIST 2500 #endif // DEBUG || LIVE_OBJECT_LIST
2488 2501
2489 } } // namespace v8::internal 2502 } } // namespace v8::internal
2490 2503
2491 #undef HEAP 2504 #undef HEAP
2492 2505
2493 #endif // V8_HEAP_H_ 2506 #endif // V8_HEAP_H_
OLDNEW
« no previous file with comments | « no previous file | src/heap.cc » ('j') | src/heap.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698