diff options
author | Chris Lattner <sabre@nondot.org> | 2001-12-14 16:38:04 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2001-12-14 16:38:04 +0000 |
commit | 38ac81cbbc147f3d2551d472b099d8de6767f7fd (patch) | |
tree | 071ab5d8cfe45597b3791d4f91e5518d721b8df9 /lib/Transforms/Utils/LowerAllocations.cpp | |
parent | d55438085090886a1c7ddc37159b1cfb406fbce4 (diff) |
Remove unsized array support
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@1466 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Transforms/Utils/LowerAllocations.cpp')
-rw-r--r-- | lib/Transforms/Utils/LowerAllocations.cpp | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/lib/Transforms/Utils/LowerAllocations.cpp b/lib/Transforms/Utils/LowerAllocations.cpp index bb2cdb67fa..666b6d976e 100644 --- a/lib/Transforms/Utils/LowerAllocations.cpp +++ b/lib/Transforms/Utils/LowerAllocations.cpp @@ -70,12 +70,6 @@ bool LowerAllocations::doPerMethodWork(Method *M) { const Type *AllocTy =cast<PointerType>(MI->getType())->getElementType(); - // If the user is allocating an unsized array with a dynamic size arg, - // start by getting the size of one element. - // - if (const ArrayType *ATy = dyn_cast<ArrayType>(AllocTy)) - if (ATy->isUnsized()) AllocTy = ATy->getElementType(); - // Get the number of bytes to be allocated for one element of the // requested type... unsigned Size = DataLayout.getTypeSize(AllocTy); |