From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id BB0E63858D33; Thu, 5 Jan 2023 19:53:24 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org BB0E63858D33 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1672948404; bh=i/fDlzVg3YkAlwA1u1CK+QPagT9QhafjT2lq6ua1+OU=; h=From:To:Subject:Date:In-Reply-To:References:From; b=qxGgbIJpl/ldUWeZsJa/B0xk4TN3z7pjNrxASztPWmH5hfKtJLxn0F6NUvLRyUFRr SXoHzKvsDh4Y1Hq5eXtg+oOJF/MPgOYfnPEzlHw5w3jjGzdQupgnDciJZNWRdG/Slq HDrdYT9fOLs2CEZNY87t1oRKY9WrYGqPaKAnrQzY= From: "hjl.tools at gmail dot com" To: gcc-bugs@gcc.gnu.org Subject: [Bug rtl-optimization/108292] [13 Regression] wrong code with vector compare & mask at -O1 and above Date: Thu, 05 Jan 2023 19:53:23 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: rtl-optimization X-Bugzilla-Version: 13.0 X-Bugzilla-Keywords: wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: hjl.tools at gmail dot com X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: roger at nextmovesoftware dot com X-Bugzilla-Target-Milestone: 13.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D108292 --- Comment #13 from H.J. Lu --- 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=3Dalderlake -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 for instructions.=20=20=20=20=20=20=20=20= =20=20=20=20=20 (gdb) f 3 #3 0x0000000002b72759 in cse_insn (insn=3D0x7fffea01bac0) at ../../src-master/gcc/cse.cc:4562 4562 src_eqv =3D 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)=