This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: egcs-971031, sparc-sun-solaris2.5 new bootstrap failure
- To: "Kaveh R. Ghazi" <ghazi at caip dot rutgers dot edu>
- Subject: Re: egcs-971031, sparc-sun-solaris2.5 new bootstrap failure
- From: Jim Wilson <wilson at cygnus dot com>
- Date: Fri, 07 Nov 1997 14:52:28 -0800
- cc: egcs at cygnus dot com
Here is a patch to fix this. This will be in the next snapshot.
Thu Nov 6 18:27:36 1997 Jim Wilson <wilson@cygnus.com>
* flags.h (flag_rerun_loop_opt): Declare.
* loop.c (invariant_p, case LABEL_REF): Check flag_rerun_loop_opt.
* toplev.c (flag_rerum_loop_opt): Delete static.
diff -pr clean-egcs-971105/gcc/flags.h egcs-971105/gcc/flags.h
*** clean-egcs-971105/gcc/flags.h Wed Aug 27 20:35:15 1997
--- egcs-971105/gcc/flags.h Thu Nov 6 17:57:46 1997
*************** extern int flag_volatile_global;
*** 275,280 ****
--- 275,284 ----
extern int flag_fast_math;
+ /* Nonzero means to run loop optimizations twice. */
+
+ extern int flag_rerun_loop_opt;
+
/* Nonzero means make functions that look like good inline candidates
go inline. */
diff -pr clean-egcs-971105/gcc/loop.c egcs-971105/gcc/loop.c
*** clean-egcs-971105/gcc/loop.c Sun Oct 26 08:20:07 1997
--- egcs-971105/gcc/loop.c Thu Nov 6 17:54:00 1997
*************** invariant_p (x)
*** 2833,2839 ****
We don't know the loop bounds here though, so just fail for all
labels. */
! if (flag_unroll_loops)
return 0;
else
return 1;
--- 2833,2844 ----
We don't know the loop bounds here though, so just fail for all
labels. */
! /* ??? This is also necessary if flag_rerun_loop_opt is true, because in
! this case we may be doing loop unrolling the second time we run loop,
! and hence the first loop run also needs this check. There is no way
! to check here whether the second run will actually do loop unrolling
! though, as that info is in a local var in rest_of_compilation. */
! if (flag_unroll_loops || flag_rerun_loop_opt)
return 0;
else
return 1;
diff -pr clean-egcs-971105/gcc/toplev.c egcs-971105/gcc/toplev.c
*** clean-egcs-971105/gcc/toplev.c Sun Oct 26 08:56:15 1997
--- egcs-971105/gcc/toplev.c Thu Nov 6 17:56:26 1997
*************** static int flag_rerun_cse_after_loop;
*** 507,513 ****
/* Nonzero means to run loop optimizations twice. */
! static int flag_rerun_loop_opt;
/* Nonzero for -finline-functions: ok to inline functions that look like
good inline candidates. */
--- 507,513 ----
/* Nonzero means to run loop optimizations twice. */
! int flag_rerun_loop_opt;
/* Nonzero for -finline-functions: ok to inline functions that look like
good inline candidates. */