diff --git a/test/C++Frontend/2007-04-14-FNoBuiltin.cpp b/test/C++Frontend/2007-04-14-FNoBuiltin.cpp new file mode 100644 index 00000000000..c52b30bd394 --- /dev/null +++ b/test/C++Frontend/2007-04-14-FNoBuiltin.cpp @@ -0,0 +1,7 @@ +// RUN: %llvmgcc -S %s -O2 -fno-builtin -o - | llvm-as -f | llc | grep -v puts +// Check that -fno-builtin is honored. + +extern "C" int printf(const char*, ...); +void foo(const char *msg) { + printf("%s\n",msg); +} diff --git a/test/CFrontend/2007-04-14-FNoBuiltin.c b/test/CFrontend/2007-04-14-FNoBuiltin.c new file mode 100644 index 00000000000..454396b22a7 --- /dev/null +++ b/test/CFrontend/2007-04-14-FNoBuiltin.c @@ -0,0 +1,7 @@ +// RUN: %llvmgcc -S %s -O2 -fno-builtin -o - | llvm-as -f | llc | grep -v puts +// Check that -fno-builtin is honored. + +extern int printf(const char*, ...); +void foo(const char *msg) { + printf("%s\n",msg); +}