when trying to include file mmintrin.h in any file, compilation fails with the following message: mmintrin.h: In function '_mm_add_si64': mmintrin.h:280: error: can't convert between vector values of different size mmintrin.h: In function '_mm_sub_si64': mmintrin.h:382: error: can't convert between vector values of different size It works okay with older versions of gcc, and fails with 4.2.0 20051211 both with the include file that ships with it and with it's older versions. Environment: System: Linux amazonia 2.6.10-5-386 #1 Mon Oct 10 11:15:41 UTC 2005 i686 GNU/Linux Architecture: i686 host: i686-pc-linux-gnu build: i686-pc-linux-gnu target: i686-pc-linux-gnu configured with: ../gcc/configure --enable-languages=c --disable-nls --prefix=/home/glauber/usr How-To-Repeat: create a file containing the single directive #include <mmintrin.h> and compile it with gcc -msse <filename>
Patch posted: http://gcc.gnu.org/ml/gcc-patches/2005-12/msg00659.html
Ok, the patch worked perfectly here. (In reply to comment #1) > Patch posted: > http://gcc.gnu.org/ml/gcc-patches/2005-12/msg00659.html > (In reply to comment #1) > Patch posted: > http://gcc.gnu.org/ml/gcc-patches/2005-12/msg00659.html >
This causes the following testsuite errors: FAIL: gcc.target/i386/3dnow-1.c (test for excess errors) FAIL: gcc.target/i386/3dnow-2.c (test for excess errors) FAIL: gcc.target/i386/3dnowA-1.c (test for excess errors) FAIL: gcc.target/i386/3dnowA-2.c (test for excess errors) FAIL: gcc.target/i386/mmx-1.c (test for excess errors) FAIL: gcc.target/i386/mmx-2.c (test for excess errors) FAIL: gcc.target/i386/mmx-4.c (test for excess errors) WARNING: gcc.target/i386/mmx-4.c compilation failed to produce executable FAIL: gcc.target/i386/mmx-5.c (test for excess errors) FAIL: gcc.target/i386/pr13366.c (test for excess errors) FAIL: gcc.target/i386/sse-1.c (test for excess errors) ERROR: gcc.target/i386/sse-1.c: error executing dg-final: couldn't open "sse-1.s": no such file or directory FAIL: gcc.target/i386/sse-13.c (test for excess errors) FAIL: gcc.target/i386/sse-14.c (test for excess errors) FAIL: gcc.target/i386/sse-2.c (test for excess errors) FAIL: gcc.target/i386/sse-3.c (test for excess errors) WARNING: gcc.target/i386/sse-3.c compilation failed to produce executable FAIL: gcc.target/i386/sse-7.c (test for excess errors) WARNING: gcc.target/i386/sse-7.c compilation failed to produce executable FAIL: gcc.target/i386/sse-9.c (test for excess errors) WARNING: gcc.target/i386/sse-9.c compilation failed to produce executable
In addition to the listed C failures, this is probably also responsible for the C++ regressions FAIL: g++.dg/opt/mmx2.C (test for excess errors) FAIL: g++.dg/other/mmintrin.C (test for excess errors) appearing at the same time.
Fixed by: * config/i386/mmintrin.h (_mm_add_si64): Only define for SSE2. (_mm_sub_si64): Likewise. * config/i386/xmmintrin.h (_mm_shuffle_pi16, _m_pshufw): Likewise. * gcc.target/i386/sse-7.c: Use -msse2.