| OLD | NEW |
| 1 //===- subzero/src/IceCfgNode.h - Control flow graph node -------*- C++ -*-===// | 1 //===- subzero/src/IceCfgNode.h - Control flow graph node -------*- C++ -*-===// |
| 2 // | 2 // |
| 3 // The Subzero Code Generator | 3 // The Subzero Code Generator |
| 4 // | 4 // |
| 5 // This file is distributed under the University of Illinois Open Source | 5 // This file is distributed under the University of Illinois Open Source |
| 6 // License. See LICENSE.TXT for details. | 6 // License. See LICENSE.TXT for details. |
| 7 // | 7 // |
| 8 //===----------------------------------------------------------------------===// | 8 //===----------------------------------------------------------------------===// |
| 9 /// | 9 /// |
| 10 /// \file | 10 /// \file |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 47 } | 47 } |
| 48 | 48 |
| 49 /// The HasReturn flag indicates that this node contains a return | 49 /// The HasReturn flag indicates that this node contains a return |
| 50 /// instruction and therefore needs an epilog. | 50 /// instruction and therefore needs an epilog. |
| 51 void setHasReturn() { HasReturn = true; } | 51 void setHasReturn() { HasReturn = true; } |
| 52 bool getHasReturn() const { return HasReturn; } | 52 bool getHasReturn() const { return HasReturn; } |
| 53 | 53 |
| 54 void setNeedsPlacement(bool Value) { NeedsPlacement = Value; } | 54 void setNeedsPlacement(bool Value) { NeedsPlacement = Value; } |
| 55 bool needsPlacement() const { return NeedsPlacement; } | 55 bool needsPlacement() const { return NeedsPlacement; } |
| 56 | 56 |
| 57 void setNeedsAlignment() { NeedsAlignment = true; } |
| 58 bool needsAlignment() const { return NeedsAlignment; } |
| 59 |
| 57 /// \name Access predecessor and successor edge lists. | 60 /// \name Access predecessor and successor edge lists. |
| 58 /// @{ | 61 /// @{ |
| 59 const NodeList &getInEdges() const { return InEdges; } | 62 const NodeList &getInEdges() const { return InEdges; } |
| 60 const NodeList &getOutEdges() const { return OutEdges; } | 63 const NodeList &getOutEdges() const { return OutEdges; } |
| 61 /// @} | 64 /// @} |
| 62 | 65 |
| 63 /// \name Manage the instruction list. | 66 /// \name Manage the instruction list. |
| 64 /// @{ | 67 /// @{ |
| 65 InstList &getInsts() { return Insts; } | 68 InstList &getInsts() { return Insts; } |
| 66 PhiList &getPhis() { return Phis; } | 69 PhiList &getPhis() { return Phis; } |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 103 void profileExecutionCount(VariableDeclaration *Var); | 106 void profileExecutionCount(VariableDeclaration *Var); |
| 104 | 107 |
| 105 private: | 108 private: |
| 106 CfgNode(Cfg *Func, SizeT LabelIndex); | 109 CfgNode(Cfg *Func, SizeT LabelIndex); |
| 107 Cfg *const Func; | 110 Cfg *const Func; |
| 108 SizeT Number; /// label index | 111 SizeT Number; /// label index |
| 109 Cfg::IdentifierIndexType NameIndex = | 112 Cfg::IdentifierIndexType NameIndex = |
| 110 Cfg::IdentifierIndexInvalid; /// index into Cfg::NodeNames table | 113 Cfg::IdentifierIndexInvalid; /// index into Cfg::NodeNames table |
| 111 bool HasReturn = false; /// does this block need an epilog? | 114 bool HasReturn = false; /// does this block need an epilog? |
| 112 bool NeedsPlacement = false; | 115 bool NeedsPlacement = false; |
| 116 bool NeedsAlignment = false; /// is sandboxing required? |
| 113 InstNumberT InstCountEstimate = 0; /// rough instruction count estimate | 117 InstNumberT InstCountEstimate = 0; /// rough instruction count estimate |
| 114 NodeList InEdges; /// in no particular order | 118 NodeList InEdges; /// in no particular order |
| 115 NodeList OutEdges; /// in no particular order | 119 NodeList OutEdges; /// in no particular order |
| 116 PhiList Phis; /// unordered set of phi instructions | 120 PhiList Phis; /// unordered set of phi instructions |
| 117 InstList Insts; /// ordered list of non-phi instructions | 121 InstList Insts; /// ordered list of non-phi instructions |
| 118 }; | 122 }; |
| 119 | 123 |
| 120 } // end of namespace Ice | 124 } // end of namespace Ice |
| 121 | 125 |
| 122 #endif // SUBZERO_SRC_ICECFGNODE_H | 126 #endif // SUBZERO_SRC_ICECFGNODE_H |
| OLD | NEW |