diff options
author | Eli Bendersky <eliben@google.com> | 2013-04-16 15:41:18 +0000 |
---|---|---|
committer | Eli Bendersky <eliben@google.com> | 2013-04-16 15:41:18 +0000 |
commit | 6b51f75cc58b5a431cfb9e808f27f1fc4432913e (patch) | |
tree | 7276103b672de836cb3c3ad3fd8278599ad4c97f /lib/IR | |
parent | a363b117f41700da0200753e6df62b5e2cb38378 (diff) | |
download | external_llvm-6b51f75cc58b5a431cfb9e808f27f1fc4432913e.zip external_llvm-6b51f75cc58b5a431cfb9e808f27f1fc4432913e.tar.gz external_llvm-6b51f75cc58b5a431cfb9e808f27f1fc4432913e.tar.bz2 |
Cleanup naming: DataLayout s/TD/DL/
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@179601 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/IR')
-rw-r--r-- | lib/IR/DataLayout.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/IR/DataLayout.cpp b/lib/IR/DataLayout.cpp index ecd5216..5658f561 100644 --- a/lib/IR/DataLayout.cpp +++ b/lib/IR/DataLayout.cpp @@ -41,7 +41,7 @@ char DataLayout::ID = 0; // Support for StructLayout //===----------------------------------------------------------------------===// -StructLayout::StructLayout(StructType *ST, const DataLayout &TD) { +StructLayout::StructLayout(StructType *ST, const DataLayout &DL) { assert(!ST->isOpaque() && "Cannot get layout of opaque structs"); StructAlignment = 0; StructSize = 0; @@ -50,7 +50,7 @@ StructLayout::StructLayout(StructType *ST, const DataLayout &TD) { // Loop over each of the elements, placing them in memory. for (unsigned i = 0, e = NumElements; i != e; ++i) { Type *Ty = ST->getElementType(i); - unsigned TyAlign = ST->isPacked() ? 1 : TD.getABITypeAlignment(Ty); + unsigned TyAlign = ST->isPacked() ? 1 : DL.getABITypeAlignment(Ty); // Add padding if necessary to align the data element properly. if ((StructSize & (TyAlign-1)) != 0) @@ -60,7 +60,7 @@ StructLayout::StructLayout(StructType *ST, const DataLayout &TD) { StructAlignment = std::max(TyAlign, StructAlignment); MemberOffsets[i] = StructSize; - StructSize += TD.getTypeAllocSize(Ty); // Consume space for this data item + StructSize += DL.getTypeAllocSize(Ty); // Consume space for this data item } // Empty structures have alignment of 1 byte. |