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]

Re: scheduling patch


>> On Tue, Jul 24, 2001 at 01:07:14PM -0700, amacleod@cygnus.com wrote:
>> > 	* params.def (PARAM_MAX_PENDING_LIST_LENGTH): Add parameter to 
>> > 	limit length of dependancy flush list.
>> > 	* params.h (MAX_PENDING_LIST_LENGTH): Define.
>> > 	* sched-int.h  (struct deps): Add pending_flush_length field.
>> > 	* sched-deps.c (flush_pending_lists): Last_pending_memory_flush now
>> > 	has 1 element in it.
>> > 	(sched_analyze): After a jump, if the pending memory flush list is too
>> > 	large, flush the pending lists.
>> > 	(init_deps): Initialize pending_flush_length to 0.
>> > 	* doc/invoke.texi (max_pending_list_length): Document parameter.
>> 
>> Ok.
>> 
>> As a followup patch, would you patch the other existing list
>> length checks to use this parameter as well?
>> 

I only see one other with a quick glance. I can add this to the patch...
And should I apply this to the 3.0 branch too?

Andrew

	* sched-deps.c (sched_analyze_1): Use MAX_PENDING_LIST_LENGTH.

Index: sched-deps.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/sched-deps.c,v
retrieving revision 1.9.4.2
diff -c -p -r1.9.4.2 sched-deps.c
*** sched-deps.c	2001/05/20 20:05:25	1.9.4.2
--- sched-deps.c	2001/07/25 19:19:30
*************** sched_analyze_1 (deps, x, insn)
*** 671,684 ****
      {
        /* Writing memory.  */
  
!       if (deps->pending_lists_length > 32)
  	{
  	  /* Flush all pending reads and writes to prevent the pending lists
  	     from getting any larger.  Insn scheduling runs too slowly when
! 	     these lists get long.  The number 32 was chosen because it
! 	     seems like a reasonable number.  When compiling GCC with itself,
  	     this flush occurs 8 times for sparc, and 10 times for m88k using
! 	     the number 32.  */
  	  flush_pending_lists (deps, insn, 0);
  	}
        else
--- 673,685 ----
      {
        /* Writing memory.  */
  
!       if (deps->pending_lists_length > MAX_PENDING_LIST_LENGTH)
  	{
  	  /* Flush all pending reads and writes to prevent the pending lists
  	     from getting any larger.  Insn scheduling runs too slowly when
! 	     these lists get long.  When compiling GCC with itself,
  	     this flush occurs 8 times for sparc, and 10 times for m88k using
! 	     the default value of 32.  */
  	  flush_pending_lists (deps, insn, 0);
  	}
        else


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