diff options
| author | Micah Villmow <villmow@gmail.com> | 2012-10-08 16:25:52 +0000 |
|---|---|---|
| committer | Micah Villmow <villmow@gmail.com> | 2012-10-08 16:25:52 +0000 |
| commit | 25a6a84cf5067b32c271e3ba078676dee838798d (patch) | |
| tree | 31a8d7b32cbc5d57322ecf8ca19951029fdb4172 /lib/CodeGen/CGExpr.cpp | |
| parent | d3420c906e3605d94c084e8b8b1f3fa490093c86 (diff) | |
Move TargetData to DataLayout.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@165395 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGExpr.cpp')
| -rw-r--r-- | lib/CodeGen/CGExpr.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/CodeGen/CGExpr.cpp b/lib/CodeGen/CGExpr.cpp index 9e172615f4..fac6e37002 100644 --- a/lib/CodeGen/CGExpr.cpp +++ b/lib/CodeGen/CGExpr.cpp @@ -26,7 +26,7 @@ #include "llvm/Intrinsics.h" #include "llvm/LLVMContext.h" #include "llvm/MDBuilder.h" -#include "llvm/Target/TargetData.h" +#include "llvm/DataLayout.h" using namespace clang; using namespace CodeGen; @@ -1160,7 +1160,7 @@ RValue CodeGenFunction::EmitLoadOfBitfieldLValue(LValue LV) { // Get the output type. llvm::Type *ResLTy = ConvertType(LV.getType()); - unsigned ResSizeInBits = CGM.getTargetData().getTypeSizeInBits(ResLTy); + unsigned ResSizeInBits = CGM.getDataLayout().getTypeSizeInBits(ResLTy); // Compute the result as an OR of all of the individual component accesses. llvm::Value *Res = 0; @@ -1358,7 +1358,7 @@ void CodeGenFunction::EmitStoreThroughBitfieldLValue(RValue Src, LValue Dst, // Get the output type. llvm::Type *ResLTy = ConvertTypeForMem(Dst.getType()); - unsigned ResSizeInBits = CGM.getTargetData().getTypeSizeInBits(ResLTy); + unsigned ResSizeInBits = CGM.getDataLayout().getTypeSizeInBits(ResLTy); // Get the source value, truncated to the width of the bit-field. llvm::Value *SrcVal = Src.getScalarVal(); |
