Functions marked malloc are noalias return.
authorDuncan Sands <baldrick@free.fr>
Sun, 1 Mar 2009 16:19:31 +0000 (16:19 +0000)
committerDuncan Sands <baldrick@free.fr>
Sun, 1 Mar 2009 16:19:31 +0000 (16:19 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@65775 91177308-0d34-0410-b5e6-96231b3b80d8

test/FrontendC/2009-03-01-MallocNoAlias.c [new file with mode: 0644]

diff --git a/test/FrontendC/2009-03-01-MallocNoAlias.c b/test/FrontendC/2009-03-01-MallocNoAlias.c
new file mode 100644 (file)
index 0000000..22ff6cb
--- /dev/null
@@ -0,0 +1,3 @@
+// RUN: %llvmgcc %s -S -o - | grep noalias
+
+void * __attribute__ ((malloc)) foo (void) { return 0; }