This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug rtl-optimization/32123] New: gcc.target/i386/sse2-vec-6.c fails for -mtune=k8
- From: "ubizjak at gmail dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 28 May 2007 07:48:36 -0000
- Subject: [Bug rtl-optimization/32123] New: gcc.target/i386/sse2-vec-6.c fails for -mtune=k8
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
This testcase fails for:
gcc -O2 -msse2 -mtune=k8 sse2-vec-6.c
Analyzing compilation unit
Performing interprocedural optimizations
<visibility> <early_local_cleanups> <inline> <static-var> <pure-const>
<type-escape-var>Assembling functions:
i386_cpuid_ecx i386_cpuid_edx i386_extended_cpuid_ecx i386_extended_cpuid_edx
sse2_test
sse2-vec-6.c: In function âsse2_testâ:
sse2-vec-6.c:69: internal compiler error: in expand_simple_binop, at
optabs.c:1214
Please submit a full bug report,
Backtrace:
#0 fancy_abort (file=0x8701de4 "../../gcc-svn/trunk/gcc/optabs.c", line=1214,
function=0x87022f2 "expand_simple_binop") at
../../gcc-svn/trunk/gcc/diagnostic.c:656
#1 0x082706e7 in expand_simple_binop (mode=V2SFmode, code=VEC_SELECT,
op0=0xb795a57c, op1=0xb792c938, target=0xb795c350, unsignedp=1,
methods=OPTAB_LIB_WIDEN) at ../../gcc-svn/trunk/gcc/optabs.c:1214
#2 0x081a5edb in force_operand (value=0xb795a5ac, target=0xb795c350) at
../../gcc-svn/trunk/gcc/expr.c:6084
#3 0x086144ab in move_invariant_reg (loop=0xb794ef74, invno=0) at
../../gcc-svn/trunk/gcc/loop-invariant.c:1178
#4 0x0861580d in move_loop_invariants () at
../../gcc-svn/trunk/gcc/loop-invariant.c:1240
#5 0x086137d5 in rtl_move_loop_invariants () at
../../gcc-svn/trunk/gcc/loop-init.c:239
#6 0x08276976 in execute_one_pass (pass=0x87c7280) at
../../gcc-svn/trunk/gcc/passes.c:1067
The problem is that we enter force_operand() with:
(gdb) p debug_rtx (value)
(vec_select:V2SF (subreg:V4SF (reg:V2DI 91 [ pretmp.201 ]) 0)
(parallel [
(const_int 0 [0x0])
(const_int 1 [0x1])
]))
There is no optab for vec_select, and we crash later in assert in
expand_simple_optab() on uninitialized optab.
The failure is actually the same as in PR26449, however the solution [1] looks
rather suspicious to me, as force_operand() won't return NULL, but would crash
via expand_simple_optab() for RTXs without optab.
[1] http://gcc.gnu.org/ml/gcc-patches/2006-06/msg00313.html
--
Summary: gcc.target/i386/sse2-vec-6.c fails for -mtune=k8
Product: gcc
Version: 4.3.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: rtl-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: ubizjak at gmail dot com
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=32123