OSDN Git Service

2007-05-01 Richard Guenther <rguenther@suse.de>
authorrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 1 May 2007 14:54:30 +0000 (14:54 +0000)
committerrguenth <rguenth@138bc75d-0d04-0410-961f-82ee72b054a4>
Tue, 1 May 2007 14:54:30 +0000 (14:54 +0000)
* tree-ssa-loop-manip.c (ip_normal_pos): Check if last stmt
  is NULL.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@124329 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/tree-ssa-loop-manip.c

index 015c4a1..617a0da 100644 (file)
@@ -1,3 +1,8 @@
+2007-05-01  Richard Guenther  <rguenther@suse.de>
+
+       * tree-ssa-loop-manip.c (ip_normal_pos): Check if last stmt
+       is NULL.
+
 2007-05-01  Joseph Myers  <joseph@codesourcery.com>
 
        * config/rs6000/libgcc-ppc-glibc.ver (__gcc_qgt): Fix typo.
index 7611a6f..3416df3 100644 (file)
@@ -505,7 +505,8 @@ ip_normal_pos (struct loop *loop)
 
   bb = single_pred (loop->latch);
   last = last_stmt (bb);
-  if (TREE_CODE (last) != COND_EXPR)
+  if (!last
+      || TREE_CODE (last) != COND_EXPR)
     return NULL;
 
   exit = EDGE_SUCC (bb, 0);