| OLD | NEW |
| 1 //===- subzero/src/IceAssemblerARM32.h - Assembler for ARM32 ----*- C++ -*-===// | 1 //===- subzero/src/IceAssemblerARM32.h - Assembler for ARM32 ----*- C++ -*-===// |
| 2 // | 2 // |
| 3 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 3 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 4 // for details. All rights reserved. Use of this source code is governed by a | 4 // for details. All rights reserved. Use of this source code is governed by a |
| 5 // BSD-style license that can be found in the LICENSE file. | 5 // BSD-style license that can be found in the LICENSE file. |
| 6 // | 6 // |
| 7 // Modified by the Subzero authors. | 7 // Modified by the Subzero authors. |
| 8 // | 8 // |
| 9 //===----------------------------------------------------------------------===// | 9 //===----------------------------------------------------------------------===// |
| 10 // | 10 // |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 112 } | 112 } |
| 113 | 113 |
| 114 Label *getOrCreateCfgNodeLabel(SizeT NodeNumber) { | 114 Label *getOrCreateCfgNodeLabel(SizeT NodeNumber) { |
| 115 return getOrCreateLabel(NodeNumber, CfgNodeLabels); | 115 return getOrCreateLabel(NodeNumber, CfgNodeLabels); |
| 116 } | 116 } |
| 117 | 117 |
| 118 Label *getOrCreateLocalLabel(SizeT Number) { | 118 Label *getOrCreateLocalLabel(SizeT Number) { |
| 119 return getOrCreateLabel(Number, LocalLabels); | 119 return getOrCreateLabel(Number, LocalLabels); |
| 120 } | 120 } |
| 121 | 121 |
| 122 void bindLocalLabel(SizeT Number) { | 122 void bindLocalLabel(const Cfg *Func, const InstARM32Label *InstL, |
| 123 SizeT Number) { |
| 124 if (BuildDefs::dump() && |
| 125 !Func->getContext()->getFlags().getDisableHybridAssembly()) { |
| 126 constexpr SizeT InstSize = 0; |
| 127 emitTextInst(InstL->getName(Func) + ":", InstSize); |
| 128 } |
| 123 Label *L = getOrCreateLocalLabel(Number); | 129 Label *L = getOrCreateLocalLabel(Number); |
| 124 if (!getPreliminary()) | 130 if (!getPreliminary()) |
| 125 this->bind(L); | 131 this->bind(L); |
| 126 } | 132 } |
| 127 | 133 |
| 128 bool fixupIsPCRel(FixupKind Kind) const override { | 134 bool fixupIsPCRel(FixupKind Kind) const override { |
| 129 (void)Kind; | 135 (void)Kind; |
| 130 // TODO(kschimpf) Decide if we need this. | 136 // TODO(kschimpf) Decide if we need this. |
| 131 return false; | 137 return false; |
| 132 } | 138 } |
| (...skipping 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 240 IValueT encodeBranchOffset(IOffsetT Offset, IValueT Inst); | 246 IValueT encodeBranchOffset(IOffsetT Offset, IValueT Inst); |
| 241 | 247 |
| 242 // Returns the offset encoded in the branch instruction Inst. | 248 // Returns the offset encoded in the branch instruction Inst. |
| 243 static IOffsetT decodeBranchOffset(IValueT Inst); | 249 static IOffsetT decodeBranchOffset(IValueT Inst); |
| 244 }; | 250 }; |
| 245 | 251 |
| 246 } // end of namespace ARM32 | 252 } // end of namespace ARM32 |
| 247 } // end of namespace Ice | 253 } // end of namespace Ice |
| 248 | 254 |
| 249 #endif // SUBZERO_SRC_ICEASSEMBLERARM32_H | 255 #endif // SUBZERO_SRC_ICEASSEMBLERARM32_H |
| OLD | NEW |