public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug tree-optimization/26600]  New: internal compiler error: in push_reload, at reload.c:1303
@ 2006-03-07 22:07 ma1flfs at bath dot ac dot uk
  2006-03-08  3:06 ` [Bug target/26600] " pinskia at gcc dot gnu dot org
                   ` (12 more replies)
  0 siblings, 13 replies; 14+ messages in thread
From: ma1flfs at bath dot ac dot uk @ 2006-03-07 22:07 UTC (permalink / raw)
  To: gcc-bugs

void fdct_int32()
{
        int tmp4, tmp5, tmp7;
        int z1, z2, z3, z4, z5;
        int *dataptr;
        int i;

        for (i = 0; i < 8; i++) {
                tmp7 = dataptr[0];

                z3 = tmp4;
                z4 = tmp5 + tmp7;
                z5 = (z3 + z4) * ((int) 9633);

                z3 += z5;

                dataptr[56] = tmp4 + z1 + z3;
                dataptr[40] = tmp5 + z2 + z4;

                dataptr++;
        }
}

When compiling the above file with the following command line arguments:
gcc -c -O -march=pentium4 -ftree-vectorize foo.c

I get the following error:
foo.c: In function 'fdct_int32':
foo.c:22: internal compiler error: in push_reload, at reload.c:1303
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.

I discovered this while trying to compile the xvid sources using silly CFLAGS
by accident. The above file is a somewhat reduced testcase.


-- 
           Summary: internal compiler error: in push_reload, at
                    reload.c:1303
           Product: gcc
           Version: 4.1.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: ma1flfs at bath dot ac dot uk
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


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


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

* [Bug target/26600] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
@ 2006-03-08  3:06 ` pinskia at gcc dot gnu dot org
  2006-03-08 10:18 ` [Bug target/26600] [4.1/4.2 Regression] " rguenth at gcc dot gnu dot org
                   ` (11 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-03-08  3:06 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from pinskia at gcc dot gnu dot org  2006-03-08 03:06 -------
Hmm, this works in "4.1.1 20060304" on x86_64 with -m32.


-- 


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


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

* [Bug target/26600] [4.1/4.2 Regression] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
  2006-03-08  3:06 ` [Bug target/26600] " pinskia at gcc dot gnu dot org
