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

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

Issue 9729015: Compute immediate dominators using SEMI-NCA. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 9 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
« no previous file with comments | « no previous file | runtime/vm/flow_graph_builder.cc » ('j') | runtime/vm/flow_graph_builder.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 19 matching lines...) Expand all
30 const GrowableArray<BlockEntryInstr*>& postorder_block_entries() const { 30 const GrowableArray<BlockEntryInstr*>& postorder_block_entries() const {
31 return postorder_block_entries_; 31 return postorder_block_entries_;
32 } 32 }
33 33
34 void Bailout(const char* reason); 34 void Bailout(const char* reason);
35 35
36 void set_context_level(intptr_t value) { context_level_ = value; } 36 void set_context_level(intptr_t value) { context_level_ = value; }
37 intptr_t context_level() const { return context_level_; } 37 intptr_t context_level() const { return context_level_; }
38 38
39 private: 39 private:
40 void ComputeDominators(GrowableArray<BlockEntryInstr*>* preorder,
41 GrowableArray<intptr_t>* parent);
42 void CompressPath(intptr_t start_index,
43 intptr_t current_index,
44 GrowableArray<intptr_t>* parent,
45 GrowableArray<intptr_t>* label);
46
40 const ParsedFunction& parsed_function_; 47 const ParsedFunction& parsed_function_;
41 GrowableArray<BlockEntryInstr*> preorder_block_entries_; 48 GrowableArray<BlockEntryInstr*> preorder_block_entries_;
42 GrowableArray<BlockEntryInstr*> postorder_block_entries_; 49 GrowableArray<BlockEntryInstr*> postorder_block_entries_;
43 intptr_t context_level_; 50 intptr_t context_level_;
44 }; 51 };
45 52
46 53
47 class TestGraphVisitor; 54 class TestGraphVisitor;
48 55
49 // Translate an AstNode to a control-flow graph fragment for its effects 56 // Translate an AstNode to a control-flow graph fragment for its effects
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after
264 } 271 }
265 272
266 // Output parameters. 273 // Output parameters.
267 TargetEntryInstr** true_successor_address_; 274 TargetEntryInstr** true_successor_address_;
268 TargetEntryInstr** false_successor_address_; 275 TargetEntryInstr** false_successor_address_;
269 }; 276 };
270 277
271 } // namespace dart 278 } // namespace dart
272 279
273 #endif // VM_FLOW_GRAPH_BUILDER_H_ 280 #endif // VM_FLOW_GRAPH_BUILDER_H_
OLDNEW
« no previous file with comments | « no previous file | runtime/vm/flow_graph_builder.cc » ('j') | runtime/vm/flow_graph_builder.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698