| OLD | NEW |
| 1 //===- subzero/src/IceTargetLoweringX8632Traits.h - x86-32 traits -*- C++ -*-=// | 1 //===- subzero/src/IceTargetLoweringX8632Traits.h - x86-32 traits -*- 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 532 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 543 using Assembler = X8632::AssemblerX8632; | 543 using Assembler = X8632::AssemblerX8632; |
| 544 | 544 |
| 545 /// X86Operand extends the Operand hierarchy. Its subclasses are | 545 /// X86Operand extends the Operand hierarchy. Its subclasses are |
| 546 /// X86OperandMem and VariableSplit. | 546 /// X86OperandMem and VariableSplit. |
| 547 class X86Operand : public ::Ice::Operand { | 547 class X86Operand : public ::Ice::Operand { |
| 548 X86Operand() = delete; | 548 X86Operand() = delete; |
| 549 X86Operand(const X86Operand &) = delete; | 549 X86Operand(const X86Operand &) = delete; |
| 550 X86Operand &operator=(const X86Operand &) = delete; | 550 X86Operand &operator=(const X86Operand &) = delete; |
| 551 | 551 |
| 552 public: | 552 public: |
| 553 enum OperandKindX8632 { k__Start = ::Ice::Operand::kTarget, kMem, kSplit }; | 553 enum OperandKindX8632 { k__Start = ::Ice::Operand::kTarget0, kMem, kSplit }; |
| 554 using ::Ice::Operand::dump; | 554 using ::Ice::Operand::dump; |
| 555 | 555 |
| 556 void dump(const Cfg *, Ostream &Str) const override; | 556 void dump(const Cfg *, Ostream &Str) const override; |
| 557 | 557 |
| 558 protected: | 558 protected: |
| 559 X86Operand(OperandKindX8632 Kind, Type Ty) | 559 X86Operand(OperandKindX8632 Kind, Type Ty) |
| 560 : Operand(static_cast<::Ice::Operand::OperandKind>(Kind), Ty) {} | 560 : Operand(static_cast<::Ice::Operand::OperandKind>(Kind), Ty) {} |
| 561 }; | 561 }; |
| 562 | 562 |
| 563 /// X86OperandMem represents the m32 addressing mode, with optional base and | 563 /// X86OperandMem represents the m32 addressing mode, with optional base and |
| (...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 668 class SpillVariable : public Variable { | 668 class SpillVariable : public Variable { |
| 669 SpillVariable() = delete; | 669 SpillVariable() = delete; |
| 670 SpillVariable(const SpillVariable &) = delete; | 670 SpillVariable(const SpillVariable &) = delete; |
| 671 SpillVariable &operator=(const SpillVariable &) = delete; | 671 SpillVariable &operator=(const SpillVariable &) = delete; |
| 672 | 672 |
| 673 public: | 673 public: |
| 674 static SpillVariable *create(Cfg *Func, Type Ty, SizeT Index) { | 674 static SpillVariable *create(Cfg *Func, Type Ty, SizeT Index) { |
| 675 return new (Func->allocate<SpillVariable>()) SpillVariable(Ty, Index); | 675 return new (Func->allocate<SpillVariable>()) SpillVariable(Ty, Index); |
| 676 } | 676 } |
| 677 const static OperandKind SpillVariableKind = | 677 const static OperandKind SpillVariableKind = |
| 678 static_cast<OperandKind>(kVariable_Target); | 678 static_cast<OperandKind>(kVariable_Target0); |
| 679 static bool classof(const Operand *Operand) { | 679 static bool classof(const Operand *Operand) { |
| 680 return Operand->getKind() == SpillVariableKind; | 680 return Operand->getKind() == SpillVariableKind; |
| 681 } | 681 } |
| 682 void setLinkedTo(Variable *Var) { LinkedTo = Var; } | 682 void setLinkedTo(Variable *Var) { LinkedTo = Var; } |
| 683 Variable *getLinkedTo() const { return LinkedTo; } | 683 Variable *getLinkedTo() const { return LinkedTo; } |
| 684 // Inherit dump() and emit() from Variable. | 684 // Inherit dump() and emit() from Variable. |
| 685 | 685 |
| 686 private: | 686 private: |
| 687 SpillVariable(Type Ty, SizeT Index) | 687 SpillVariable(Type Ty, SizeT Index) |
| 688 : Variable(SpillVariableKind, Ty, Index), LinkedTo(nullptr) {} | 688 : Variable(SpillVariableKind, Ty, Index), LinkedTo(nullptr) {} |
| (...skipping 27 matching lines...) Expand all Loading... |
| 716 | 716 |
| 717 } // end of namespace X86Internal | 717 } // end of namespace X86Internal |
| 718 | 718 |
| 719 namespace X8632 { | 719 namespace X8632 { |
| 720 using Traits = ::Ice::X86Internal::MachineTraits<TargetX8632>; | 720 using Traits = ::Ice::X86Internal::MachineTraits<TargetX8632>; |
| 721 } // end of namespace X8632 | 721 } // end of namespace X8632 |
| 722 | 722 |
| 723 } // end of namespace Ice | 723 } // end of namespace Ice |
| 724 | 724 |
| 725 #endif // SUBZERO_SRC_ICETARGETLOWERINGX8632TRAITS_H | 725 #endif // SUBZERO_SRC_ICETARGETLOWERINGX8632TRAITS_H |
| OLD | NEW |