public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/32224]  New: [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374
@ 2007-06-05 17:11 tbm at cyrius dot com
  2007-06-06 21:03 ` [Bug tree-optimization/32224] " pinskia at gcc dot gnu dot org
                   ` (5 more replies)
  0 siblings, 6 replies; 7+ messages in thread
From: tbm at cyrius dot com @ 2007-06-05 17:11 UTC (permalink / raw)
  To: gcc-bugs

I'm seeing the following ICE with current trunk.  This was introduced at
some point between 20070131 (works) and 20070303 (ICE).  This is on x86_64.

(sid)25015:tbm@em64t: ~] /usr/lib/gcc-snapshot/bin/gcc -c -O -ftree-vectorize
gmp-export.c
gmp-export.c: In function 'gmpz_export':
gmp-export.c:4: internal compiler error: in vect_analyze_operations, at
tree-vect-analyze.c:374
Please submit a full bug report,

Testcase:


typedef unsigned long int *mp_ptr;
typedef const unsigned long int *mp_srcptr;
gmpz_export (void *data)
{
  mp_srcptr zp;
  int count, i;
  mp_ptr __dst = ((mp_ptr) data);
  mp_srcptr __src = (zp);

  for (i = 0; i < count; i++)
  {
    __asm__ ("bswap %q0": "=r" (*__dst):"0" (*(__src)));
    __src++;
  }
}


-- 
           Summary: [4.3 Regression] ICE in vect_analyze_operations, at
                    tree-vect-analyze.c:374
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: tbm at cyrius dot com


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


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

