2006-06-19 Daniel Berlin <dberlin@dberlin.org>
authordberlin <dberlin@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 19 Jun 2006 14:33:46 +0000 (14:33 +0000)
committerdberlin <dberlin@138bc75d-0d04-0410-961f-82ee72b054a4>
Mon, 19 Jun 2006 14:33:46 +0000 (14:33 +0000)
Fix PR tree-optimization/27341
* tree-cfg.c (gimplify_val): Call mark_new_vars_to_rename on the
statement we get.
* tree-complex.c (pass_lower_complex): Update SMT usage.

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

gcc/ChangeLog
gcc/testsuite/gcc.c-torture/compile/pr27341-1.c [new file with mode: 0644]
gcc/testsuite/gcc.c-torture/compile/pr27341-2.c [new file with mode: 0644]
gcc/tree-cfg.c
gcc/tree-complex.c

index 2c7c65a..34b7da6 100644 (file)
@@ -1,3 +1,10 @@
+2006-06-19  Daniel Berlin  <dberlin@dberlin.org>
+
+       Fix PR tree-optimization/27341
+       * tree-cfg.c (gimplify_val): Call mark_new_vars_to_rename on the
+       statement we get.
+       * tree-complex.c (pass_lower_complex): Update SMT usage.        
+
 2006-06-19  Andreas Krebbel  <krebbel1@de.ibm.com>
 
        * config/s390/s390.md ("doloop_si64", "doloop_si31", "doloop_di"): 
diff --git a/gcc/testsuite/gcc.c-torture/compile/pr27341-1.c b/gcc/testsuite/gcc.c-torture/compile/pr27341-1.c
new file mode 100644 (file)
index 0000000..b77e937
--- /dev/null
@@ -0,0 +1,7 @@
+extern double R_NaReal;
+void z_atan2 (double _Complex * r, double _Complex * ccs)
+{
+    if (*ccs == 0)
+        __imag__ *r = R_NaReal;
+}
+
diff --git a/gcc/testsuite/gcc.c-torture/compile/pr27341-2.c b/gcc/testsuite/gcc.c-torture/compile/pr27341-2.c
new file mode 100644 (file)
index 0000000..e6be1e4
--- /dev/null
@@ -0,0 +1,8 @@
+void zgemm_ (const int*, const double*);
+extern void matmul_c8 (_Complex double * dest)
+{
+  const int  ldc = 0;
+  const double zero = 0;
+  zgemm_ ( &zero, &ldc);
+  dest[1] += 1 ;
+}
index a3fed03..6dbb7d3 100644 (file)
@@ -5584,6 +5584,8 @@ gimplify_val (block_stmt_iterator *bsi, tree type, tree exp)
   TREE_BLOCK (new_stmt) = TREE_BLOCK (orig_stmt);
 
   bsi_insert_before (bsi, new_stmt, BSI_SAME_STMT);
+  if (in_ssa_p)
+    mark_new_vars_to_rename (new_stmt);
 
   return t;
 }
index 0a5040e..f841844 100644 (file)
@@ -1541,11 +1541,12 @@ struct tree_opt_pass pass_lower_complex =
   0,                                   /* tv_id */
   PROP_ssa,                            /* properties_required */
   0,                                   /* properties_provided */
-  0,                                   /* properties_destroyed */
+  PROP_smt_usage,                       /* properties_destroyed */
   0,                                   /* todo_flags_start */
   TODO_dump_func | TODO_ggc_collect
-    | TODO_update_ssa
-    | TODO_verify_stmts,               /* todo_flags_finish */
+  | TODO_update_smt_usage
+  | TODO_update_ssa
+  | TODO_verify_stmts,                 /* todo_flags_finish */
   0                                    /* letter */
 };