public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME
@ 2004-07-28 20:53 falk at debian dot org
  2004-07-28 20:53 ` [Bug tree-optimization/16808] " falk at debian dot org
                   ` (10 more replies)
  0 siblings, 11 replies; 12+ messages in thread
From: falk at debian dot org @ 2004-07-28 20:53 UTC (permalink / raw)
  To: gcc-bugs

This is a test case from PR 11372, but most likely it's a different problem
this time.

% gcc -c -O2 pr11372.c   
pr11372.c: In function `evalTerm':
pr11372.c:25: error: Missing definition
for SSA_NAME: TMT.14<D1176>_26

in statement:
#   TMT.14<D1176>_28 = V_MAY_DEF <TMT.14<D1176>_26>;
#   TMT.15<D1177>_29 = V_MAY_DEF <TMT.15<D1177>_27>;
f (T.6<D1160>_12);

pr11372.c:25: error: Missing definition
for SSA_NAME: TMT.15<D1177>_27

in statement:
#   TMT.14<D1176>_28 = V_MAY_DEF <TMT.14<D1176>_26>;
#   TMT.15<D1177>_29 = V_MAY_DEF <TMT.15<D1177>_27>;
f (T.6<D1160>_12);

pr11372.c:25: internal compiler error: verify_ssa failed.
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.

-- 
           Summary: verify_ssa failed: Missing definition for SSA_NAME
           Product: gcc
           Version: 3.5.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P2
         Component: tree-optimization
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: falk at debian dot org
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: alphaev68-unknown-linux-gnu
  GCC host triplet: alphaev68-unknown-linux-gnu
GCC target triplet: alphaev68-unknown-linux-gnu


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16808


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug tree-optimization/16808] verify_ssa failed: Missing definition for SSA_NAME
  2004-07-28 20:53 [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME falk at debian dot org
@ 2004-07-28 20:53 ` falk at debian dot org
  2004-07-28 21:02 ` [Bug tree-optimization/16808] [3.5 Regression] " pinskia at gcc dot gnu dot org
                   ` (9 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: falk at debian dot org @ 2004-07-28 20:53 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From falk at debian dot org  2004-07-28 20:53 -------
Created an attachment (id=6848)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=6848&action=view)
Test case


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16808


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug tree-optimization/16808] [3.5 Regression] verify_ssa failed: Missing definition for SSA_NAME
  2004-07-28 20:53 [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME falk at debian dot org
  2004-07-28 20:53 ` [Bug tree-optimization/16808] " falk at debian dot org
@ 2004-07-28 21:02 ` pinskia at gcc dot gnu dot org
  2004-07-28 21:09 ` pinskia at gcc dot gnu dot org
                   ` (8 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-07-28 21:02 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-07-28 21:02 -------
: Search converges between 2004-05-11-trunk (#454) and 2004-05-14-trunk (#455).

: Test is the same (pass) at both endpoints (2003-05-30-ssa,
: 2004-01-26-ssa), so there's nothing for me to do.

Confirmed.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|                            |1
   Last reconfirmed|0000-00-00 00:00:00         |2004-07-28 21:02:52
               date|                            |
            Summary|verify_ssa failed: Missing  |[3.5 Regression] verify_ssa
                   |definition for SSA_NAME     |failed: Missing definition
                   |                            |for SSA_NAME
   Target Milestone|---                         |3.5.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16808


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug tree-optimization/16808] [3.5 Regression] verify_ssa failed: Missing definition for SSA_NAME
  2004-07-28 20:53 [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME falk at debian dot org
  2004-07-28 20:53 ` [Bug tree-optimization/16808] " falk at debian dot org
  2004-07-28 21:02 ` [Bug tree-optimization/16808] [3.5 Regression] " pinskia at gcc dot gnu dot org
@ 2004-07-28 21:09 ` pinskia at gcc dot gnu dot org
  2004-08-02 15:08 ` zhangjie at magima dot com dot cn
                   ` (7 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-07-28 21:09 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-07-28 21:09 -------
The problem comes from folding exp(0.0) to 1.0 in fab.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |rth at gcc dot gnu dot org
           Severity|normal                      |critical
  GCC build triplet|alphaev68-unknown-linux-gnu |
   GCC host triplet|alphaev68-unknown-linux-gnu |
 GCC target triplet|alphaev68-unknown-linux-gnu |
   Last reconfirmed|2004-07-28 21:02:52         |2004-07-28 21:09:24
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16808


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug tree-optimization/16808] [3.5 Regression] verify_ssa failed: Missing definition for SSA_NAME
  2004-07-28 20:53 [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME falk at debian dot org
                   ` (2 preceding siblings ...)
  2004-07-28 21:09 ` pinskia at gcc dot gnu dot org
@ 2004-08-02 15:08 ` zhangjie at magima dot com dot cn
  2004-08-02 15:29 ` falk at debian dot org
                   ` (6 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: zhangjie at magima dot com dot cn @ 2004-08-02 15:08 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From zhangjie at magima dot com dot cn  2004-08-02 15:07 -------
How about this patch? Are there other variables that need be renamed?


2004-08-02  Jie Zhang  <zhangjie@magima.com.cn>

	* tree-ssa-ccp.c (execute_fold_all_builtins): Rename the affected vars
	in V_MAY_DEFS after folding builtins.
	(struct tree_opt_pass pass_fold_builtins): Add TODO_rename_vars in
	todo_flags_finish.


Index: tree-ssa-ccp.c
===================================================================
RCS file: /cvsroot/gcc/gcc/gcc/tree-ssa-ccp.c,v
retrieving revision 2.29
diff -u -p -r2.29 tree-ssa-ccp.c
--- tree-ssa-ccp.c	30 Jul 2004 22:55:25 -0000	2.29
+++ tree-ssa-ccp.c	2 Aug 2004 14:55:50 -0000
@@ -2653,11 +2653,11 @@ execute_fold_all_builtins (void)
   basic_block bb;
   FOR_EACH_BB (bb)
     {
-      block_stmt_iterator i;
-      for (i = bsi_start (bb); !bsi_end_p (i); bsi_next (&i))
+      block_stmt_iterator bsi;
+      for (bsi = bsi_start (bb); !bsi_end_p (bsi); bsi_next (&bsi))
 	{
-	  tree *stmtp = bsi_stmt_ptr (i);
-	  tree call = get_rhs (*stmtp);
+	  tree stmt = bsi_stmt (bsi);
+	  tree call = get_rhs (stmt);
 	  tree callee, result;
 
 	  if (!call || TREE_CODE (call) != CALL_EXPR)
@@ -2666,7 +2666,7 @@ execute_fold_all_builtins (void)
 	  if (!callee || DECL_BUILT_IN_CLASS (callee) != BUILT_IN_NORMAL)
 	    continue;
 
-	  result = ccp_fold_builtin (*stmtp, call);
+	  result = ccp_fold_builtin (stmt, call);
 	  if (!result)
 	    switch (DECL_FUNCTION_CODE (callee))
 	      {
@@ -2684,16 +2684,31 @@ execute_fold_all_builtins (void)
 	  if (dump_file && (dump_flags & TDF_DETAILS))
 	    {
 	      fprintf (dump_file, "Simplified\n  ");
-	      print_generic_stmt (dump_file, *stmtp, dump_flags);
+	      print_generic_stmt (dump_file, stmt, dump_flags);
 	    }
 
-	  if (set_rhs (stmtp, result))
-	    modify_stmt (*stmtp);
+	  if (set_rhs (&stmt, result))
+	    {
+	      size_t i;
+	      stmt_ann_t ann;
+	      v_may_def_optype v_may_defs;
+
+	      ann = stmt_ann (stmt);
+	      v_may_defs = V_MAY_DEF_OPS (ann);
+	      for (i = 0; i < NUM_V_MAY_DEFS (v_may_defs); i++)
+		{
+		  tree op = V_MAY_DEF_RESULT (v_may_defs, i);
+		  tree var = SSA_NAME_VAR (op);
+		  bitmap_set_bit (vars_to_rename, var_ann (var)->uid);
+		}
+
+	      modify_stmt (stmt);
+	    }
 
 	  if (dump_file && (dump_flags & TDF_DETAILS))
 	    {
 	      fprintf (dump_file, "to\n  ");
-	      print_generic_stmt (dump_file, *stmtp, dump_flags);
+	      print_generic_stmt (dump_file, stmt, dump_flags);
 	      fprintf (dump_file, "\n");
 	    }
 	}
@@ -2714,6 +2729,7 @@ struct tree_opt_pass pass_fold_builtins 
   0,					/* properties_destroyed */
   0,					/* todo_flags_start */
   TODO_dump_func | TODO_verify_ssa	/* todo_flags_finish */
+    | TODO_rename_vars
 };
 
 


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16808


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug tree-optimization/16808] [3.5 Regression] verify_ssa failed: Missing definition for SSA_NAME
  2004-07-28 20:53 [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME falk at debian dot org
                   ` (3 preceding siblings ...)
  2004-08-02 15:08 ` zhangjie at magima dot com dot cn
@ 2004-08-02 15:29 ` falk at debian dot org
  2004-08-03  1:06 ` pinskia at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: falk at debian dot org @ 2004-08-02 15:29 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From falk at debian dot org  2004-08-02 15:28 -------
Could you please submit this patch to gcc-patches, including the test case
for gcc.c-torture/compile?

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16808


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug tree-optimization/16808] [3.5 Regression] verify_ssa failed: Missing definition for SSA_NAME
  2004-07-28 20:53 [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME falk at debian dot org
                   ` (4 preceding siblings ...)
  2004-08-02 15:29 ` falk at debian dot org
@ 2004-08-03  1:06 ` pinskia at gcc dot gnu dot org
  2004-08-03 15:00 ` zhangjie at magima dot com dot cn
                   ` (4 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-08-03  1:06 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-08-03 01:06 -------
Patch here: <http://gcc.gnu.org/ml/gcc-patches/2004-08/msg00098.html>.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |patch


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16808


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug tree-optimization/16808] [3.5 Regression] verify_ssa failed: Missing definition for SSA_NAME
  2004-07-28 20:53 [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME falk at debian dot org
                   ` (5 preceding siblings ...)
  2004-08-03  1:06 ` pinskia at gcc dot gnu dot org
@ 2004-08-03 15:00 ` zhangjie at magima dot com dot cn
  2004-11-01 19:31 ` [Bug tree-optimization/16808] [4.0 " pinskia at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: zhangjie at magima dot com dot cn @ 2004-08-03 15:00 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From zhangjie at magima dot com dot cn  2004-08-03 15:00 -------
My first patch was bad. Here is a new patch:
<http://gcc.gnu.org/ml/gcc-patches/2004-08/msg00148.html>.

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16808


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug tree-optimization/16808] [4.0 Regression] verify_ssa failed: Missing definition for SSA_NAME
  2004-07-28 20:53 [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME falk at debian dot org
                   ` (6 preceding siblings ...)
  2004-08-03 15:00 ` zhangjie at magima dot com dot cn
@ 2004-11-01 19:31 ` pinskia at gcc dot gnu dot org
  2004-11-02  4:38 ` pinskia at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  10 siblings, 0 replies; 12+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-11-01 19:31 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-11-01 19:31 -------
I have a newer simpler patch.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |pinskia at gcc dot gnu dot
                   |dot org                     |org
             Status|NEW                         |ASSIGNED
           Keywords|patch                       |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16808


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug tree-optimization/16808] [4.0 Regression] verify_ssa failed: Missing definition for SSA_NAME
  2004-07-28 20:53 [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME falk at debian dot org
                   ` (7 preceding siblings ...)
  2004-11-01 19:31 ` [Bug tree-optimization/16808] [4.0 " pinskia at gcc dot gnu dot org
@ 2004-11-02  4:38 ` pinskia at gcc dot gnu dot org
  2004-11-02 16:38 ` pinskia at gcc dot gnu dot org
  2004-11-02 16:38 ` cvs-commit at gcc dot gnu dot org
  10 siblings, 0 replies; 12+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-11-02  4:38 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-11-02 04:38 -------
New patch here: <http://gcc.gnu.org/ml/gcc-patches/2004-11/msg00107.html>.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |patch


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16808


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug tree-optimization/16808] [4.0 Regression] verify_ssa failed: Missing definition for SSA_NAME
  2004-07-28 20:53 [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME falk at debian dot org
                   ` (9 preceding siblings ...)
  2004-11-02 16:38 ` pinskia at gcc dot gnu dot org
@ 2004-11-02 16:38 ` cvs-commit at gcc dot gnu dot org
  10 siblings, 0 replies; 12+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2004-11-02 16:38 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From cvs-commit at gcc dot gnu dot org  2004-11-02 16:38 -------
Subject: Bug 16808

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	pinskia@gcc.gnu.org	2004-11-02 16:38:18

Modified files:
	gcc            : ChangeLog tree-ssa.c 
	gcc/testsuite  : ChangeLog 
Added files:
	gcc/testsuite/gcc.c-torture/compile: pr16808.c 

Log message:
	2004-11-02  Andrew Pinski  <pinskia@physics.uc.edu>
	
	PR tree-opt/16808
	* gcc.c-torture/compile/pr16808.c: New test.
	
	2004-11-02  Andrew Pinski  <pinskia@physics.uc.edu>
	
	PR tree-opt/16808
	* tree-ssa.c (replace_immediate_uses): If we call fold_stmt, make sure
	that the vops get marked for renaming.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.6137&r2=2.6138
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/tree-ssa.c.diff?cvsroot=gcc&r1=2.53&r2=2.54
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.4534&r2=1.4535
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gcc.c-torture/compile/pr16808.c.diff?cvsroot=gcc&r1=NONE&r2=1.1



-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16808


^ permalink raw reply	[flat|nested] 12+ messages in thread

* [Bug tree-optimization/16808] [4.0 Regression] verify_ssa failed: Missing definition for SSA_NAME
  2004-07-28 20:53 [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME falk at debian dot org
                   ` (8 preceding siblings ...)
  2004-11-02  4:38 ` pinskia at gcc dot gnu dot org
@ 2004-11-02 16:38 ` pinskia at gcc dot gnu dot org
  2004-11-02 16:38 ` cvs-commit at gcc dot gnu dot org
  10 siblings, 0 replies; 12+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2004-11-02 16:38 UTC (permalink / raw)
  To: gcc-bugs


------- Additional Comments From pinskia at gcc dot gnu dot org  2004-11-02 16:38 -------
Fixed.

-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16808


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2004-11-02 16:38 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-07-28 20:53 [Bug tree-optimization/16808] New: verify_ssa failed: Missing definition for SSA_NAME falk at debian dot org
2004-07-28 20:53 ` [Bug tree-optimization/16808] " falk at debian dot org
2004-07-28 21:02 ` [Bug tree-optimization/16808] [3.5 Regression] " pinskia at gcc dot gnu dot org
2004-07-28 21:09 ` pinskia at gcc dot gnu dot org
2004-08-02 15:08 ` zhangjie at magima dot com dot cn
2004-08-02 15:29 ` falk at debian dot org
2004-08-03  1:06 ` pinskia at gcc dot gnu dot org
2004-08-03 15:00 ` zhangjie at magima dot com dot cn
2004-11-01 19:31 ` [Bug tree-optimization/16808] [4.0 " pinskia at gcc dot gnu dot org
2004-11-02  4:38 ` pinskia at gcc dot gnu dot org
2004-11-02 16:38 ` pinskia at gcc dot gnu dot org
2004-11-02 16:38 ` cvs-commit at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).