diff options
author | Chris Lattner <sabre@nondot.org> | 2004-02-13 22:04:41 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2004-02-13 22:04:41 +0000 |
commit | 6f3ff3e34d7087e3cb084ba4675386002a807ccd (patch) | |
tree | ba903667063f8e8a5fe2922671fdb52ccf75005a /test | |
parent | 0021c31b60706f0a35f0858c112ebdc709f3d3e7 (diff) |
New testcase. The CFE should not generate illegal LLVM intrinsics, even if
the input program is horribly broken (like 126.gcc).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11401 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r-- | test/CFrontend/2004-02-13-IllegalVararg.c.tr | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/test/CFrontend/2004-02-13-IllegalVararg.c.tr b/test/CFrontend/2004-02-13-IllegalVararg.c.tr new file mode 100644 index 0000000000..1f3eded0cd --- /dev/null +++ b/test/CFrontend/2004-02-13-IllegalVararg.c.tr @@ -0,0 +1,11 @@ +// RUN: %llvmgcc -xc %s -c -o - | llc + +#include <stdarg.h> + +float test(int X, ...) { + va_list ap; + float F; + va_start(ap, X); + F = va_arg(ap, float); + return F; +} |