Bug 100783

Summary: gcc reports "Internal compiler error in emit_move_insn_1, at expr.c:2803" compiling fftw3
Product: [Retired] Red Hat Linux Reporter: 260795 <d.sbragion>
Component: gccAssignee: Jakub Jelinek <jakub>
Status: CLOSED CURRENTRELEASE QA Contact: Brian Brock <bbrock>
Severity: medium Docs Contact:
Priority: medium    
Version: 7.3   
Target Milestone: ---   
Target Release: ---   
Hardware: i686   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2004-10-04 00:26:50 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description 260795 2003-07-25 11:27:59 UTC
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0)

Description of problem:
while compiling fftw3 3.0.1 in single precision arithmetic with sse support 
enabled, gcc reports:

In file included from simd.h:22,
                 from 3dnow.c:24:
simd-sse.h: In function `VADD':
simd-sse.h:38: Internal compiler error in emit_move_insn_1, at expr.c:2803
Please submit a full bug report.
See <URL:http://bugzilla.redhat.com/bugzilla/> for instructions.

The code where the error comes up is:

static __inline__ V VADD(V a, V b)
{
     V ret;
     __asm__("addps %2, %0" : "=x"(ret) : "%0"(a), "xm"(b));
     return ret;
}

Version-Release number of selected component (if applicable):
gcc-2.96-113

How reproducible:
Always

Steps to Reproduce:
1. Download "http://www.fftw.org/fftw-3.0.1.tar.gz" and unpack it
2. Run "./configure --enable-sse --enable-single" in the unpacked directory
3. Run make
    

Actual Results:  After compiling some files I got the error described above.

Expected Results:  Complete compilation of the package.

Additional info:

Don't know if this helps but this does not happen with sse2 enabled instead of 
sse.

Comment 1 marleen ade 2004-02-23 17:29:49 UTC
I also encountered this bug and found that the cause was in the 
declaration/definition of two-dimensional const tables, e.g.:
int const specExpTableComb[4][14] =
{
  {1, 2, 3, 5, 6, 7, 9, 10, 11, 13, 14, 15, 17, 18},
  {1, 2, 3, 5, 6, 7, 9, 10, 11, 13, 14, 15, 17, 18},
  {1, 2, 4, 5, 6, 8, 9, 10, 12, 13, 14, 16, 17, 18},
  {1, 3, 4, 5, 7, 8, 9, 11, 12, 13, 15, 16, 17, 19}
};
Removing the 'const' keyword was a good work-around.

Comment 2 Richard Henderson 2004-10-04 00:26:50 UTC
Well, no, removing the const turned off the optimization that
contained the bug.  But it appears to be fixed in gcc 3.2.3-20.