From 25140ca60e424bd385b96f932fdd97ca3bf8760a Mon Sep 17 00:00:00 2001 From: Michael Beck Date: Thu, 14 Jun 2007 11:25:44 +0000 Subject: [PATCH] __fastcall error [r14488] --- ir/be/test/fehler19.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 ir/be/test/fehler19.c diff --git a/ir/be/test/fehler19.c b/ir/be/test/fehler19.c new file mode 100644 index 000000000..b671fe696 --- /dev/null +++ b/ir/be/test/fehler19.c @@ -0,0 +1,26 @@ +/* + * compiler with -f no-inline + */ +#include + +#ifdef __GNUC__ +#define NO_INLINE __attribute__((noinline)) +#else +#define NO_INLINE __declspec(noinline) +#endif + +static NO_INLINE void func(float a, float b, float *c, float *d); + +static void func(float a, float b, float *c, float *d) { + *c = a; + *d = b; +} + +int main(int argc, char *argv[]) { + float a, b; + + func(3.0f, 4.0f, &a, &b); + + printf("a = %f (should be 3.0)\n", a); + printf("b = %f (should be 4.0)\n", b); +} -- 2.20.1