Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 //===- subzero/src/IceTargetLoweringMIPS32.h - MIPS32 lowering ---*- C++-*-===// | 1 //===- subzero/src/IceTargetLoweringMIPS32.h - MIPS32 lowering ---*- 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 347 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 358 auto *Instr = Context.insert<InstMIPS32Mov>(Dest, Src0, Src1); | 358 auto *Instr = Context.insert<InstMIPS32Mov>(Dest, Src0, Src1); |
| 359 if (Instr->getDestHi() != nullptr) { | 359 if (Instr->getDestHi() != nullptr) { |
| 360 // If DestHi is available, then Dest must be a Variable64On32. We add a | 360 // If DestHi is available, then Dest must be a Variable64On32. We add a |
| 361 // fake-def for Instr.DestHi here. | 361 // fake-def for Instr.DestHi here. |
| 362 assert(llvm::isa<Variable64On32>(Dest)); | 362 assert(llvm::isa<Variable64On32>(Dest)); |
| 363 Context.insert<InstFakeDef>(Instr->getDestHi()); | 363 Context.insert<InstFakeDef>(Instr->getDestHi()); |
| 364 } | 364 } |
| 365 } | 365 } |
| 366 } | 366 } |
| 367 | 367 |
| 368 void _mov_redefined(Variable *Dest, Operand *Src0, Operand *Src1 = nullptr) { | |
| 369 if (llvm::isa<ConstantRelocatable>(Src0)) { | |
| 370 Context.insert<InstMIPS32La>(Dest, Src0); | |
| 371 } else { | |
| 372 auto *Instr = Context.insert<InstMIPS32Mov>(Dest, Src0, Src1); | |
| 373 Instr->setDestRedefined(); | |
| 374 if (Instr->getDestHi() != nullptr) { | |
| 375 // If Instr is multi-dest, then Dest must be a Variable64On32. We add a | |
|
jaydeep.patil
2016/10/27 09:59:39
Reflow comment to 80-col
Jim Stichnoth
2016/10/27 14:03:38
Actually this needs a "make -f Makefile.standalone
| |
| 376 // fake-def for Instr.DestHi here. | |
| 377 assert(llvm::isa<Variable64On32>(Dest)); | |
| 378 Context.insert<InstFakeDef>(Instr->getDestHi()); | |
| 379 } | |
| 380 } | |
| 381 } | |
| 382 | |
| 368 void _mov_d(Variable *Dest, Variable *Src) { | 383 void _mov_d(Variable *Dest, Variable *Src) { |
| 369 Context.insert<InstMIPS32Mov_d>(Dest, Src); | 384 Context.insert<InstMIPS32Mov_d>(Dest, Src); |
| 370 } | 385 } |
| 371 | 386 |
| 372 void _mov_s(Variable *Dest, Variable *Src) { | 387 void _mov_s(Variable *Dest, Variable *Src) { |
| 373 Context.insert<InstMIPS32Mov_s>(Dest, Src); | 388 Context.insert<InstMIPS32Mov_s>(Dest, Src); |
| 374 } | 389 } |
| 375 | 390 |
| 376 void _movf(Variable *Dest, Variable *Src0, Operand *FCC) { | 391 void _movf(Variable *Dest, Variable *Src0, Operand *FCC) { |
| 377 Context.insert<InstMIPS32Movf>(Dest, Src0, FCC)->setDestRedefined(); | 392 Context.insert<InstMIPS32Movf>(Dest, Src0, FCC)->setDestRedefined(); |
| (...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 882 explicit TargetHeaderMIPS32(GlobalContext *Ctx); | 897 explicit TargetHeaderMIPS32(GlobalContext *Ctx); |
| 883 | 898 |
| 884 private: | 899 private: |
| 885 ~TargetHeaderMIPS32() = default; | 900 ~TargetHeaderMIPS32() = default; |
| 886 }; | 901 }; |
| 887 | 902 |
| 888 } // end of namespace MIPS32 | 903 } // end of namespace MIPS32 |
| 889 } // end of namespace Ice | 904 } // end of namespace Ice |
| 890 | 905 |
| 891 #endif // SUBZERO_SRC_ICETARGETLOWERINGMIPS32_H | 906 #endif // SUBZERO_SRC_ICETARGETLOWERINGMIPS32_H |
| OLD | NEW |