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]

Tiny compilation time improvement



 > Before applying this patch, please check if it is REALLY correct. I'm new
 > in the study of gcc, so...

This is WRONG for the case of jump.c, because the else gets attached to the
wrong if. Braces are needed (and indeed this is picked up by the
current default set of warning options).

Ian

 > *** ../egcs-19991214/gcc/jump.c Mon Dec 20 15:09:18 1999
 > --- ./jump.c    Mon Dec 20 16:09:04 1999
 > *************** invert_exp (x, insn)
 > *** 4646,4652 ****
 >         if (fmt[i] == 'e')
 >         if (! invert_exp (XEXP (x, i), insn))
 >           return 0;
 > !       if (fmt[i] == 'E')
 >         {
 >           register int j;
 >           for (j = 0; j < XVECLEN (x, i); j++)
 > --- 4646,4652 ----
 >         if (fmt[i] == 'e')
 >         if (! invert_exp (XEXP (x, i), insn))
 >           return 0;
 > !       else if (fmt[i] == 'E')
 >         {
 >           register int j;
 >           for (j = 0; j < XVECLEN (x, i); j++)
 > *************** redirect_exp (loc, olabel, nlabel, insn)
 > *** 4795,4801 ****
 >         if (fmt[i] == 'e')
 >         if (! redirect_exp (&XEXP (x, i), olabel, nlabel, insn))
 >           return 0;
 > !       if (fmt[i] == 'E')
 >         {
 >           register int j;
 >           for (j = 0; j < XVECLEN (x, i); j++)
 > --- 4795,4801 ----
 >         if (fmt[i] == 'e')
 >         if (! redirect_exp (&XEXP (x, i), olabel, nlabel, insn))
 >           return 0;
 > !       else if (fmt[i] == 'E')
 >         {
 >           register int j;
 >           for (j = 0; j < XVECLEN (x, i); j++)


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