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: CALL_INSN_FUNCTION_USAGE problem


In article <10005091120.AA17529@vlsi1.ultra.nyu.edu> you write:
>*************** reload_combine ()
>*** 8390,8402 ****
>    /* To avoid wasting too much time later searching for an index register,
>       determine the minimum and maximum index register numbers.  */
>!   for (i = FIRST_PSEUDO_REGISTER - 1; i >= 0; --i)
>!     {
>!       if (TEST_HARD_REG_BIT (reg_class_contents[INDEX_REG_CLASS], i))
>! 	{
>! 	  if (! last_index_reg)
>! 	    last_index_reg = i;
>! 	  first_index_reg = i;
>! 	}
>!     }
>    /* If no index register is available, we can quit now.  */
>    if (first_index_reg > last_index_reg)
>--- 8391,8402 ----
>    /* To avoid wasting too much time later searching for an index register,
>       determine the minimum and maximum index register numbers.  */
>!   for (r = 0; r < FIRST_PSEUDO_REGISTER; r++)
>!     if (TEST_HARD_REG_BIT (reg_class_contents[INDEX_REG_CLASS], r))
>!       {
>! 	if (! last_index_reg)
>! 	  last_index_reg = r;
>! 	first_index_reg = i;
>!       }
>! 
>    /* If no index register is available, we can quit now.  */
>    if (first_index_reg > last_index_reg)

This is obviously wrong.  There are two things wrong with it.

Why are you trying to "fix" code that isn't broken?  It is a waste of time
to try to rewrite all code that wasn't written exactly the way that you would
have written it.  You are just adding bugs to gcc, and making it harder for
people to submit patches.

Jim

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