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

Side by Side Diff: src/heap/heap.h

Issue 750813003: Use deadline in IdleNotification. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 6 years 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
« no previous file with comments | « src/heap/gc-idle-time-handler.cc ('k') | src/heap/heap.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 1086 matching lines...) Expand 10 before | Expand all | Expand 10 after
1097 int freed_global_handles); 1097 int freed_global_handles);
1098 1098
1099 // Indicates whether inline bump-pointer allocation has been disabled. 1099 // Indicates whether inline bump-pointer allocation has been disabled.
1100 bool inline_allocation_disabled() { return inline_allocation_disabled_; } 1100 bool inline_allocation_disabled() { return inline_allocation_disabled_; }
1101 1101
1102 // Switch whether inline bump-pointer allocation should be used. 1102 // Switch whether inline bump-pointer allocation should be used.
1103 void EnableInlineAllocation(); 1103 void EnableInlineAllocation();
1104 void DisableInlineAllocation(); 1104 void DisableInlineAllocation();
1105 1105
1106 // Implements the corresponding V8 API function. 1106 // Implements the corresponding V8 API function.
1107 bool IdleNotification(double deadline_in_seconds);
1107 bool IdleNotification(int idle_time_in_ms); 1108 bool IdleNotification(int idle_time_in_ms);
1108 1109
1109 // Declare all the root indices. This defines the root list order. 1110 // Declare all the root indices. This defines the root list order.
1110 enum RootListIndex { 1111 enum RootListIndex {
1111 #define ROOT_INDEX_DECLARATION(type, name, camel_name) k##camel_name##RootIndex, 1112 #define ROOT_INDEX_DECLARATION(type, name, camel_name) k##camel_name##RootIndex,
1112 STRONG_ROOT_LIST(ROOT_INDEX_DECLARATION) 1113 STRONG_ROOT_LIST(ROOT_INDEX_DECLARATION)
1113 #undef ROOT_INDEX_DECLARATION 1114 #undef ROOT_INDEX_DECLARATION
1114 1115
1115 #define STRING_INDEX_DECLARATION(name, str) k##name##RootIndex, 1116 #define STRING_INDEX_DECLARATION(name, str) k##name##RootIndex,
1116 INTERNALIZED_STRING_LIST(STRING_INDEX_DECLARATION) 1117 INTERNALIZED_STRING_LIST(STRING_INDEX_DECLARATION)
(...skipping 884 matching lines...) Expand 10 before | Expand all | Expand 10 after
2001 2002
2002 // TODO(hpayer): Allocation site pretenuring may make this method obsolete. 2003 // TODO(hpayer): Allocation site pretenuring may make this method obsolete.
2003 // Re-visit incremental marking heuristics. 2004 // Re-visit incremental marking heuristics.
2004 bool IsHighSurvivalRate() { return high_survival_rate_period_length_ > 0; } 2005 bool IsHighSurvivalRate() { return high_survival_rate_period_length_ > 0; }
2005 2006
2006 void SelectScavengingVisitorsTable(); 2007 void SelectScavengingVisitorsTable();
2007 2008
2008 void IdleMarkCompact(const char* message); 2009 void IdleMarkCompact(const char* message);
2009 2010
2010 void TryFinalizeIdleIncrementalMarking( 2011 void TryFinalizeIdleIncrementalMarking(
2011 size_t idle_time_in_ms, size_t size_of_objects, 2012 double idle_time_in_ms, size_t size_of_objects,
2012 size_t mark_compact_speed_in_bytes_per_ms); 2013 size_t mark_compact_speed_in_bytes_per_ms);
2013 2014
2014 bool WorthActivatingIncrementalMarking(); 2015 bool WorthActivatingIncrementalMarking();
2015 2016
2016 void ClearObjectStats(bool clear_last_time_stats = false); 2017 void ClearObjectStats(bool clear_last_time_stats = false);
2017 2018
2018 void set_weak_object_to_code_table(Object* value) { 2019 void set_weak_object_to_code_table(Object* value) {
2019 DCHECK(!InNewSpace(value)); 2020 DCHECK(!InNewSpace(value));
2020 weak_object_to_code_table_ = value; 2021 weak_object_to_code_table_ = value;
2021 } 2022 }
(...skipping 556 matching lines...) Expand 10 before | Expand all | Expand 10 after
2578 DisallowHeapAllocation no_allocation; // i.e. no gc allowed. 2579 DisallowHeapAllocation no_allocation; // i.e. no gc allowed.
2579 2580
2580 private: 2581 private:
2581 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer); 2582 DISALLOW_IMPLICIT_CONSTRUCTORS(PathTracer);
2582 }; 2583 };
2583 #endif // DEBUG 2584 #endif // DEBUG
2584 } 2585 }
2585 } // namespace v8::internal 2586 } // namespace v8::internal
2586 2587
2587 #endif // V8_HEAP_HEAP_H_ 2588 #endif // V8_HEAP_HEAP_H_
OLDNEW
« no previous file with comments | « src/heap/gc-idle-time-handler.cc ('k') | src/heap/heap.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698