This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug rtl-optimization/18614] [3.4/4.0 Regression] ICE in simplify_binary_operation


------- Additional Comments From uros at gcc dot gnu dot org  2004-11-23 14:04 -------
Gcc crashes with this insn:

(insn 25 24 26 0 (set (reg:V4SF 60 [ D.1457 ])
        (subreg:V4SF (vec_concat:V4SI (subreg:V2SI (float_truncate:V2SF
(reg:V2DF 73)) 0)
                (const_vector:V2SI [
                        (const_int 0 [0x0])
                        (const_int 0 [0x0])
                    ])) 0)) -1 (nil)
    (nil))

n_elts is calculated as 4, but op0_n_elts and op1_n_elts are 2 (which is kind of
obvious for vec_concat). Because a constant is loaded to (reg 73), the whole
insn simplifies to vec_concat of two constant 2-element vectors.

This triggers the asserts:
      gcc_assert (op0_n_elts == n_elts);
      gcc_assert (op1_n_elts == n_elts);

The fix would be to prevent an entry of vec_concat into simplify_binary_operation().

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18614


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]