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

Side by Side Diff: src/IceTargetLoweringMIPS32.cpp

Issue 1691193002: Subzero: Prototype to make use of RegNumT::No Register more concise (Closed) Base URL: https://chromium.googlesource.com/native_client/pnacl-subzero.git@master
Patch Set: changes suggested by stichnot Created 4 years, 10 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
« src/IceOperand.h ('K') | « src/IceOperand.h ('k') | no next file » | 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/IceTargetLoweringMIPS32.cpp - MIPS32 lowering ----------===// 1 //===- subzero/src/IceTargetLoweringMIPS32.cpp - MIPS32 lowering ----------===//
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 342 matching lines...) Expand 10 before | Expand all | Expand 10 after
353 UnimplementedError(Func->getContext()->getFlags()); 353 UnimplementedError(Func->getContext()->getFlags());
354 return Ctx->getConstantZero(Ty); 354 return Ctx->getConstantZero(Ty);
355 } 355 }
356 return From; 356 return From;
357 } 357 }
358 358
359 Variable *TargetMIPS32::makeReg(Type Type, RegNumT RegNum) { 359 Variable *TargetMIPS32::makeReg(Type Type, RegNumT RegNum) {
360 // There aren't any 64-bit integer registers for Mips32. 360 // There aren't any 64-bit integer registers for Mips32.
361 assert(Type != IceType_i64); 361 assert(Type != IceType_i64);
362 Variable *Reg = Func->makeVariable(Type); 362 Variable *Reg = Func->makeVariable(Type);
363 if (RegNum == RegNumT::NoRegister) 363 if (RegNum.hasValue())
364 Reg->setMustHaveReg(); 364 Reg->setMustHaveReg();
365 else 365 else
366 Reg->setRegNum(RegNum); 366 Reg->setRegNum(RegNum);
367 return Reg; 367 return Reg;
368 } 368 }
369 369
370 void TargetMIPS32::emitVariable(const Variable *Var) const { 370 void TargetMIPS32::emitVariable(const Variable *Var) const {
371 if (!BuildDefs::dump()) 371 if (!BuildDefs::dump())
372 return; 372 return;
373 Ostream &Str = Ctx->getStrEmit(); 373 Ostream &Str = Ctx->getStrEmit();
(...skipping 926 matching lines...) Expand 10 before | Expand all | Expand 10 after
1300 Str << "\t.set\t" 1300 Str << "\t.set\t"
1301 << "nomips16\n"; 1301 << "nomips16\n";
1302 } 1302 }
1303 1303
1304 llvm::SmallBitVector TargetMIPS32::TypeToRegisterSet[RCMIPS32_NUM]; 1304 llvm::SmallBitVector TargetMIPS32::TypeToRegisterSet[RCMIPS32_NUM];
1305 llvm::SmallBitVector TargetMIPS32::TypeToRegisterSetUnfiltered[RCMIPS32_NUM]; 1305 llvm::SmallBitVector TargetMIPS32::TypeToRegisterSetUnfiltered[RCMIPS32_NUM];
1306 llvm::SmallBitVector TargetMIPS32::RegisterAliases[RegMIPS32::Reg_NUM]; 1306 llvm::SmallBitVector TargetMIPS32::RegisterAliases[RegMIPS32::Reg_NUM];
1307 1307
1308 } // end of namespace MIPS32 1308 } // end of namespace MIPS32
1309 } // end of namespace Ice 1309 } // end of namespace Ice
OLDNEW
« src/IceOperand.h ('K') | « src/IceOperand.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698