From: Chris Lattner Date: Mon, 4 Nov 2002 16:18:07 +0000 (+0000) Subject: New testcase for malloc promotion X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=0eaaa56f1f5a87446c7c45b530f0ab0bbe365f59;p=oota-llvm.git New testcase for malloc promotion git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4533 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/test/Transforms/InstCombine/malloc.ll b/test/Transforms/InstCombine/malloc.ll new file mode 100644 index 00000000000..3545f3073de --- /dev/null +++ b/test/Transforms/InstCombine/malloc.ll @@ -0,0 +1,7 @@ +; test that malloc's with a constant argument are promoted to array allocations +; RUN: as < %s | opt -instcombine -die | dis | grep getelementptr + +int* %test() { + %X = malloc int, uint 4 + ret int* %X +}