* [Bug tree-optimization/32224] [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374
  2007-06-05 17:11 [Bug tree-optimization/32224] New: [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374 tbm at cyrius dot com
@ 2007-06-06 21:03 ` pinskia at gcc dot gnu dot org
  2007-06-07  2:29 ` pinskia at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-06-06 21:03 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from pinskia at gcc dot gnu dot org  2007-06-06 21:03 -------
Confirmed:
t1.c:10: note: ==> examining statement: __asm__("bswap %q0":"=r" *__dst_4:"0"
D.2235_9)


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
   Last reconfirmed|0000-00-00 00:00:00         |2007-06-06 21:03:34
               date|                            |
   Target Milestone|---                         |4.3.0


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


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

* [Bug tree-optimization/32224] [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374
  2007-06-05 17:11 [Bug tree-optimization/32224] New: [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374 tbm at cyrius dot com
  2007-06-06 21:03 ` [Bug tree-optimization/32224] " pinskia at gcc dot gnu dot org
@ 2007-06-07  2:29 ` pinskia at gcc dot gnu dot org
  2007-06-07  2:32 ` pinskia at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-06-07  2:29 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from pinskia at gcc dot gnu dot org  2007-06-07 02:29 -------
Caused by:
r120825 | dorit | 2007-01-16 00:26:03 -0800 (Tue, 16 Jan 2007) | 11 lines

        * tree-vectorizer.h (is_pattern_stmt_p): New.
        * tree-vect-analyze.c (vect_determine_vectorization_factor): Fix
        formatting (tabs instead of spaces). Cleanup and clarify setting
        of STMT_VINFO_VECTYPE. Call is_pattern_stmt_p.
        * tree-vect-transform.c (vect_get_vec_def_for_operand): Fix typo.
        (vectorizable_type_demotion): Check that types are integral.
        (vectorizable_type_promotion): Likewise.
        (vectorizable_store): Fix typo.  Eliminate new-line at end of
        comments.

When we have an ASM_EXPR, we just skip that statement without rejecting it.
The code looks like:
+         if (vect_print_dump_info (REPORT_DETAILS))
+           {
+             fprintf (vect_dump, "==> examining statement: ");
+             print_generic_expr (vect_dump, stmt, TDF_SLIM);
+           }
+
+         if (TREE_CODE (stmt) != GIMPLE_MODIFY_STMT)
+           continue;

Now.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |dorit at il dot ibm dot com


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


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

* [Bug tree-optimization/32224] [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374
  2007-06-05 17:11 [Bug tree-optimization/32224] New: [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374 tbm at cyrius dot com
  2007-06-06 21:03 ` [Bug tree-optimization/32224] " pinskia at gcc dot gnu dot org
  2007-06-07  2:29 ` pinskia at gcc dot gnu dot org
@ 2007-06-07  2:32 ` pinskia at gcc dot gnu dot org
  2007-06-07 18:40 ` dorit at il dot ibm dot com
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-06-07  2:32 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from pinskia at gcc dot gnu dot org  2007-06-07 02:31 -------
here is the link to the patch:
http://gcc.gnu.org/ml/gcc-patches/2007-01/msg00004.html


-- 


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


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

* [Bug tree-optimization/32224] [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374
  2007-06-05 17:11 [Bug tree-optimization/32224] New: [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374 tbm at cyrius dot com
                   ` (2 preceding siblings ...)
  2007-06-07  2:32 ` pinskia at gcc dot gnu dot org
@ 2007-06-07 18:40 ` dorit at il dot ibm dot com
  2007-06-08  8:58 ` dorit at gcc dot gnu dot org
  2007-06-08 16:51 ` pinskia at gcc dot gnu dot org
  5 siblings, 0 replies; 7+ messages in thread
From: dorit at il dot ibm dot com @ 2007-06-07 18:40 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from dorit at il dot ibm dot com  2007-06-07 18:40 -------
You're right. I'm testing this obvious patch:

Index: tree-vect-analyze.c
===================================================================
*** tree-vect-analyze.c (revision 125526)
--- tree-vect-analyze.c (working copy)
*************** vect_determine_vectorization_factor (loo
*** 173,181 ****
              print_generic_expr (vect_dump, stmt, TDF_SLIM);
            }

-         if (TREE_CODE (stmt) != GIMPLE_MODIFY_STMT)
-           continue;
-
          gcc_assert (stmt_info);

          /* skip stmts which do not need to be vectorized.  */
--- 173,178 ----
*************** vect_determine_vectorization_factor (loo
*** 187,192 ****
--- 184,199 ----
              continue;
            }

+         if (TREE_CODE (stmt) != GIMPLE_MODIFY_STMT)
+           {
+             if (vect_print_dump_info (REPORT_UNVECTORIZED_LOOPS))
+               {
+                 fprintf (vect_dump, "not vectorized: irregular stmt.");
+                 print_generic_expr (vect_dump, stmt, TDF_SLIM);
+               }
+             return false;
+           }
+
          if (!GIMPLE_STMT_P (stmt)
              && VECTOR_MODE_P (TYPE_MODE (TREE_TYPE (stmt))))
            {


-- 


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


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

* [Bug tree-optimization/32224] [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374
  2007-06-05 17:11 [Bug tree-optimization/32224] New: [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374 tbm at cyrius dot com
                   ` (3 preceding siblings ...)
  2007-06-07 18:40 ` dorit at il dot ibm dot com
@ 2007-06-08  8:58 ` dorit at gcc dot gnu dot org
  2007-06-08 16:51 ` pinskia at gcc dot gnu dot org
  5 siblings, 0 replies; 7+ messages in thread
From: dorit at gcc dot gnu dot org @ 2007-06-08  8:58 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from dorit at gcc dot gnu dot org  2007-06-08 08:58 -------
Subject: Bug 32224

Author: dorit
Date: Fri Jun  8 08:57:54 2007
New Revision: 125566

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=125566
Log:
        PR tree-optimization/32224
        * tree-vect-analyze.c (vect_determine_vectorization_factor): Fail
        vectorization upon a non GIMPLE_MODIFY_STMT.


Added:
    trunk/gcc/testsuite/gcc.dg/vect/pr32224.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/tree-vect-analyze.c


-- 


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


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

* [Bug tree-optimization/32224] [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374
  2007-06-05 17:11 [Bug tree-optimization/32224] New: [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374 tbm at cyrius dot com
                   ` (4 preceding siblings ...)
  2007-06-08  8:58 ` dorit at gcc dot gnu dot org
@ 2007-06-08 16:51 ` pinskia at gcc dot gnu dot org
  5 siblings, 0 replies; 7+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2007-06-08 16:51 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from pinskia at gcc dot gnu dot org  2007-06-08 16:51 -------
Fixed.


-- 

pinskia at gcc dot gnu dot org changed:

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


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


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

end of thread, other threads:[~2007-06-08 16:51 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-06-05 17:11 [Bug tree-optimization/32224] New: [4.3 Regression] ICE in vect_analyze_operations, at tree-vect-analyze.c:374 tbm at cyrius dot com
2007-06-06 21:03 ` [Bug tree-optimization/32224] " pinskia at gcc dot gnu dot org
2007-06-07  2:29 ` pinskia at gcc dot gnu dot org
2007-06-07  2:32 ` pinskia at gcc dot gnu dot org
2007-06-07 18:40 ` dorit at il dot ibm dot com
2007-06-08  8:58 ` dorit at gcc dot gnu dot org
2007-06-08 16:51 ` pinskia 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).