Commit 48ee6fa0 by Eric Botcazou Committed by Eric Botcazou

builtin-apply2.c: Set size of stack argument data to 64.

	* gcc.dg/builtin-apply2.c: Set size of stack argument data to 64.
	* gcc.dg/builtin-apply3.c: New test.

From-SVN: r74022
parent 21f1c577
2003-11-28 Eric Botcazou <ebotcazou@libertysurf.fr>
* gcc.dg/builtin-apply2.c: Set size of stack argument data to 64.
* gcc.dg/builtin-apply3.c: New test.
2003-11-27 Eric Botcazou <ebotcazou@libertysurf.fr>
* lib/compat.exp (compat-obj): New xfaildata parameter.
......
......@@ -9,8 +9,6 @@
#define INTEGER_ARG 5
typedef __SIZE_TYPE__ size_t;
extern void abort(void);
void foo(char *name, double d, double e, double f, int g)
......@@ -21,14 +19,7 @@ void foo(char *name, double d, double e, double f, int g)
void bar(char *name, ...)
{
size_t size;
void *arguments;
size = sizeof(char *) + 3 * sizeof(double) + sizeof(int);
arguments = __builtin_apply_args();
__builtin_apply(foo, arguments, size);
__builtin_apply(foo, __builtin_apply_args(), 64);
}
int main(void)
......
/* PR middle-end/12210 */
/* Origin: Ossadchy Yury A. <waspcoder@mail.ru> */
/* This used to fail on i686 because the argument was not copied
to the right location by __builtin_apply after the direct call. */
/* { dg-do run } */
#define INTEGER_ARG 5
extern void abort(void);
void foo(int arg)
{
if (arg != INTEGER_ARG)
abort();
}
void bar(int arg)
{
foo(arg);
__builtin_apply(foo, __builtin_apply_args(), 16);
}
int main(void)
{
bar(INTEGER_ARG);
return 0;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment