* gcc.dg/990424-1.c: New test.

From-SVN: r26622
This commit is contained in:
Richard Henderson 1999-04-25 05:29:35 -07:00 committed by Richard Henderson
parent 10195bd88e
commit ed856f4c70
2 changed files with 30 additions and 0 deletions

View File

@ -1,3 +1,7 @@
Sun Apr 25 12:28:59 1999 Richard Henderson <rth@cygnus.com>
* gcc.dg/990424-1.c: New test.
1999-04-24 Craig Burley <craig@jcb-sc.com> 1999-04-24 Craig Burley <craig@jcb-sc.com>
* g77.f-torture/execute/u77-test.f (main): Bug involving * g77.f-torture/execute/u77-test.f (main): Bug involving

View File

@ -0,0 +1,26 @@
/* Test that stack alignment is preserved with pending_stack_adjust
with stdcall functions. */
/* { dg-do run { target i?86-*-* } } */
/* { dg-options -mpreferred-stack-boundary=4 } */
void __attribute__((stdcall)) foo(int a, int b, int c);
int
main ()
{
foo(1, 2, 3);
foo(1, 2, 3);
exit (0);
}
void __attribute__((stdcall))
foo(int a, int b, int c)
{
static int last_align = -1;
int dummy, align = (int)&dummy & 15;
if (last_align < 0)
last_align = align;
else if (align != last_align)
abort ();
}