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

Side by Side Diff: runtime/vm/precompiler.h

Issue 1359963002: Let the embedder provide entry points to Dart_Precompile. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 3 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
« no previous file with comments | « runtime/vm/dart_api_impl.cc ('k') | runtime/vm/precompiler.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 (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef VM_PRECOMPILER_H_ 5 #ifndef VM_PRECOMPILER_H_
6 #define VM_PRECOMPILER_H_ 6 #define VM_PRECOMPILER_H_
7 7
8 #include "vm/allocation.h" 8 #include "vm/allocation.h"
9 #include "vm/hash_map.h" 9 #include "vm/hash_map.h"
10 #include "vm/object.h" 10 #include "vm/object.h"
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 } 71 }
72 72
73 private: 73 private:
74 Zone* zone_; 74 Zone* zone_;
75 DirectChainedHashMap<SymbolPair> map_; 75 DirectChainedHashMap<SymbolPair> map_;
76 }; 76 };
77 77
78 78
79 class Precompiler : public ValueObject { 79 class Precompiler : public ValueObject {
80 public: 80 public:
81 static RawError* CompileAll(); 81 static RawError* CompileAll(
82 Dart_QualifiedFunctionName embedder_entry_points[]);
82 83
83 private: 84 private:
84 explicit Precompiler(Thread* thread); 85 explicit Precompiler(Thread* thread);
85 86
86 void DoCompileAll(); 87 void DoCompileAll(Dart_QualifiedFunctionName embedder_entry_points[]);
87 void ClearAllCode(); 88 void ClearAllCode();
88 void AddRoots(); 89 void AddRoots(Dart_QualifiedFunctionName embedder_entry_points[]);
90 void AddEntryPoints(Dart_QualifiedFunctionName entry_points[]);
89 void Iterate(); 91 void Iterate();
90 void CleanUp(); 92 void CleanUp();
91 93
92 void AddCalleesOf(const Function& function); 94 void AddCalleesOf(const Function& function);
93 void AddField(const Field& field); 95 void AddField(const Field& field);
94 void AddFunction(const Function& function); 96 void AddFunction(const Function& function);
95 void AddClass(const Class& cls); 97 void AddClass(const Class& cls);
96 void AddSelector(const String& selector); 98 void AddSelector(const String& selector);
97 bool IsSent(const String& selector); 99 bool IsSent(const String& selector);
98 100
(...skipping 19 matching lines...) Expand all
118 const GrowableObjectArray& libraries_; 120 const GrowableObjectArray& libraries_;
119 const GrowableObjectArray& pending_functions_; 121 const GrowableObjectArray& pending_functions_;
120 const GrowableObjectArray& collected_closures_; 122 const GrowableObjectArray& collected_closures_;
121 SymbolSet sent_selectors_; 123 SymbolSet sent_selectors_;
122 Error& error_; 124 Error& error_;
123 }; 125 };
124 126
125 } // namespace dart 127 } // namespace dart
126 128
127 #endif // VM_PRECOMPILER_H_ 129 #endif // VM_PRECOMPILER_H_
OLDNEW
« no previous file with comments | « runtime/vm/dart_api_impl.cc ('k') | runtime/vm/precompiler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698