From 1c44c4db2170f9cea4a06d317e0684bfc4097b84 Mon Sep 17 00:00:00 2001 From: Dale Johannesen Date: Sun, 15 Apr 2007 00:18:31 +0000 Subject: [PATCH] testcases for -fno-builtin git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36038 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/C++Frontend/2007-04-14-FNoBuiltin.cpp | 7 +++++++ test/CFrontend/2007-04-14-FNoBuiltin.c | 7 +++++++ 2 files changed, 14 insertions(+) create mode 100644 test/C++Frontend/2007-04-14-FNoBuiltin.cpp create mode 100644 test/CFrontend/2007-04-14-FNoBuiltin.c 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); +} -- 2.34.1