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

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

Issue 10916228: Inline monomorphic calls. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Incorporated review comments. Created 8 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, 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_FLOW_GRAPH_BUILDER_H_ 5 #ifndef VM_FLOW_GRAPH_BUILDER_H_
6 #define VM_FLOW_GRAPH_BUILDER_H_ 6 #define VM_FLOW_GRAPH_BUILDER_H_
7 7
8 #include "vm/allocation.h" 8 #include "vm/allocation.h"
9 #include "vm/ast.h" 9 #include "vm/ast.h"
10 #include "vm/growable_array.h" 10 #include "vm/growable_array.h"
(...skipping 10 matching lines...) Expand all
21 public: 21 public:
22 explicit FlowGraphBuilder(const ParsedFunction& parsed_function); 22 explicit FlowGraphBuilder(const ParsedFunction& parsed_function);
23 23
24 enum InliningContext { 24 enum InliningContext {
25 kNotInlining, 25 kNotInlining,
26 kValueContext, 26 kValueContext,
27 kEffectContext, 27 kEffectContext,
28 kTestContext 28 kTestContext
29 }; 29 };
30 30
31 FlowGraph* BuildGraph(); 31 FlowGraph* BuildGraph(InliningContext context);
32 FlowGraph* BuildGraphForInlining(InliningContext context);
33 32
34 const ParsedFunction& parsed_function() const { return parsed_function_; } 33 const ParsedFunction& parsed_function() const { return parsed_function_; }
35 34
36 void Bailout(const char* reason); 35 void Bailout(const char* reason);
37 36
38 void set_context_level(intptr_t value) { context_level_ = value; } 37 void set_context_level(intptr_t value) { context_level_ = value; }
39 intptr_t context_level() const { return context_level_; } 38 intptr_t context_level() const { return context_level_; }
40 39
41 // Each try in this function gets its own try index. 40 // Each try in this function gets its own try index.
42 intptr_t AllocateTryIndex() { return ++last_used_try_index_; } 41 intptr_t AllocateTryIndex() { return ++last_used_try_index_; }
(...skipping 346 matching lines...) Expand 10 before | Expand all | Expand 10 after
389 // Output parameters. 388 // Output parameters.
390 GrowableArray<TargetEntryInstr**> true_successor_addresses_; 389 GrowableArray<TargetEntryInstr**> true_successor_addresses_;
391 GrowableArray<TargetEntryInstr**> false_successor_addresses_; 390 GrowableArray<TargetEntryInstr**> false_successor_addresses_;
392 391
393 intptr_t condition_token_pos_; 392 intptr_t condition_token_pos_;
394 }; 393 };
395 394
396 } // namespace dart 395 } // namespace dart
397 396
398 #endif // VM_FLOW_GRAPH_BUILDER_H_ 397 #endif // VM_FLOW_GRAPH_BUILDER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698