diff options
author | Matt Arsenault <Matthew.Arsenault@amd.com> | 2013-07-27 19:22:28 +0000 |
---|---|---|
committer | Matt Arsenault <Matthew.Arsenault@amd.com> | 2013-07-27 19:22:28 +0000 |
commit | fe655dc15598ebd4c8077e4a67914e7f233e0774 (patch) | |
tree | d31eb1f5c91e53cf4a7085b08dfe3fa2383ca66e | |
parent | 1faea8f0869a173c5952b59fd17718cf42111416 (diff) | |
download | external_llvm-fe655dc15598ebd4c8077e4a67914e7f233e0774.zip external_llvm-fe655dc15598ebd4c8077e4a67914e7f233e0774.tar.gz external_llvm-fe655dc15598ebd4c8077e4a67914e7f233e0774.tar.bz2 |
Minor code simplification suggested by Duncan
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@187309 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | lib/IR/DataLayout.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/IR/DataLayout.cpp b/lib/IR/DataLayout.cpp index d1096d7..d786d33 100644 --- a/lib/IR/DataLayout.cpp +++ b/lib/IR/DataLayout.cpp @@ -514,8 +514,7 @@ unsigned DataLayout::getPointerTypeSizeInBits(Type *Ty) const { if (Ty->isPointerTy()) return getTypeSizeInBits(Ty); - Type *EleTy = cast<VectorType>(Ty)->getElementType(); - return getTypeSizeInBits(EleTy); + return getTypeSizeInBits(Ty->getScalarType()); } /*! |