re PR target/9506 (ABI breakage: structure return)

PR c/9506
	* i386.c (override_options): Use DEFAULT_PCC_STRUCT_RETURN.
	* gcc.dg/struct-ret-libc.c: New test.

From-SVN: r62204
This commit is contained in:
Loren J. Rittle 2003-01-31 21:59:38 +00:00
parent 072b0db2e3
commit 7c712dcc2b
3 changed files with 26 additions and 1 deletions

View File

@ -1,3 +1,12 @@
2003-01-31 Jan Hubicka <jh@suse.cz>
PR c/9506
* i386.c (override_options): Use DEFAULT_PCC_STRUCT_RETURN.
2003-01-31 Loren J. Rittle <ljrittle@acm.org>
* gcc.dg/struct-ret-libc.c: New test.
2003-01-31 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
* pa32-regs.h (REGNO_REG_CLASS, REG_CLASS_FROM_LETTER): Delete

View File

@ -1118,7 +1118,7 @@ override_options ()
if (flag_asynchronous_unwind_tables == 2)
flag_asynchronous_unwind_tables = 0;
if (flag_pcc_struct_return == 2)
flag_pcc_struct_return = 1;
flag_pcc_struct_return = DEFAULT_PCC_STRUCT_RETURN;
}
#ifdef SUBTARGET_OVERRIDE_OPTIONS

View File

@ -0,0 +1,16 @@
/* Test evolved from source from Simona Perri <perri@mat.unical.it>
and Gerald Pfeifer<pfeifer@dbai.tuwien.ac.at>.
Copyright (C) 2003 Free Software Foundation */
/* { dg-do run } */
#include <stdlib.h>
int main ()
{
div_t d = div (20, 5);
if ((d.quot != 4) || (d.rem))
abort ();
exit (0);
}