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

Side by Side Diff: src/IceAssemblerMIPS32.h

Issue 2367743004: Subzero, MIPS32: Binding intrablock labels, unconditional branch (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: Addressing comments Created 4 years, 2 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
« no previous file with comments | « no previous file | src/IceInstMIPS32.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 //===- subzero/src/IceAssemblerMIPS32.h - Assembler for MIPS ----*- C++ -*-===// 1 //===- subzero/src/IceAssemblerMIPS32.h - Assembler for MIPS ----*- 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 260 matching lines...) Expand 10 before | Expand all | Expand 10 after
271 } 271 }
272 272
273 Label *getOrCreateCfgNodeLabel(SizeT NodeNumber) { 273 Label *getOrCreateCfgNodeLabel(SizeT NodeNumber) {
274 return getOrCreateLabel(NodeNumber, CfgNodeLabels); 274 return getOrCreateLabel(NodeNumber, CfgNodeLabels);
275 } 275 }
276 276
277 Label *getOrCreateLocalLabel(SizeT Number) { 277 Label *getOrCreateLocalLabel(SizeT Number) {
278 return getOrCreateLabel(Number, LocalLabels); 278 return getOrCreateLabel(Number, LocalLabels);
279 } 279 }
280 280
281 void bindLocalLabel(const InstMIPS32Label *InstL, SizeT Number) {
282 if (BuildDefs::dump() && !getFlags().getDisableHybridAssembly()) {
283 constexpr SizeT InstSize = 0;
284 emitTextInst(InstL->getLabelName() + ":", InstSize);
285 }
286 Label *L = getOrCreateLocalLabel(Number);
287 if (!getPreliminary())
288 this->bind(L);
289 }
290
281 bool fixupIsPCRel(FixupKind Kind) const override { 291 bool fixupIsPCRel(FixupKind Kind) const override {
282 (void)Kind; 292 (void)Kind;
283 llvm::report_fatal_error("Not yet implemented."); 293 llvm::report_fatal_error("Not yet implemented.");
284 } 294 }
285 295
286 static bool classof(const Assembler *Asm) { 296 static bool classof(const Assembler *Asm) {
287 return Asm->getKind() == Asm_MIPS32; 297 return Asm->getKind() == Asm_MIPS32;
288 } 298 }
289 299
290 private: 300 private:
(...skipping 13 matching lines...) Expand all
304 void emitInst(IValueT Value) { 314 void emitInst(IValueT Value) {
305 AssemblerBuffer::EnsureCapacity _(&Buffer); 315 AssemblerBuffer::EnsureCapacity _(&Buffer);
306 Buffer.emit<IValueT>(Value); 316 Buffer.emit<IValueT>(Value);
307 } 317 }
308 }; 318 };
309 319
310 } // end of namespace MIPS32 320 } // end of namespace MIPS32
311 } // end of namespace Ice 321 } // end of namespace Ice
312 322
313 #endif // SUBZERO_SRC_ICEASSEMBLERMIPS32_H 323 #endif // SUBZERO_SRC_ICEASSEMBLERMIPS32_H
OLDNEW
« no previous file with comments | « no previous file | src/IceInstMIPS32.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698