reload.c (find_reloads): Exit loop once we find this operand cannot be reloaded someh...
authorPo-Chun Chang <pchang9@cs.wisc.edu>
Tue, 23 Jul 2013 15:56:37 +0000 (15:56 +0000)
committerJeff Law <law@gcc.gnu.org>
Tue, 23 Jul 2013 15:56:37 +0000 (09:56 -0600)
2013-07-22  Po-Chun Chang  <pchang9@cs.wisc.edu>

* reload.c (find_reloads): Exit loop once we find this operand
cannot be reloaded somehow for this alternative.

* reload.c (find_reloads): Exit loop once we find a hard register.

* rtlanal.c (computed_jump_p): Exit loop once we find label
reference is used.

* i386.c (ix86_pad_returns): Exit loop after setting replace.

* cfgloopmanip.c (remove_path): Exit loop after setting
irred_invalidated.

* gensupport.c (subst_dup): Avoid loop if code is not
MATCH_DUP nor MATCH_OP_DUP.

From-SVN: r201174

gcc/ChangeLog
gcc/cfgloopmanip.c
gcc/config/i386/i386.c
gcc/gensupport.c
gcc/reload.c
gcc/rtlanal.c

index b2851dd358a92bea96c2f46d210f977dd67947e8..95a86e47b1f614a05e69010a7fe87d1ebeb4b3b5 100644 (file)
@@ -1,3 +1,21 @@
+2013-07-22  Po-Chun Chang  <pchang9@cs.wisc.edu>
+
+       * reload.c (find_reloads): Exit loop once we find this operand
+       cannot be reloaded somehow for this alternative.
+
+       * reload.c (find_reloads): Exit loop once we find a hard register.
+
+       * rtlanal.c (computed_jump_p): Exit loop once we find label
+       reference is used.
+
+       * i386.c (ix86_pad_returns): Exit loop after setting replace.
+
+       * cfgloopmanip.c (remove_path): Exit loop after setting
+       irred_invalidated.
+
+       * gensupport.c (subst_dup): Avoid loop if code is not
+       MATCH_DUP nor MATCH_OP_DUP.
+
 2013-07-23  Nicklas Bo Jensen  <nbjensen@gmail.com>
 
        * doc/md.texi (Machine-Specific Peephole Optimizers): Fix a typo.
        -march=r5900 -mhard-float -mdouble-float.  Use spu_single_format
        for -march=r5900 -mhard-float.
 
-2013-07-22  Chang  <pchang9@cs.wisc.edu>
+2013-07-22  Po-Chun Chang  <pchang9@cs.wisc.edu>
 
        * df-problems.c (can_move_insns_across): Exit loop once we
        find a non-fixed, non-global register.
 
        * tree-pass.h (pass_ipa_lto_wpa_fixup): Remove redundant decl.
 
-2013-07-18  Chang  <pchang9@cs.wisc.edu>
+2013-07-18  Po-Chun Chang  <pchang9@cs.wisc.edu>
 
        * read-rtl.c (validate_const_int): Once an invalid character is
        seen, quit the loop.
index bc877559052ea5f91e019828c0c1e912e4ca026e..f35e5aedc7902c6591f67ac1248029347c351324 100644 (file)
@@ -343,7 +343,11 @@ remove_path (edge e)
     FOR_EACH_EDGE (ae, ei, e->src->succs)
       if (ae != e && ae->dest != EXIT_BLOCK_PTR && !bitmap_bit_p (seen, ae->dest->index)
          && ae->flags & EDGE_IRREDUCIBLE_LOOP)
-       irred_invalidated = true;
+       {
+         irred_invalidated = true;
+         break;
+       }
+
   for (i = 0; i < nrem; i++)
     {
       bb = rem_bbs[i];
index 140c56913599881800a1b5e787cde3a9b3973b09..0c546af00b2f99e5362a8d982da41342ab85afcf 100644 (file)
@@ -35725,7 +35725,10 @@ ix86_pad_returns (void)
          FOR_EACH_EDGE (e, ei, bb->preds)
            if (EDGE_FREQUENCY (e) && e->src->index >= 0
                && !(e->flags & EDGE_FALLTHRU))
-             replace = true;
+             {
+               replace = true;
+               break;
+             }
        }
       if (!replace)
        {
index 19b92408dc4bcc6d86ace6006b6f52dc6e24c17f..c7a27c42617b96f4fd6c68a3393317dea34cfc37 100644 (file)
@@ -2178,8 +2178,8 @@ subst_dup (rtx pattern, int n_alt, int n_subst_alt)
          if (XVEC (pattern, i) == NULL)
            break;
        case 'E':
-         for (j = XVECLEN (pattern, i) - 1; j >= 0; --j)
-           if (code != MATCH_DUP && code != MATCH_OP_DUP)
+         if (code != MATCH_DUP && code != MATCH_OP_DUP)
+           for (j = XVECLEN (pattern, i) - 1; j >= 0; --j)
              XVECEXP (pattern, i, j) = subst_dup (XVECEXP (pattern, i, j),
                                                   n_alt, n_subst_alt);
          break;
index 8733ff33467cb1188231debb900e64d5d0de8eca..b15f3b20eb7d4ad87f6285b1df1f89b973c213eb 100644 (file)
@@ -3324,7 +3324,10 @@ find_reloads (rtx insn, int replace, int ind_levels, int live_known,
                      for (j = 0; j < i; j++)
                        if (this_alternative_matches[j]
                            == this_alternative_matches[i])
-                         badop = 1;
+                         {
+                           badop = 1;
+                           break;
+                         }
                    break;
 
                  case 'p':
@@ -4640,7 +4643,10 @@ find_reloads (rtx insn, int replace, int ind_levels, int live_known,
 
            for (nri = 1; nri < nr; nri ++)
              if (! TEST_HARD_REG_BIT (reg_class_contents[rld[i].rclass], regno + nri))
-               ok = 0;
+               {
+                 ok = 0;
+                 break;
+               }
 
            if (ok)
              rld[i].reg_rtx = dest;
index 9567694bc1581c16d9cb47b8ddef654ee193b891..95a314f0f3fdefe1ac4170d00ff72c183fe9ede2 100644 (file)
@@ -2802,7 +2802,10 @@ computed_jump_p (const_rtx insn)
            if (GET_CODE (XVECEXP (pat, 0, i)) == USE
                && (GET_CODE (XEXP (XVECEXP (pat, 0, i), 0))
                    == LABEL_REF))
-             has_use_labelref = 1;
+             {
+               has_use_labelref = 1;
+               break;
+             }
 
          if (! has_use_labelref)
            for (i = len - 1; i >= 0; i--)