xref: /llvm-project/clang/test/CodeGen/2007-04-14-FNoBuiltin.c (revision 7dbc9cf8760e07f28cea29e337ff3666624dc91d)
1 // RUN: %clang_cc1 -emit-llvm %s -O2 -fno-builtin -o - | FileCheck %s
2 // RUN: %clang_cc1 -emit-llvm %s -O2 -fno-builtin-printf -o - | FileCheck %s
3 // Check that -fno-builtin is honored.
4 
5 extern int printf(const char*, ...);
6 
7 // CHECK: define {{.*}}void {{.*}}foo(
foo(const char * msg)8 void foo(const char *msg) {
9   // CHECK: call {{.*}}printf
10   printf("%s\n",msg);
11 }
12