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

Side by Side Diff: src/IceTargetLoweringMIPS32.h

Issue 2619363003: Subzero, MIPS32: Atomic intrinsics fixes (Closed)
Patch Set: Addressed review comments Created 3 years, 11 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 | « src/IceTargetLowering.h ('k') | src/IceTargetLoweringMIPS32.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/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 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 PrologEmitsFixedAllocas = true; 105 PrologEmitsFixedAllocas = true;
106 } 106 }
107 int32_t getFrameFixedAllocaOffset() const override { 107 int32_t getFrameFixedAllocaOffset() const override {
108 int32_t FixedAllocaOffset = 108 int32_t FixedAllocaOffset =
109 Utils::applyAlignment(CurrentAllocaOffset, FixedAllocaAlignBytes); 109 Utils::applyAlignment(CurrentAllocaOffset, FixedAllocaAlignBytes);
110 return FixedAllocaOffset - MaxOutArgsSizeBytes; 110 return FixedAllocaOffset - MaxOutArgsSizeBytes;
111 } 111 }
112 112
113 uint32_t maxOutArgsSizeBytes() const override { return MaxOutArgsSizeBytes; } 113 uint32_t maxOutArgsSizeBytes() const override { return MaxOutArgsSizeBytes; }
114 114
115 uint32_t getFramePointerOffset(uint32_t CurrentOffset,
116 uint32_t Size) const override {
117 (void)Size;
118 return CurrentOffset + MaxOutArgsSizeBytes;
119 }
120
115 bool shouldSplitToVariable64On32(Type Ty) const override { 121 bool shouldSplitToVariable64On32(Type Ty) const override {
116 return Ty == IceType_i64; 122 return Ty == IceType_i64;
117 } 123 }
118 124
119 bool shouldSplitToVariableVecOn32(Type Ty) const override { 125 bool shouldSplitToVariableVecOn32(Type Ty) const override {
120 return isVectorType(Ty); 126 return isVectorType(Ty);
121 } 127 }
122 128
123 // TODO(ascull): what is the best size of MIPS? 129 // TODO(ascull): what is the best size of MIPS?
124 SizeT getMinJumpTableSize() const override { return 3; } 130 SizeT getMinJumpTableSize() const override { return 3; }
(...skipping 476 matching lines...) Expand 10 before | Expand all | Expand 10 after
601 607
602 public: 608 public:
603 explicit Sandboxer( 609 explicit Sandboxer(
604 TargetMIPS32 *Target, 610 TargetMIPS32 *Target,
605 InstBundleLock::Option BundleOption = InstBundleLock::Opt_None); 611 InstBundleLock::Option BundleOption = InstBundleLock::Opt_None);
606 ~Sandboxer(); 612 ~Sandboxer();
607 613
608 void addiu_sp(uint32_t StackOffset); 614 void addiu_sp(uint32_t StackOffset);
609 void lw(Variable *Dest, OperandMIPS32Mem *Mem); 615 void lw(Variable *Dest, OperandMIPS32Mem *Mem);
610 void sw(Variable *Dest, OperandMIPS32Mem *Mem); 616 void sw(Variable *Dest, OperandMIPS32Mem *Mem);
617 void ll(Variable *Dest, OperandMIPS32Mem *Mem);
618 void sc(Variable *Dest, OperandMIPS32Mem *Mem);
611 void lwc1(Variable *Dest, OperandMIPS32Mem *Mem, RelocOp Reloc = RO_No); 619 void lwc1(Variable *Dest, OperandMIPS32Mem *Mem, RelocOp Reloc = RO_No);
612 void ldc1(Variable *Dest, OperandMIPS32Mem *Mem, RelocOp Reloc = RO_No); 620 void ldc1(Variable *Dest, OperandMIPS32Mem *Mem, RelocOp Reloc = RO_No);
613 void ret(Variable *RetAddr, Variable *RetValue); 621 void ret(Variable *RetAddr, Variable *RetValue);
614 void reset_sp(Variable *Src); 622 void reset_sp(Variable *Src);
615 InstMIPS32Call *jal(Variable *ReturnReg, Operand *CallTarget); 623 InstMIPS32Call *jal(Variable *ReturnReg, Operand *CallTarget);
616 624
617 private: 625 private:
618 TargetMIPS32 *const Target; 626 TargetMIPS32 *const Target;
619 const InstBundleLock::Option BundleOption; 627 const InstBundleLock::Option BundleOption;
620 std::unique_ptr<AutoBundle> Bundler; 628 std::unique_ptr<AutoBundle> Bundler;
(...skipping 425 matching lines...) Expand 10 before | Expand all | Expand 10 after
1046 uint32_t Flags1 = AFL_FLAGS1_ODDSPREG; 1054 uint32_t Flags1 = AFL_FLAGS1_ODDSPREG;
1047 uint32_t Flags2 = AFL_FLAGS2_NONE; 1055 uint32_t Flags2 = AFL_FLAGS2_NONE;
1048 1056
1049 MipsABIFlagsSection() = default; 1057 MipsABIFlagsSection() = default;
1050 }; 1058 };
1051 1059
1052 } // end of namespace MIPS32 1060 } // end of namespace MIPS32
1053 } // end of namespace Ice 1061 } // end of namespace Ice
1054 1062
1055 #endif // SUBZERO_SRC_ICETARGETLOWERINGMIPS32_H 1063 #endif // SUBZERO_SRC_ICETARGETLOWERINGMIPS32_H
OLDNEW
« no previous file with comments | « src/IceTargetLowering.h ('k') | src/IceTargetLoweringMIPS32.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698