]> gcc.gnu.org Git - gcc.git/commitdiff
* tree-tailcall.c (find_tail_calls): Ignore GIMPLE_NOPs.
authorJakub Jelinek <jakub@redhat.com>
Fri, 4 Dec 2015 16:40:05 +0000 (17:40 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Fri, 4 Dec 2015 16:40:05 +0000 (17:40 +0100)
From-SVN: r231282

gcc/ChangeLog
gcc/tree-tailcall.c

index b6ff6e162f5ba3aad7357a57db8ebe36d91fde76..d9a0bf8956962da09b1711e171128a0aca9646bb 100644 (file)
@@ -1,5 +1,7 @@
 2015-12-04  Jakub Jelinek  <jakub@redhat.com>
 
+       * tree-tailcall.c (find_tail_calls): Ignore GIMPLE_NOPs.
+
        PR tree-optimization/68680
        * calls.c (special_function_p): Return ECF_MAY_BE_ALLOCA for
        BUILT_IN_ALLOCA{,_WITH_ALIGN}.  Don't check for __builtin_alloca
index bbd1b29ae48d423a49353ddbe591977bf6fadbc2..a2585fbc53340012c949f129a6613cb112580f1f 100644 (file)
@@ -412,9 +412,10 @@ find_tail_calls (basic_block bb, struct tailcall **ret)
     {
       stmt = gsi_stmt (gsi);
 
-      /* Ignore labels, returns, clobbers and debug stmts.  */
+      /* Ignore labels, returns, nops, clobbers and debug stmts.  */
       if (gimple_code (stmt) == GIMPLE_LABEL
          || gimple_code (stmt) == GIMPLE_RETURN
+         || gimple_code (stmt) == GIMPLE_NOP
          || gimple_clobber_p (stmt)
          || is_gimple_debug (stmt))
        continue;
@@ -532,7 +533,8 @@ find_tail_calls (basic_block bb, struct tailcall **ret)
 
       stmt = gsi_stmt (agsi);
 
-      if (gimple_code (stmt) == GIMPLE_LABEL)
+      if (gimple_code (stmt) == GIMPLE_LABEL
+         || gimple_code (stmt) == GIMPLE_NOP)
        continue;
 
       if (gimple_code (stmt) == GIMPLE_RETURN)
This page took 0.100342 seconds and 5 git commands to generate.