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

Unified Diff: src/heap/heap.h

Issue 1320843002: [heap] Limit friendship of the Heap class to essentials. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/factory.h ('k') | src/heap/heap.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap/heap.h
diff --git a/src/heap/heap.h b/src/heap/heap.h
index 254b19f83cb54714fd80a897f14242331ff0fb59..b5ede40572226ecc498de4ccb01fa86df126d3ef 100644
--- a/src/heap/heap.h
+++ b/src/heap/heap.h
@@ -1224,14 +1224,26 @@ class Heap {
roots_[kNonMonomorphicCacheRootIndex] = value;
}
- void public_set_empty_script(Script* script) {
- roots_[kEmptyScriptRootIndex] = script;
- }
-
void public_set_materialized_objects(FixedArray* objects) {
roots_[kMaterializedObjectsRootIndex] = objects;
}
+ void public_set_code_stub_context(Object* value) {
Hannes Payer (out of office) 2015/08/27 09:25:02 These are not "real" setters. Hence, they should n
Michael Starzinger 2015/08/27 09:27:48 The "public" prefix is to not clash with the priva
Hannes Payer (out of office) 2015/08/27 10:11:00 I would prefer SetRoot*
Michael Starzinger 2015/08/27 11:09:13 Done. Your slight preference is my command.
+ roots_[kCodeStubContextRootIndex] = value;
+ }
+
+ void public_set_code_stub_exports_object(JSObject* value) {
+ roots_[kCodeStubExportsObjectRootIndex] = value;
+ }
+
+ void public_set_script_list(Object* value) {
+ roots_[kScriptListRootIndex] = value;
+ }
+
+ void public_set_string_table(StringTable* value) {
+ roots_[kStringTableRootIndex] = value;
+ }
+
// Set the stack limit in the roots_ array. Some architectures generate
// code that looks here, because it is faster than loading from the static
// jslimit_/real_jslimit_ variable in the StackGuard.
@@ -2407,21 +2419,23 @@ class Heap {
StrongRootsList* strong_roots_list_;
+ // Classes in "heap" can be friends.
friend class AlwaysAllocateScope;
- friend class Bootstrapper;
- friend class Deserializer;
- friend class Factory;
friend class GCCallbacksScope;
friend class GCTracer;
friend class HeapIterator;
friend class IncrementalMarking;
- friend class Isolate;
friend class MarkCompactCollector;
friend class MarkCompactMarkingVisitor;
- friend class MapCompact;
friend class Page;
friend class StoreBuffer;
+ // The allocator interface.
+ friend class Factory;
+
+ // The Isolate constructs use.
+ friend class Isolate;
+
// Used in cctest.
friend class HeapTester;
« no previous file with comments | « src/factory.h ('k') | src/heap/heap.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698