Commit 380f6ad3 by Jakub Jelinek Committed by Jakub Jelinek

sparc.c (sparc_emit_set_const64): Don't abort when op0 is a SUBREG.

	* config/sparc/sparc.c (sparc_emit_set_const64): Don't abort when
	op0 is a SUBREG.
	(function_arg_slotno): Accept TImode/CTImode.
	* config/sparc/sparc.h (MIN_UNITS_PER_WORD): If IN_LIBGCC2 define
	to UNITS_PER_WORD.

        * gcc.c-torture/compile/20000923-1.c: New test.

From-SVN: r36645
parent ef120fc0
2000-09-26 Jakub Jelinek <jakub@redhat.com>
* config/sparc/sparc.c (sparc_emit_set_const64): Don't abort when
op0 is a SUBREG.
(function_arg_slotno): Accept TImode/CTImode.
* config/sparc/sparc.h (MIN_UNITS_PER_WORD): If IN_LIBGCC2 define
to UNITS_PER_WORD.
2000-09-26 Michael Hayes <mhayes@cygnus.com> 2000-09-26 Michael Hayes <mhayes@cygnus.com>
* flow.c (flow_loop_pre_header_scan): Punt if loop enters * flow.c (flow_loop_pre_header_scan): Punt if loop enters
......
...@@ -1832,12 +1832,17 @@ sparc_emit_set_const64 (op0, op1) ...@@ -1832,12 +1832,17 @@ sparc_emit_set_const64 (op0, op1)
rtx temp; rtx temp;
/* Sanity check that we know what we are working with. */ /* Sanity check that we know what we are working with. */
if (! TARGET_ARCH64 if (! TARGET_ARCH64)
|| GET_CODE (op0) != REG
|| (REGNO (op0) >= SPARC_FIRST_FP_REG
&& REGNO (op0) <= SPARC_LAST_V9_FP_REG))
abort (); abort ();
if (GET_CODE (op0) != SUBREG)
{
if (GET_CODE (op0) != REG
|| (REGNO (op0) >= SPARC_FIRST_FP_REG
&& REGNO (op0) <= SPARC_LAST_V9_FP_REG))
abort ();
}
if (reload_in_progress || reload_completed) if (reload_in_progress || reload_completed)
temp = op0; temp = op0;
else else
...@@ -3971,6 +3976,7 @@ function_arg_slotno (cum, mode, type, named, incoming_p, pregno, ppadding) ...@@ -3971,6 +3976,7 @@ function_arg_slotno (cum, mode, type, named, incoming_p, pregno, ppadding)
case HImode : case CHImode : case HImode : case CHImode :
case SImode : case CSImode : case SImode : case CSImode :
case DImode : case CDImode : case DImode : case CDImode :
case TImode : case CTImode :
if (slotno >= SPARC_INT_ARG_MAX) if (slotno >= SPARC_INT_ARG_MAX)
return -1; return -1;
regno = regbase + slotno; regno = regbase + slotno;
......
...@@ -765,7 +765,11 @@ extern struct sparc_cpu_select sparc_select[]; ...@@ -765,7 +765,11 @@ extern struct sparc_cpu_select sparc_select[];
/* Width of a word, in units (bytes). */ /* Width of a word, in units (bytes). */
#define UNITS_PER_WORD (TARGET_ARCH64 ? 8 : 4) #define UNITS_PER_WORD (TARGET_ARCH64 ? 8 : 4)
#ifdef IN_LIBGCC2
#define MIN_UNITS_PER_WORD UNITS_PER_WORD
#else
#define MIN_UNITS_PER_WORD 4 #define MIN_UNITS_PER_WORD 4
#endif
/* Now define the sizes of the C data types. */ /* Now define the sizes of the C data types. */
......
2000-09-26 Jakub Jelinek <jakub@redhat.com>
* gcc.c-torture/compile/20000923-1.c: New test.
2000-09-25 Theodore Papadopoulo <Theodore.Papadopoulo@sophia.inria.fr> 2000-09-25 Theodore Papadopoulo <Theodore.Papadopoulo@sophia.inria.fr>
* g++.old-deja/g++.other/crash20.C: Make ready for libstdc++-v3. * g++.old-deja/g++.other/crash20.C: Make ready for libstdc++-v3.
......
const int a = 3;
const int b = 50;
void foo (void)
{
long int x[a][b];
asm ("" : : "r" (x) : "memory");
}
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