@ 2006-03-08 10:18 ` rguenth at gcc dot gnu dot org
  2006-03-08 10:41 ` rguenth at gcc dot gnu dot org
                   ` (10 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2006-03-08 10:18 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from rguenth at gcc dot gnu dot org  2006-03-08 10:18 -------
For mainline, this is a dup of 26449.  For 4.1.0 I can reproduce this:

#1  0x08493eae in push_reload (in=0x4023a4b8, out=0x40241280, 
    inloc=0x40244a84, outloc=0x40229be0, class=NO_REGS, inmode=V4SImode, 
    outmode=TImode, strict_low=0, optional=0, opnum=0, type=RELOAD_OTHER)
    at /space/rguenther/src/svn/gcc-4_1-branch/gcc/reload.c:1302

  gcc_assert (class != NO_REGS
              || (optional != 0 && type == RELOAD_FOR_OUTPUT));

(gdb) call debug_rtx (in)
(const_vector:V4SI [
        (const_int 9633 [0x25a1])
        (const_int 9633 [0x25a1])
        (const_int 9633 [0x25a1])
        (const_int 9633 [0x25a1])
    ])
(gdb) call debug_rtx (out)
(reg:TI 23 xmm2)

this problem may be latent on the mainline (so I make it depend on 26449).
This is a regression in that we didn't ICE here for 4.0, but we didn't do any
vectorization there either.

So, who's the reload expert for vector stuff ;)


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  BugsThisDependsOn|                            |26449
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
  GCC build triplet|i686-pc-linux-gnu           |
   GCC host triplet|i686-pc-linux-gnu           |
           Keywords|                            |ice-on-valid-code, ssemmx
   Last reconfirmed|0000-00-00 00:00:00         |2006-03-08 10:18:34
               date|                            |
            Summary|internal compiler error: in |[4.1/4.2 Regression]
                   |push_reload, at             |internal compiler error: in
                   |reload.c:1303               |push_reload, at
                   |                            |reload.c:1303


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


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

* [Bug target/26600] [4.1/4.2 Regression] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
  2006-03-08  3:06 ` [Bug target/26600] " pinskia at gcc dot gnu dot org
  2006-03-08 10:18 ` [Bug target/26600] [4.1/4.2 Regression] " rguenth at gcc dot gnu dot org
@ 2006-03-08 10:41 ` rguenth at gcc dot gnu dot org
  2006-03-08 12:39 ` pinskia at gcc dot gnu dot org
                   ` (9 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2006-03-08 10:41 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from rguenth at gcc dot gnu dot org  2006-03-08 10:40 -------
(gdb) call debug_rtx(*outloc)
(subreg:TI (reg:V4SI 23 xmm2 [99]) 0)

(but of course it looks like NO_REGS doesn't make any sense for this reload)

(gdb) up
#2  0x0849b343 in find_reloads (insn=0x402401b8, replace=0, ind_levels=0, 
    live_known=1, reload_reg_p=0x87f5a00)
    at /space/rguenther/src/svn/gcc-4_1-branch/gcc/reload.c:3953
3953                operand_reloadnum[goal_alternative_matched[i]]
(gdb) call debug_rtx (insn)
(insn 58 57 59 2 (set (subreg:TI (reg:V4SI 23 xmm2 [99]) 0)
        (lshiftrt:TI (subreg:TI (reg:V4SI 96) 0)
            (const_int 32 [0x20]))) 711 {sse2_lshrti3} (nil)
    (nil))

and we call push_reload with in
(subreg:TI (const_vector:V4SI [
            (const_int 9633 [0x25a1])
            (const_int 9633 [0x25a1])
            (const_int 9633 [0x25a1])
            (const_int 9633 [0x25a1])
        ]) 0)

Looking at reload.c:1018 I don't feel like wanting to dig further ;)


-- 


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


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

* [Bug target/26600] [4.1/4.2 Regression] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
                   ` (2 preceding siblings ...)
  2006-03-08 10:41 ` rguenth at gcc dot gnu dot org
@ 2006-03-08 12:39 ` pinskia at gcc dot gnu dot org
  2006-03-26 13:14 ` reichelt at gcc dot gnu dot org
                   ` (8 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-03-08 12:39 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from pinskia at gcc dot gnu dot org  2006-03-08 12:39 -------
So it looks like this is HWI bug really, if a target needs to support TImode in
any shape or form, HWI should be set to 64bits no questions asked.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   GCC host triplet|                            |32bits
   Target Milestone|---                         |4.1.1


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


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

* [Bug target/26600] [4.1/4.2 Regression] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
                   ` (3 preceding siblings ...)
  2006-03-08 12:39 ` pinskia at gcc dot gnu dot org
@ 2006-03-26 13:14 ` reichelt at gcc dot gnu dot org
  2006-04-16 18:43 ` mmitchel at gcc dot gnu dot org
                   ` (7 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2006-03-26 13:14 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from reichelt at gcc dot gnu dot org  2006-03-26 13:13 -------
Shorter testcase (compile with "gcc -O -ftree-vectorize -msse2"):

====================================================
void foo(int *p, int N)
{
    int i;
    for (i=0; i<8; ++i, ++p)
    {
        int j = N+2*(N+p[0]), k = 2*N+p[0];
        p[0] = j+N;
        p[5] = j+k;
    }
}
====================================================


-- 

reichelt at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |reichelt at gcc dot gnu dot
                   |                            |org


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


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

* [Bug target/26600] [4.1/4.2 Regression] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
                   ` (4 preceding siblings ...)
  2006-03-26 13:14 ` reichelt at gcc dot gnu dot org
@ 2006-04-16 18:43 ` mmitchel at gcc dot gnu dot org
  2006-04-18 14:07 ` bonzini at gnu dot org
                   ` (6 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: mmitchel at gcc dot gnu dot org @ 2006-04-16 18:43 UTC (permalink / raw)
  To: gcc-bugs



-- 

mmitchel at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P3                          |P1


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


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

* [Bug target/26600] [4.1/4.2 Regression] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
                   ` (5 preceding siblings ...)
  2006-04-16 18:43 ` mmitchel at gcc dot gnu dot org
@ 2006-04-18 14:07 ` bonzini at gnu dot org
  2006-04-18 16:15 ` pinskia at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: bonzini at gnu dot org @ 2006-04-18 14:07 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from bonzini at gnu dot org  2006-04-18 14:07 -------
pinskia: You're right in some sense but, shudder, this will make things
sloooow.


-- 


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


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

* [Bug target/26600] [4.1/4.2 Regression] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
                   ` (6 preceding siblings ...)
  2006-04-18 14:07 ` bonzini at gnu dot org
@ 2006-04-18 16:15 ` pinskia at gcc dot gnu dot org
  2006-05-11 17:22 ` roger at eyesopen dot com
                   ` (4 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2006-04-18 16:15 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from pinskia at gcc dot gnu dot org  2006-04-18 16:15 -------
(In reply to comment #6)
> pinskia: You're right in some sense but, shudder, this will make things
> sloooow.

No it will not.  I and others have sped up the HWI being 64bit case as
PPC-darwin was 32bit until the 64 in 32 mode came around and had to change. 
Please come back with real prove that GCC will slow down with the change
instead of just saying it will because I have already speed it up at least
twice.


-- 


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


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

* [Bug target/26600] [4.1/4.2 Regression] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
                   ` (7 preceding siblings ...)
  2006-04-18 16:15 ` pinskia at gcc dot gnu dot org
@ 2006-05-11 17:22 ` roger at eyesopen dot com
  2006-05-14 14:23 ` steven at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: roger at eyesopen dot com @ 2006-05-11 17:22 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #8 from roger at eyesopen dot com  2006-05-11 17:22 -------
Patch posted here: http://gcc.gnu.org/ml/gcc-patches/2006-05/msg00472.html


-- 


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


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

* [Bug target/26600] [4.1/4.2 Regression] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
                   ` (8 preceding siblings ...)
  2006-05-11 17:22 ` roger at eyesopen dot com
@ 2006-05-14 14:23 ` steven at gcc dot gnu dot org
  2006-05-16  4:18 ` sayle at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  12 siblings, 0 replies; 14+ messages in thread
From: steven at gcc dot gnu dot org @ 2006-05-14 14:23 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #9 from steven at gcc dot gnu dot org  2006-05-14 14:23 -------
Please take bugs if you post patches for them, it makes it easier to search for
bugs that nobody is looking at.


-- 

steven at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |sayle at gcc dot gnu dot org
                   |dot org                     |
             Status|NEW                         |ASSIGNED


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


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

* [Bug target/26600] [4.1/4.2 Regression] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
                   ` (9 preceding siblings ...)
  2006-05-14 14:23 ` steven at gcc dot gnu dot org
@ 2006-05-16  4:18 ` sayle at gcc dot gnu dot org
  2006-05-17  1:12 ` sayle at gcc dot gnu dot org
  2006-05-18  1:50 ` roger at eyesopen dot com
  12 siblings, 0 replies; 14+ messages in thread
From: sayle at gcc dot gnu dot org @ 2006-05-16  4:18 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #10 from sayle at gcc dot gnu dot org  2006-05-16 04:17 -------
Subject: Bug 26600

Author: sayle
Date: Tue May 16 04:16:00 2006
New Revision: 113818

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=113818
Log:

        PR target/26600
        * config/i386/i386.c (legitimate_constant_p) <CONST_DOUBLE>: TImode
        integer constants other than zero are only legitimate on TARGET_64BIT.
        <CONST_VECTOR> Only zero vectors are legitimate.
        (ix86_cannot_force_const_mem): Integral and vector constants can
        always be put in the constant pool.

        * gcc.target/i386/pr26600.c: New test case.


Added:
    trunk/gcc/testsuite/gcc.target/i386/pr26600.c
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/config/i386/i386.c
    trunk/gcc/testsuite/ChangeLog


-- 


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


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

* [Bug target/26600] [4.1/4.2 Regression] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
                   ` (10 preceding siblings ...)
  2006-05-16  4:18 ` sayle at gcc dot gnu dot org
@ 2006-05-17  1:12 ` sayle at gcc dot gnu dot org
  2006-05-18  1:50 ` roger at eyesopen dot com
  12 siblings, 0 replies; 14+ messages in thread
From: sayle at gcc dot gnu dot org @ 2006-05-17  1:12 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #11 from sayle at gcc dot gnu dot org  2006-05-17 01:12 -------
Subject: Bug 26600

Author: sayle
Date: Wed May 17 01:11:59 2006
New Revision: 113839

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=113839
Log:

        PR target/26600
        * config/i386/i386.c (legitimate_constant_p) <CONST_DOUBLE>: TImode
        integer constants other than zero are only legitimate on TARGET_64BIT.
        <CONST_VECTOR> Only zero vectors are legitimate.
        (ix86_cannot_force_const_mem): Integral and vector constants can
        always be put in the constant pool.

        * gcc.target/i386/pr26600.c: New test case.


Added:
    branches/gcc-4_1-branch/gcc/testsuite/gcc.target/i386/pr26600.c
Modified:
    branches/gcc-4_1-branch/gcc/ChangeLog
    branches/gcc-4_1-branch/gcc/config/i386/i386.c
    branches/gcc-4_1-branch/gcc/testsuite/ChangeLog


-- 


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


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

* [Bug target/26600] [4.1/4.2 Regression] internal compiler error: in push_reload, at reload.c:1303
  2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
                   ` (11 preceding siblings ...)
  2006-05-17  1:12 ` sayle at gcc dot gnu dot org
@ 2006-05-18  1:50 ` roger at eyesopen dot com
  12 siblings, 0 replies; 14+ messages in thread
From: roger at eyesopen dot com @ 2006-05-18  1:50 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #12 from roger at eyesopen dot com  2006-05-18 01:50 -------
This is now fixed on both mainline and the 4.1 branch.


-- 

roger at eyesopen dot com changed:

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


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


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

end of thread, other threads:[~2006-05-18  1:50 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-03-07 22:07 [Bug tree-optimization/26600] New: internal compiler error: in push_reload, at reload.c:1303 ma1flfs at bath dot ac dot uk
2006-03-08  3:06 ` [Bug target/26600] " pinskia at gcc dot gnu dot org
2006-03-08 10:18 ` [Bug target/26600] [4.1/4.2 Regression] " rguenth at gcc dot gnu dot org
2006-03-08 10:41 ` rguenth at gcc dot gnu dot org
2006-03-08 12:39 ` pinskia at gcc dot gnu dot org
2006-03-26 13:14 ` reichelt at gcc dot gnu dot org
2006-04-16 18:43 ` mmitchel at gcc dot gnu dot org
2006-04-18 14:07 ` bonzini at gnu dot org
2006-04-18 16:15 ` pinskia at gcc dot gnu dot org
2006-05-11 17:22 ` roger at eyesopen dot com
2006-05-14 14:23 ` steven at gcc dot gnu dot org
2006-05-16  4:18 ` sayle at gcc dot gnu dot org
2006-05-17  1:12 ` sayle at gcc dot gnu dot org
2006-05-18  1:50 ` roger at eyesopen dot com

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).