Commit b2f24c85 by Eric Botcazou

sparc.c (function_arg_record_value_1): Fix computation of the number of integer registers required.

	* config/sparc/sparc.c (function_arg_record_value_1): Fix
	computation of the number of integer registers required.

From-SVN: r76339
parent b4e0dd8e
2004-01-22 Olivier Hainque <hainque@act-europe.fr>
* config/sparc/sparc.c (function_arg_record_value_1): Fix
computation of the number of integer registers required.
2004-01-21 Kazu Hirata <kazu@cs.umass.edu>
* config/i386/i386.md: Simplify certain comparisons of
......
......@@ -5039,10 +5039,13 @@ function_arg_record_value_1 (tree type, HOST_WIDE_INT startbitpos,
{
if (parms->intoffset != -1)
{
unsigned int startbit, endbit;
int intslots, this_slotno;
intslots = (bitpos - parms->intoffset + BITS_PER_WORD - 1)
/ BITS_PER_WORD;
startbit = parms->intoffset & -BITS_PER_WORD;
endbit = (bitpos + BITS_PER_WORD - 1) & -BITS_PER_WORD;
intslots = (endbit - startbit) / BITS_PER_WORD;
this_slotno = parms->slotno + parms->intoffset
/ BITS_PER_WORD;
......
2004-01-22 Eric Botcazou <ebotcazou@libertysurf.fr>
* gcc.dg/struct-by-value-2.c: New test.
2004-01-21 Andrew Pinski <apinski@apple.com>
PR target/13785
......
/* This testcase caused a sanity check to abort on SPARC64
because of a discrepancy between two functions involved
in the calculation of structure layout. */
/* { dg-do compile } */
struct S { float f1; int i1; int i2; float f2; };
extern void foo(struct S);
void bar(void)
{
struct S s;
foo(s);
}
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