Dead
[official-gcc.git] / gomp-20050608-branch / gcc / testsuite / gcc.dg / builtin-protos-1.c
blobc3cdc533feda63675e946076784d82f5a910e3d6
1 /* { dg-do compile } */
2 /* { dg-options -Wconversion } */
4 int
5 test_s (signed int x)
7 return __builtin_abs (x) /* { dg-bogus "as unsigned due to prototype" } */
8 + __builtin_clz (x) /* { dg-warning "as unsigned due to prototype" } */
9 + __builtin_ctz (x) /* { dg-warning "as unsigned due to prototype" } */
10 + __builtin_ffs (x) /* { dg-bogus "as unsigned due to prototype" } */
11 + __builtin_parity (x) /* { dg-warning "as unsigned due to prototype" } */
12 + __builtin_popcount (x); /* { dg-warning "as unsigned due to prototype" } */
15 int
16 test_u (unsigned int x)
18 return __builtin_abs (x) /* { dg-warning "as signed due to prototype" } */
19 + __builtin_clz (x) /* { dg-bogus "as signed due to prototype" } */
20 + __builtin_ctz (x) /* { dg-bogus "as signed due to prototype" } */
21 + __builtin_ffs (x) /* { dg-warning "as signed due to prototype" } */
22 + __builtin_parity (x) /* { dg-bogus "as signed due to prototype" } */
23 + __builtin_popcount (x); /* { dg-bogus "as signed due to prototype" } */
26 int
27 test_sl (signed long x)
29 return __builtin_labs (x) /* { dg-bogus "as unsigned due to prototype" } */
30 + __builtin_clzl (x) /* { dg-warning "as unsigned due to prototype" } */
31 + __builtin_ctzl (x) /* { dg-warning "as unsigned due to prototype" } */
32 + __builtin_ffsl (x) /* { dg-bogus "as unsigned due to prototype" } */
33 + __builtin_parityl (x) /* { dg-warning "as unsigned due to prototype" } */
34 + __builtin_popcountl (x); /* { dg-warning "as unsigned due to prototype" } */
37 int
38 test_ul (unsigned long x)
40 return __builtin_labs (x) /* { dg-warning "as signed due to prototype" } */
41 + __builtin_clzl (x) /* { dg-bogus "as signed due to prototype" } */
42 + __builtin_ctzl (x) /* { dg-bogus "as signed due to prototype" } */
43 + __builtin_ffsl (x) /* { dg-warning "as signed due to prototype" } */
44 + __builtin_parityl (x) /* { dg-bogus "as signed due to prototype" } */
45 + __builtin_popcountl (x); /* { dg-bogus "as signed due to prototype" } */
48 int
49 test_sll (signed long long x)
51 return __builtin_llabs (x) /* { dg-bogus "as unsigned due to prototype" } */
52 + __builtin_clzll (x) /* { dg-warning "as unsigned due to prototype" } */
53 + __builtin_ctzll (x) /* { dg-warning "as unsigned due to prototype" } */
54 + __builtin_ffsll (x) /* { dg-bogus "as unsigned due to prototype" } */
55 + __builtin_parityll (x) /* { dg-warning "as unsigned due to prototype" } */
56 + __builtin_popcountll (x); /* { dg-warning "as unsigned due to prototype" } */
59 int
60 test_ull (unsigned long long x)
62 return __builtin_llabs (x) /* { dg-warning "as signed due to prototype" } */
63 + __builtin_clzll (x) /* { dg-bogus "as signed due to prototype" } */
64 + __builtin_ctzll (x) /* { dg-bogus "as signed due to prototype" } */
65 + __builtin_ffsll (x) /* { dg-warning "as signed due to prototype" } */
66 + __builtin_parityll (x) /* { dg-bogus "as signed due to prototype" } */
67 + __builtin_popcountll (x); /* { dg-bogus "as signed due to prototype" } */