| 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 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 168 void _and(Variable *Dest, Variable *Src0, Variable *Src1) { | 168 void _and(Variable *Dest, Variable *Src0, Variable *Src1) { |
| 169 Context.insert<InstMIPS32And>(Dest, Src0, Src1); | 169 Context.insert<InstMIPS32And>(Dest, Src0, Src1); |
| 170 } | 170 } |
| 171 | 171 |
| 172 void _andi(Variable *Dest, Variable *Src, uint32_t Imm) { | 172 void _andi(Variable *Dest, Variable *Src, uint32_t Imm) { |
| 173 Context.insert<InstMIPS32Andi>(Dest, Src, Imm); | 173 Context.insert<InstMIPS32Andi>(Dest, Src, Imm); |
| 174 } | 174 } |
| 175 | 175 |
| 176 void _br(CfgNode *Target) { Context.insert<InstMIPS32Br>(Target); } | 176 void _br(CfgNode *Target) { Context.insert<InstMIPS32Br>(Target); } |
| 177 | 177 |
| 178 void _br(CfgNode *Target, const InstMIPS32Label *Label) { |
| 179 Context.insert<InstMIPS32Br>(Target, Label); |
| 180 } |
| 181 |
| 178 void _br(CfgNode *TargetTrue, CfgNode *TargetFalse, Operand *Src0, | 182 void _br(CfgNode *TargetTrue, CfgNode *TargetFalse, Operand *Src0, |
| 179 Operand *Src1, CondMIPS32::Cond Condition) { | 183 Operand *Src1, CondMIPS32::Cond Condition) { |
| 180 Context.insert<InstMIPS32Br>(TargetTrue, TargetFalse, Src0, Src1, | 184 Context.insert<InstMIPS32Br>(TargetTrue, TargetFalse, Src0, Src1, |
| 181 Condition); | 185 Condition); |
| 182 } | 186 } |
| 183 | 187 |
| 184 void _br(CfgNode *TargetTrue, CfgNode *TargetFalse, Operand *Src0, | 188 void _br(CfgNode *TargetTrue, CfgNode *TargetFalse, Operand *Src0, |
| 185 CondMIPS32::Cond Condition) { | 189 CondMIPS32::Cond Condition) { |
| 186 Context.insert<InstMIPS32Br>(TargetTrue, TargetFalse, Src0, Condition); | 190 Context.insert<InstMIPS32Br>(TargetTrue, TargetFalse, Src0, Condition); |
| 187 } | 191 } |
| (...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 322 } | 326 } |
| 323 | 327 |
| 324 void _divu(Variable *Dest, Variable *Src0, Variable *Src1) { | 328 void _divu(Variable *Dest, Variable *Src0, Variable *Src1) { |
| 325 Context.insert<InstMIPS32Divu>(Dest, Src0, Src1); | 329 Context.insert<InstMIPS32Divu>(Dest, Src0, Src1); |
| 326 } | 330 } |
| 327 | 331 |
| 328 void _ldc1(Variable *Value, OperandMIPS32Mem *Mem, RelocOp Reloc = RO_No) { | 332 void _ldc1(Variable *Value, OperandMIPS32Mem *Mem, RelocOp Reloc = RO_No) { |
| 329 Context.insert<InstMIPS32Ldc1>(Value, Mem, Reloc); | 333 Context.insert<InstMIPS32Ldc1>(Value, Mem, Reloc); |
| 330 } | 334 } |
| 331 | 335 |
| 336 void _ll(Variable *Value, OperandMIPS32Mem *Mem) { |
| 337 Context.insert<InstMIPS32Ll>(Value, Mem); |
| 338 } |
| 339 |
| 332 void _lw(Variable *Value, OperandMIPS32Mem *Mem) { | 340 void _lw(Variable *Value, OperandMIPS32Mem *Mem) { |
| 333 Context.insert<InstMIPS32Lw>(Value, Mem); | 341 Context.insert<InstMIPS32Lw>(Value, Mem); |
| 334 } | 342 } |
| 335 | 343 |
| 336 void _lwc1(Variable *Value, OperandMIPS32Mem *Mem, RelocOp Reloc = RO_No) { | 344 void _lwc1(Variable *Value, OperandMIPS32Mem *Mem, RelocOp Reloc = RO_No) { |
| 337 Context.insert<InstMIPS32Lwc1>(Value, Mem, Reloc); | 345 Context.insert<InstMIPS32Lwc1>(Value, Mem, Reloc); |
| 338 } | 346 } |
| 339 | 347 |
| 340 void _lui(Variable *Dest, Operand *Src, RelocOp Reloc = RO_No) { | 348 void _lui(Variable *Dest, Operand *Src, RelocOp Reloc = RO_No) { |
| 341 Context.insert<InstMIPS32Lui>(Dest, Src, Reloc); | 349 Context.insert<InstMIPS32Lui>(Dest, Src, Reloc); |
| (...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 467 } | 475 } |
| 468 | 476 |
| 469 void _or(Variable *Dest, Variable *Src0, Variable *Src1) { | 477 void _or(Variable *Dest, Variable *Src0, Variable *Src1) { |
| 470 Context.insert<InstMIPS32Or>(Dest, Src0, Src1); | 478 Context.insert<InstMIPS32Or>(Dest, Src0, Src1); |
| 471 } | 479 } |
| 472 | 480 |
| 473 void _ori(Variable *Dest, Variable *Src, uint32_t Imm) { | 481 void _ori(Variable *Dest, Variable *Src, uint32_t Imm) { |
| 474 Context.insert<InstMIPS32Ori>(Dest, Src, Imm); | 482 Context.insert<InstMIPS32Ori>(Dest, Src, Imm); |
| 475 } | 483 } |
| 476 | 484 |
| 485 InstMIPS32Sc *_sc(Variable *Value, OperandMIPS32Mem *Mem) { |
| 486 return Context.insert<InstMIPS32Sc>(Value, Mem); |
| 487 } |
| 488 |
| 477 void _sdc1(Variable *Value, OperandMIPS32Mem *Mem) { | 489 void _sdc1(Variable *Value, OperandMIPS32Mem *Mem) { |
| 478 Context.insert<InstMIPS32Sdc1>(Value, Mem); | 490 Context.insert<InstMIPS32Sdc1>(Value, Mem); |
| 479 } | 491 } |
| 480 | 492 |
| 481 void _sll(Variable *Dest, Variable *Src, uint32_t Imm) { | 493 void _sll(Variable *Dest, Variable *Src, uint32_t Imm) { |
| 482 Context.insert<InstMIPS32Sll>(Dest, Src, Imm); | 494 Context.insert<InstMIPS32Sll>(Dest, Src, Imm); |
| 483 } | 495 } |
| 484 | 496 |
| 485 void _sllv(Variable *Dest, Variable *Src0, Variable *Src1) { | 497 void _sllv(Variable *Dest, Variable *Src0, Variable *Src1) { |
| 486 Context.insert<InstMIPS32Sllv>(Dest, Src0, Src1); | 498 Context.insert<InstMIPS32Sllv>(Dest, Src0, Src1); |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 543 } | 555 } |
| 544 | 556 |
| 545 void _sw(Variable *Value, OperandMIPS32Mem *Mem) { | 557 void _sw(Variable *Value, OperandMIPS32Mem *Mem) { |
| 546 Context.insert<InstMIPS32Sw>(Value, Mem); | 558 Context.insert<InstMIPS32Sw>(Value, Mem); |
| 547 } | 559 } |
| 548 | 560 |
| 549 void _swc1(Variable *Value, OperandMIPS32Mem *Mem) { | 561 void _swc1(Variable *Value, OperandMIPS32Mem *Mem) { |
| 550 Context.insert<InstMIPS32Swc1>(Value, Mem); | 562 Context.insert<InstMIPS32Swc1>(Value, Mem); |
| 551 } | 563 } |
| 552 | 564 |
| 565 void _sync() { Context.insert<InstMIPS32Sync>(); } |
| 566 |
| 553 void _teq(Variable *Src0, Variable *Src1, uint32_t TrapCode) { | 567 void _teq(Variable *Src0, Variable *Src1, uint32_t TrapCode) { |
| 554 Context.insert<InstMIPS32Teq>(Src0, Src1, TrapCode); | 568 Context.insert<InstMIPS32Teq>(Src0, Src1, TrapCode); |
| 555 } | 569 } |
| 556 | 570 |
| 557 void _trunc_l_d(Variable *Dest, Variable *Src) { | 571 void _trunc_l_d(Variable *Dest, Variable *Src) { |
| 558 Context.insert<InstMIPS32Trunc_l_d>(Dest, Src); | 572 Context.insert<InstMIPS32Trunc_l_d>(Dest, Src); |
| 559 } | 573 } |
| 560 | 574 |
| 561 void _trunc_l_s(Variable *Dest, Variable *Src) { | 575 void _trunc_l_s(Variable *Dest, Variable *Src) { |
| 562 Context.insert<InstMIPS32Trunc_l_s>(Dest, Src); | 576 Context.insert<InstMIPS32Trunc_l_s>(Dest, Src); |
| (...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 739 Operand *Src0, Operand *Src1); | 753 Operand *Src0, Operand *Src1); |
| 740 void lowerAssign(const InstAssign *Instr) override; | 754 void lowerAssign(const InstAssign *Instr) override; |
| 741 void lowerBr(const InstBr *Instr) override; | 755 void lowerBr(const InstBr *Instr) override; |
| 742 void lowerBreakpoint(const InstBreakpoint *Instr) override; | 756 void lowerBreakpoint(const InstBreakpoint *Instr) override; |
| 743 void lowerCall(const InstCall *Instr) override; | 757 void lowerCall(const InstCall *Instr) override; |
| 744 void lowerCast(const InstCast *Instr) override; | 758 void lowerCast(const InstCast *Instr) override; |
| 745 void lowerExtractElement(const InstExtractElement *Instr) override; | 759 void lowerExtractElement(const InstExtractElement *Instr) override; |
| 746 void lowerFcmp(const InstFcmp *Instr) override; | 760 void lowerFcmp(const InstFcmp *Instr) override; |
| 747 void lowerIcmp(const InstIcmp *Instr) override; | 761 void lowerIcmp(const InstIcmp *Instr) override; |
| 748 void lower64Icmp(const InstIcmp *Instr); | 762 void lower64Icmp(const InstIcmp *Instr); |
| 763 void createArithInst(Intrinsics::AtomicRMWOperation Operation, Variable *Dest, |
| 764 Variable *Src0, Variable *Src1); |
| 749 void lowerIntrinsicCall(const InstIntrinsicCall *Instr) override; | 765 void lowerIntrinsicCall(const InstIntrinsicCall *Instr) override; |
| 750 void lowerInsertElement(const InstInsertElement *Instr) override; | 766 void lowerInsertElement(const InstInsertElement *Instr) override; |
| 751 void lowerLoad(const InstLoad *Instr) override; | 767 void lowerLoad(const InstLoad *Instr) override; |
| 752 void lowerPhi(const InstPhi *Instr) override; | 768 void lowerPhi(const InstPhi *Instr) override; |
| 753 void lowerRet(const InstRet *Instr) override; | 769 void lowerRet(const InstRet *Instr) override; |
| 754 void lowerSelect(const InstSelect *Instr) override; | 770 void lowerSelect(const InstSelect *Instr) override; |
| 755 void lowerShuffleVector(const InstShuffleVector *Instr) override; | 771 void lowerShuffleVector(const InstShuffleVector *Instr) override; |
| 756 void lowerStore(const InstStore *Instr) override; | 772 void lowerStore(const InstStore *Instr) override; |
| 757 void lowerSwitch(const InstSwitch *Instr) override; | 773 void lowerSwitch(const InstSwitch *Instr) override; |
| 758 void lowerUnreachable(const InstUnreachable *Instr) override; | 774 void lowerUnreachable(const InstUnreachable *Instr) override; |
| (...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1030 uint32_t Flags1 = AFL_FLAGS1_ODDSPREG; | 1046 uint32_t Flags1 = AFL_FLAGS1_ODDSPREG; |
| 1031 uint32_t Flags2 = AFL_FLAGS2_NONE; | 1047 uint32_t Flags2 = AFL_FLAGS2_NONE; |
| 1032 | 1048 |
| 1033 MipsABIFlagsSection() = default; | 1049 MipsABIFlagsSection() = default; |
| 1034 }; | 1050 }; |
| 1035 | 1051 |
| 1036 } // end of namespace MIPS32 | 1052 } // end of namespace MIPS32 |
| 1037 } // end of namespace Ice | 1053 } // end of namespace Ice |
| 1038 | 1054 |
| 1039 #endif // SUBZERO_SRC_ICETARGETLOWERINGMIPS32_H | 1055 #endif // SUBZERO_SRC_ICETARGETLOWERINGMIPS32_H |
| OLD | NEW |