icc doesn't like -fomit-frame-pointer without -O
[libfirm] / ir / be / test / fehler019.c
1 /*
2  * compiler with -f no-inline
3  */
4 #include <stdio.h>
5
6 #ifdef __GNUC__
7 #define NO_INLINE __attribute__((noinline))
8 #else
9 #define NO_INLINE __declspec(noinline)
10 #endif
11
12 static NO_INLINE void func(float a, float b, float *c, float *d);
13
14 static void func(float a, float b, float *c, float *d) {
15   *c = a;
16   *d = b;
17 }
18
19 int main(int argc, char *argv[]) {
20   float a, b;
21
22   func(3.0f, 4.0f, &a, &b);
23
24   printf("a = %f (should be 3.0)\n", a);
25   printf("b = %f (should be 4.0)\n", b);
26
27   return 0;
28 }