https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108292

--- Comment #13 from H.J. Lu <hjl.tools at gmail dot com> ---
I also got

$ cat foo.i
extern void foo (float *);

extern int x;
int
mouse_frame_side(void) {
  float mouseloc;
  foo (&mouseloc);
  return mouseloc > x ? 1 : 2;
}
$ gcc -march=alderlake -Ofast -S foo.i
during RTL pass: cse2
foo.i: In function ?mouse_frame_side?:
foo.i:9:1: internal compiler error: in copy_rtx, at rtl.cc:369
    9 | }
      | ^
0x148a75b copy_rtx(rtx_def*)
        ../../src-master/gcc/rtl.cc:369
0x148a690 copy_rtx(rtx_def*)
        ../../src-master/gcc/rtl.cc:342
0x2b72758 cse_insn
        ../../src-master/gcc/cse.cc:4562
0x2b787b8 cse_extended_basic_block
        ../../src-master/gcc/cse.cc:6566
0x2b78cd6 cse_main
        ../../src-master/gcc/cse.cc:6711
0x2b7ae5e rest_of_handle_cse2
        ../../src-master/gcc/cse.cc:7600
0x2b7af84 execute
        ../../src-master/gcc/cse.cc:7655
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.             

(gdb) f 3
#3  0x0000000002b72759 in cse_insn (insn=0x7fffea01bac0)
    at ../../src-master/gcc/cse.cc:4562
4562            src_eqv = copy_rtx (XEXP (tem, 0));
(gdb) call debug_rtx (insn)
(insn 48 47 49 2 (parallel [
            (set (reg:SI 94)
                (if_then_else:SI (unlt:SI (reg:CCFP 17 flags)
                        (const_int 0 [0]))
                    (const_int -1 [0xffffffffffffffff])
                    (const_int 0 [0])))
            (clobber (reg:CC 17 flags))
        ]) "/export/project/git/gcc-bisect/foo.i":8:27 discrim 2 1288
{*x86_movsicc_0_m1}
     (expr_list:REG_DEAD (reg:CCFP 17 flags)
        (expr_list:REG_UNUSED (reg:CC 17 flags)
            (expr_list:REG_EQUAL (neg:SI (UnKnown:SI Unknown))
                (nil)))))
(gdb)

Reply via email to