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

Unified Diff: src/ast/collect-eager-literals.h

Issue 2399463008: Create multiple compilation jobs for ignition if compiling multiple literals (Closed)
Patch Set: updates Created 4 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 side-by-side diff with in-line comments
Download patch
Index: src/ast/collect-eager-literals.h
diff --git a/src/ast/collect-eager-literals.h b/src/ast/collect-eager-literals.h
new file mode 100644
index 0000000000000000000000000000000000000000..1fc66bc1e7214981c09a24566e20ea2bc429d575
--- /dev/null
+++ b/src/ast/collect-eager-literals.h
@@ -0,0 +1,44 @@
+// Copyright 2016 the V8 project authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef V8_AST_COLLECT_EAGER_LITERALS_H_
+#define V8_AST_COLLECT_EAGER_LITERALS_H_
+
+#include <set>
+
+#include "src/ast/ast-traversal-visitor.h"
+#include "src/base/macros.h"
+
+namespace v8 {
+namespace internal {
+
+class CompilationInfo;
+class ParseInfo;
+
+class CollectEagerLiterals final
+ : public AstTraversalVisitor<CollectEagerLiterals> {
+ public:
+ explicit CollectEagerLiterals(CompilationInfo* info);
Michael Starzinger 2016/10/17 13:16:03 nit: How would you feel about passing just the Par
+ ~CollectEagerLiterals();
+
+ const std::set<FunctionLiteral*>& eager_literals() const {
+ return eager_literals_;
+ }
+
+ private:
+ friend class AstTraversalVisitor<CollectEagerLiterals>;
+
+ void VisitFunctionDeclaration(FunctionDeclaration* decl);
+ void VisitFunctionLiteral(FunctionLiteral* fun);
+
+ std::set<FunctionLiteral*> eager_literals_;
+ ParseInfo* parse_info_;
+
+ DISALLOW_COPY_AND_ASSIGN(CollectEagerLiterals);
+};
+
+} // namespace internal
+} // namespace v8
+
+#endif // V8_AST_COLLECT_EAGER_LITERALS_H_
« no previous file with comments | « BUILD.gn ('k') | src/ast/collect-eager-literals.cc » ('j') | src/ast/collect-eager-literals.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698