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

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

Issue 13932005: Refactor the code for making inlining decisions. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 8 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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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_INTERMEDIATE_LANGUAGE_H_ 5 #ifndef VM_INTERMEDIATE_LANGUAGE_H_
6 #define VM_INTERMEDIATE_LANGUAGE_H_ 6 #define VM_INTERMEDIATE_LANGUAGE_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 1186 matching lines...) Expand 10 before | Expand all | Expand 10 after
1197 void InsertPhi(intptr_t var_index, intptr_t var_count); 1197 void InsertPhi(intptr_t var_index, intptr_t var_count);
1198 void RemoveDeadPhis(Definition* replacement); 1198 void RemoveDeadPhis(Definition* replacement);
1199 1199
1200 void InsertPhi(PhiInstr* phi); 1200 void InsertPhi(PhiInstr* phi);
1201 1201
1202 virtual void PrintTo(BufferFormatter* f) const; 1202 virtual void PrintTo(BufferFormatter* f) const;
1203 1203
1204 private: 1204 private:
1205 // Classes that have access to predecessors_ when inlining. 1205 // Classes that have access to predecessors_ when inlining.
1206 friend class BlockEntryInstr; 1206 friend class BlockEntryInstr;
1207 friend class InliningContext; 1207 friend class InlineExitCollector;
1208 1208
1209 // Direct access to phis_ in order to resize it due to phi elimination. 1209 // Direct access to phis_ in order to resize it due to phi elimination.
1210 friend class ConstantPropagator; 1210 friend class ConstantPropagator;
1211 1211
1212 virtual void ClearPredecessors() { predecessors_.Clear(); } 1212 virtual void ClearPredecessors() { predecessors_.Clear(); }
1213 virtual void AddPredecessor(BlockEntryInstr* predecessor); 1213 virtual void AddPredecessor(BlockEntryInstr* predecessor);
1214 1214
1215 GrowableArray<BlockEntryInstr*> predecessors_; 1215 GrowableArray<BlockEntryInstr*> predecessors_;
1216 ZoneGrowableArray<PhiInstr*>* phis_; 1216 ZoneGrowableArray<PhiInstr*>* phis_;
1217 1217
(...skipping 3661 matching lines...) Expand 10 before | Expand all | Expand 10 after
4879 ForwardInstructionIterator* current_iterator_; 4879 ForwardInstructionIterator* current_iterator_;
4880 4880
4881 private: 4881 private:
4882 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor); 4882 DISALLOW_COPY_AND_ASSIGN(FlowGraphVisitor);
4883 }; 4883 };
4884 4884
4885 4885
4886 } // namespace dart 4886 } // namespace dart
4887 4887
4888 #endif // VM_INTERMEDIATE_LANGUAGE_H_ 4888 #endif // VM_INTERMEDIATE_LANGUAGE_H_
OLDNEW
« runtime/vm/flow_graph_inliner.cc ('K') | « runtime/vm/flow_graph_inliner.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698