Index: runtime/vm/flow_graph_builder.h |
diff --git a/runtime/vm/flow_graph_builder.h b/runtime/vm/flow_graph_builder.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..b7d66f1d10bac5b801c16417e2f33185db38dc8f |
--- /dev/null |
+++ b/runtime/vm/flow_graph_builder.h |
@@ -0,0 +1,33 @@ |
+// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
+// for details. All rights reserved. Use of this source code is governed by a |
+// BSD-style license that can be found in the LICENSE file. |
+ |
+#ifndef VM_FLOW_GRAPH_BUILDER_H_ |
+#define VM_FLOW_GRAPH_BUILDER_H_ |
+ |
+#include "vm/allocation.h" |
+ |
+namespace dart { |
+ |
+class ParsedFunction; |
+ |
+class FlowGraphBuilder: public ValueObject { |
+ public: |
+ explicit FlowGraphBuilder(const ParsedFunction& parsed_function) |
+ : parsed_function_(parsed_function), bailout_reason_(NULL) { } |
+ |
+ void BuildGraph(); |
+ |
+ const ParsedFunction& parsed_function() const { return parsed_function_; } |
+ |
+ void Bailout(const char* reason) { bailout_reason_ = reason; } |
+ void TraceBailout() const; |
+ |
+ private: |
+ const ParsedFunction& parsed_function_; |
+ const char* bailout_reason_; |
+}; |
+ |
+} // namespace dart |
+ |
+#endif // VM_FLOW_GRAPH_BUILDER_H_ |