The code below, when compiled by "gcc -O3 -msse", gives the following
error (same code compiles fine in gcc 3.3.5):

bug2.c: In function 'main':
bug2.c:17: error: Invalid reference prefix.
&fooD.1292;

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

Environment:
System: Linux fftw.org 2.6.3-1-686-smp #2 SMP Tue Feb 24 20:29:08 EST 2004 i686 
GNU/Linux
Architecture: i686

        
host: i686-pc-linux-gnu
build: i686-pc-linux-gnu
target: i686-pc-linux-gnu
configured with: ../configure --prefix=/home/stevenj/gcc4

How-To-Repeat:

Compile the following code with 'gcc -O3 -msse -o bug2 bug2.c'

typedef float V __attribute__ ((vector_size (16)));
union fvec {
     float f[4];
     V v;
};

typedef unsigned int uintptr_t;
#define ALIGNMENT 8
#define TAINT_BIT 1
#define PTRINT(p) ((uintptr_t)(p))
#define ALIGNED(p) \
  (((PTRINT(p) % ALIGNMENT) == 0) && !(PTRINT(p) & TAINT_BIT))

const union fvec foo = {{-0.0, 0.0, -0.0, 0.0}};

int main(void)
{
     return !ALIGNED(&foo);
}

-- 
           Summary: ICE on simple SSE code (works in gcc 3.3)
           Product: gcc
           Version: 4.0.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: stevenj at fftw dot org
                CC: gcc-bugs at gcc dot gnu dot org
 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=19858

Reply via email to