Bug 21163 - [4.0 regression] internal compiler error: in output_constant_pool_2, at varasm.c:3135
Summary: [4.0 regression] internal compiler error: in output_constant_pool_2, at varas...
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: rtl-optimization (show other bugs)
Version: 4.0.0
: P2 normal
Target Milestone: 4.0.1
Assignee: Richard Henderson
URL:
Keywords: ice-on-valid-code, ssemmx
: 21522 (view as bug list)
Depends on:
Blocks:
 
Reported: 2005-04-22 15:26 UTC by Anuradha Suraparaju
Modified: 2007-12-02 22:40 UTC (History)
3 users (show)

See Also:
Host: i686-pc-linux-gnu
Target: i686-pc-linux-gnu
Build: i686-pc-linux-gnu
Known to work: 4.1.0
Known to fail:
Last reconfirmed: 2005-04-24 07:50:34


Attachments
g++ --save-temps -mmmx -g -O2 test_mmx_diff2.cpp (92.33 KB, text/plain)
2005-04-22 15:28 UTC, Anuradha Suraparaju
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Anuradha Suraparaju 2005-04-22 15:26:19 UTC
gcc -v 

Using built-in specs.
Target: i686-pc-linux-gnu
Configured with: ../gcc-4.0.0/configure --prefix=/usr/local/gcc-4.0.0
Thread model: posix
gcc version 4.0.0


g++ --save-temps -mmmx -g -O2 test_mmx_diff2.cpp
test_mmx_diff2.cpp: In function ‘int simple_block_diff_mmx_4(short int** const&,
short int** const&, int)’:
test_mmx_diff2.cpp:42: internal compiler error: in output_constant_pool_2, at
varasm.c:3135
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
Comment 1 Anuradha Suraparaju 2005-04-22 15:28:01 UTC
Created attachment 8710 [details]
g++ --save-temps -mmmx -g -O2 test_mmx_diff2.cpp

g++ --save-temps -mmmx -g -O2 test_mmx_diff2.cpp
Comment 2 Andrew Pinski 2005-04-22 15:53:01 UTC
 configured with: ../gcc-4.0.0/configure --pref
Comment 3 Andrew Pinski 2005-04-22 15:58:16 UTC
Even though the ICE has nothing to do with the following but you are violating C aliasing rules with the 
following:
           __m64 pic = *(__m64 *)&pic_data[j][i];
           __m64 ref = *(__m64 *)&ref_data[j][i];
Comment 4 Andrew Pinski 2005-04-22 16:01:24 UTC
This works on the mainline.
Comment 5 Richard Henderson 2005-04-24 22:10:08 UTC
Not target specific.
Comment 6 CVS Commits 2005-04-24 22:15:13 UTC
Subject: Bug 21163

CVSROOT:	/cvs/gcc
Module name:	gcc
Branch: 	gcc-4_0-branch
Changes by:	rth@gcc.gnu.org	2005-04-24 22:15:06

Modified files:
	gcc            : ChangeLog simplify-rtx.c 

Log message:
	PR rtl-opt/21163
	* simplify-rtx.c (simplify_binary_operation) <IOR>: Check
	for SCALAR_INT_MODE_P instead of not MODE_CC before returning
	constm1_rtx.
	<XOR, AND, LSHIFTRT, UMIN>: Use CONST0_RTX.
	<UDIV, UMOD>: Use CONST0_RTX and CONST1_RTX.
	<DIV, MOD>: Likewise.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=2.7592.2.187&r2=2.7592.2.188
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/simplify-rtx.c.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.230.2.5&r2=1.230.2.6

Comment 7 CVS Commits 2005-04-24 22:16:55 UTC
Subject: Bug 21163

CVSROOT:	/cvs/gcc
Module name:	gcc
Changes by:	rth@gcc.gnu.org	2005-04-24 22:16:49

Modified files:
	gcc            : ChangeLog simplify-rtx.c 

Log message:
	PR rtl-opt/21163
	* simplify-rtx.c (simplify_binary_operation) <IOR>: Check
	for SCALAR_INT_MODE_P instead of not MODE_CC before returning
	constm1_rtx.
	<AND, LSHIFTRT, UMIN>: Use CONST0_RTX.
	<UDIV, UMOD>: Use CONST0_RTX and CONST1_RTX.
	<DIV, MOD>: Likewise.

Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcc&r1=2.8442&r2=2.8443
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/simplify-rtx.c.diff?cvsroot=gcc&r1=1.238&r2=1.239

Comment 8 Richard Henderson 2005-04-24 22:20:41 UTC
Fixed.
Comment 9 Andrew Pinski 2005-05-11 22:42:29 UTC
*** Bug 21522 has been marked as a duplicate of this bug. ***