blob: 36a140a8e50b43b6aff11a64671166fedeb0f743 [file] [log] [blame]
Eric Christopher3883e662011-07-26 22:17:02 +00001// RUN: %clang_cc1 %s -emit-llvm -o - | grep llvm.memset | count 3
2
Eric Christopherb056db92011-07-26 23:18:10 +00003#ifndef memset
Eric Christopher3883e662011-07-26 22:17:02 +00004void *memset(void*, int, unsigned long);
Eric Christopherb056db92011-07-26 23:18:10 +00005#endif
6#ifndef bzero
Eric Christopher3883e662011-07-26 22:17:02 +00007void bzero(void*, unsigned long);
Eric Christopherb056db92011-07-26 23:18:10 +00008#endif
Eric Christopher3883e662011-07-26 22:17:02 +00009
10void test(int* X, char *Y) {
11 // CHECK: call i8* llvm.memset
12 memset(X, 4, 1000);
13 // CHECK: call void bzero
14 bzero(Y, 100);
15}