This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

fix 20000731-1.c on powerpc (and hopefully mips)


The underlying problem is that we tried to compute (const_int 0) *
(const_int 1) in DFmode.  Since neither is a valid DFmode rtx, the
computation goes haywire, and eventually trips a newly-added abort in
trunc_int_for_mode.

I'm inclined to write this off as yet another case of loop brokenness.
The code involved is ancient.

Tested on powerpc-eabisim.

-- 
Geoff Keating <geoffk@redhat.com>

===File ~/patches/gcc-fptotal.patch=========================
2002-08-20  Geoffrey Keating  <geoffk@redhat.com>

	* unroll.c (biv_total_increment): Don't try to compute the total
	increment for FP BIVs.

Index: unroll.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/unroll.c,v
retrieving revision 1.174
diff -p -u -p -r1.174 unroll.c
--- unroll.c	2 Aug 2002 00:50:01 -0000	1.174
+++ unroll.c	21 Aug 2002 04:04:51 -0000
@@ -2419,7 +2419,8 @@ biv_total_increment (bl)
   for (v = bl->biv; v; v = v->next_iv)
     {
       if (v->always_computable && v->mult_val == const1_rtx
-	  && ! v->maybe_multiple)
+	  && ! v->maybe_multiple
+	  && SCALAR_INT_MODE_P (v->mode))
 	result = fold_rtx_mult_add (result, const1_rtx, v->add_val, v->mode);
       else
 	return 0;
============================================================


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]