OLD | NEW |
1 //===- subzero/src/IceTargetLoweringX8632.h - x86-32 lowering ---*- C++ -*-===// | 1 //===- subzero/src/IceTargetLoweringX8632.h - x86-32 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 // This file declares the TargetLoweringX8632 class, which | 10 // This file declares the TargetLoweringX8632 class, which |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
42 bool hasFramePointer() const override { return IsEbpBasedFrame; } | 42 bool hasFramePointer() const override { return IsEbpBasedFrame; } |
43 SizeT getFrameOrStackReg() const override { | 43 SizeT getFrameOrStackReg() const override { |
44 return IsEbpBasedFrame ? RegX8632::Reg_ebp : RegX8632::Reg_esp; | 44 return IsEbpBasedFrame ? RegX8632::Reg_ebp : RegX8632::Reg_esp; |
45 } | 45 } |
46 size_t typeWidthInBytesOnStack(Type Ty) const override { | 46 size_t typeWidthInBytesOnStack(Type Ty) const override { |
47 // Round up to the next multiple of 4 bytes. In particular, i1, | 47 // Round up to the next multiple of 4 bytes. In particular, i1, |
48 // i8, and i16 are rounded up to 4 bytes. | 48 // i8, and i16 are rounded up to 4 bytes. |
49 return (typeWidthInBytes(Ty) + 3) & ~3; | 49 return (typeWidthInBytes(Ty) + 3) & ~3; |
50 } | 50 } |
51 SizeT getBundleAlignLog2Bytes() const override { return 5; } | 51 SizeT getBundleAlignLog2Bytes() const override { return 5; } |
52 llvm::ArrayRef<uint8_t> getNonExecBundlePadding() const override { | 52 llvm::ArrayRef<AsmCodeByte> getNonExecBundlePadding() const override { |
53 static const uint8_t Padding[] = { 0xF4 }; | 53 static const AsmCodeByte Padding[] = { 0xF4 }; |
54 return llvm::ArrayRef<uint8_t>(Padding, 1); | 54 return llvm::ArrayRef<AsmCodeByte>(Padding, 1); |
55 } | 55 } |
56 void emitVariable(const Variable *Var) const override; | 56 void emitVariable(const Variable *Var) const override; |
57 void lowerArguments() override; | 57 void lowerArguments() override; |
58 void addProlog(CfgNode *Node) override; | 58 void addProlog(CfgNode *Node) override; |
59 void addEpilog(CfgNode *Node) override; | 59 void addEpilog(CfgNode *Node) override; |
60 void emitConstants() const override; | 60 void emitConstants() const override; |
61 SizeT makeNextLabelNumber() { return NextLabelNumber++; } | 61 SizeT makeNextLabelNumber() { return NextLabelNumber++; } |
62 // Ensure that a 64-bit Variable has been split into 2 32-bit | 62 // Ensure that a 64-bit Variable has been split into 2 32-bit |
63 // Variables, creating them if necessary. This is needed for all | 63 // Variables, creating them if necessary. This is needed for all |
64 // I64 operations, and it is needed for pushing F64 arguments for | 64 // I64 operations, and it is needed for pushing F64 arguments for |
(...skipping 436 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
501 }; | 501 }; |
502 | 502 |
503 template <> void ConstantInteger32::emit(GlobalContext *Ctx) const; | 503 template <> void ConstantInteger32::emit(GlobalContext *Ctx) const; |
504 template <> void ConstantInteger64::emit(GlobalContext *Ctx) const; | 504 template <> void ConstantInteger64::emit(GlobalContext *Ctx) const; |
505 template <> void ConstantFloat::emit(GlobalContext *Ctx) const; | 505 template <> void ConstantFloat::emit(GlobalContext *Ctx) const; |
506 template <> void ConstantDouble::emit(GlobalContext *Ctx) const; | 506 template <> void ConstantDouble::emit(GlobalContext *Ctx) const; |
507 | 507 |
508 } // end of namespace Ice | 508 } // end of namespace Ice |
509 | 509 |
510 #endif // SUBZERO_SRC_ICETARGETLOWERINGX8632_H | 510 #endif // SUBZERO_SRC_ICETARGETLOWERINGX8632_H |
OLD | NEW |