OSDN Git Service

Handle GIMPLE_COND in diagnose_sb_2.
authorhjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 28 Dec 2009 16:41:33 +0000 (16:41 +0000)
committerhjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 28 Dec 2009 16:41:33 +0000 (16:41 +0000)
gcc/

2009-12-28  H.J. Lu  <hongjiu.lu@intel.com>

PR middle-end/41344
* omp-low.c (diagnose_sb_2): Handle GIMPLE_COND.

gcc/testsuite/

2009-12-28  H.J. Lu  <hongjiu.lu@intel.com>

* gfortran.dg/gomp/pr41344.f: New.

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

gcc/ChangeLog
gcc/omp-low.c
gcc/testsuite/ChangeLog
gcc/testsuite/gfortran.dg/gomp/pr41344.f [new file with mode: 0644]

index e0a5ae3..022296f 100644 (file)
@@ -1,3 +1,8 @@
+2009-12-28  H.J. Lu  <hongjiu.lu@intel.com>
+
+       PR middle-end/41344
+       * omp-low.c (diagnose_sb_2): Handle GIMPLE_COND.
+
 2009-12-24  Andy Hutchinson  <hutchinsonandy@gcc.gnu.org>
 
        PR target/42457
        the start of a loop over basic blocks.
 
 2009-12-24  Julian Brown  <julian@codesourcery.com>
-            Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
+           Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
 
-        PR target/40887
-        * config/arm/arm.c (output_call_mem): Remove armv5 support.
-        * config/arm/arm.md (*call_mem): Disable for armv5. Add note.
-        (*call_value_mem): Likewise.
+       PR target/40887
+       * config/arm/arm.c (output_call_mem): Remove armv5 support.
+       * config/arm/arm.md (*call_mem): Disable for armv5. Add note.
+       (*call_value_mem): Likewise.
 
 2009-12-23  Jakub Jelinek  <jakub@redhat.com>
 
 
 2009-12-23  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
 
-        PR target/42093
-        * config/arm/arm.h (CASE_VECTOR_PC_RELATIVE): Fix macro usage
-        to TARGET_THUMB1.
-        (CASE_VECTOR_SHORTEN_MODE): Allow signed offsets
-        only for TARGET_THUMB1.
+       PR target/42093
+       * config/arm/arm.h (CASE_VECTOR_PC_RELATIVE): Fix macro usage
+       to TARGET_THUMB1.
+       (CASE_VECTOR_SHORTEN_MODE): Allow signed offsets
+       only for TARGET_THUMB1.
 
 2009-12-23  Ramana Radhakrishnan  <ramrad01@arm.com>
 
index 02fea10..3170031 100644 (file)
@@ -6858,6 +6858,27 @@ diagnose_sb_2 (gimple_stmt_iterator *gsi_p, bool *handled_ops_p,
       wi->info = context;
       break;
 
+    case GIMPLE_COND:
+       {
+         tree lab = gimple_cond_true_label (stmt);
+         if (lab)
+           {
+             n = splay_tree_lookup (all_labels,
+                                    (splay_tree_key) lab);
+             diagnose_sb_0 (gsi_p, context,
+                            n ? (gimple) n->value : NULL);
+           }
+         lab = gimple_cond_false_label (stmt);
+         if (lab)
+           {
+             n = splay_tree_lookup (all_labels,
+                                    (splay_tree_key) lab);
+             diagnose_sb_0 (gsi_p, context,
+                            n ? (gimple) n->value : NULL);
+           }
+       }
+      break;
+
     case GIMPLE_GOTO:
       {
        tree lab = gimple_goto_dest (stmt);
index 349aa46..d1b3841 100644 (file)
@@ -1,3 +1,7 @@
+2009-12-28  H.J. Lu  <hongjiu.lu@intel.com>
+
+       * gfortran.dg/gomp/pr41344.f: New.
+
 2009-12-27  Martin Jambor  <mjambor@suse.cz>
 
        PR tree-optimization/42231
@@ -18,9 +22,9 @@
        * g++.dg/lookup/koenig12.C: New test.
 
 2009-12-24  Julian Brown  <julian@codesourcery.com>
-            Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
+           Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
 
-        PR target/40887
+       PR target/40887
        * gcc.target/arm/pr40887.c: New test.
 
 2009-12-23  Jakub Jelinek  <jakub@redhat.com>
@@ -36,8 +40,8 @@
 
 2009-12-23  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
 
-        PR target/42093
-        * gcc.target/arm/pr42093.c: New test.
+       PR target/42093
+       * gcc.target/arm/pr42093.c: New test.
 
 2009-12-23  Ramana Radhakrishnan  <ramrad01@arm.com>
 
diff --git a/gcc/testsuite/gfortran.dg/gomp/pr41344.f b/gcc/testsuite/gfortran.dg/gomp/pr41344.f
new file mode 100644 (file)
index 0000000..66ae8b3
--- /dev/null
@@ -0,0 +1,16 @@
+      subroutine xrotate(nerr)
+
+      common /dfm/ndfl
+
+*$omp parallel private(ix)
+      ix = 0
+*$omp do
+      do i=1,ndfl
+         ix = ix + 1
+        if (ix.gt.5) go to 9000 ! { dg-error "invalid (exit|branch)" }
+      enddo
+*$omp end do
+*$omp end parallel
+
+9000  continue
+      end