From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 53CDF3851C06; Thu, 23 Apr 2020 06:44:35 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 53CDF3851C06 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1587624275; bh=aMnXoSiN6jIqDzwz7K8vDgm9yq9cNmflR8g/6/3LyoY=; h=From:To:Subject:Date:In-Reply-To:References:From; b=lTOoHHRdanmph7MBQl+f8PDqXwNKhphkqROrgyLThMuexWjK9q7NRuvilR1Rvgz7q Sbb/C6zoktYMsc5WTBGnHFbkg9ZKbEWUwjU4uawi9AryFuwt2YcDLC5zP7Ryll7A8R Twrnz6NuX0qKFS62xI9iRfsPdxkBnIVnw3peCj1I= From: "rguenth at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/94727] [10 Regression] GCC produces incorrect code with -O3 since r10-5071-g02d895504cc59be0 Date: Thu, 23 Apr 2020 06:44:35 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: tree-optimization X-Bugzilla-Version: 10.0 X-Bugzilla-Keywords: wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: rguenth at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 10.0 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: cf_gcctarget 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 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 23 Apr 2020 06:44:35 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D94727 Richard Biener changed: What |Removed |Added ---------------------------------------------------------------------------- Target| |x86_64-*-* --- Comment #2 from Richard Biener --- test() is basic-block vectorized on the c-loop body which has the d- and e-loops completely unrolled. We create some weird mask__84.17_18 =3D vect_cst__94 < vect_cst__20; vect_patt_266.18_6 =3D VEC_COND_EXPR ; where vect_cst__94 and vect_cst__20 look like { var_3.1_42 ? -1 : 0, var_3.1_42 ? -1 : 0, ... or even { _272 ? -1 : 0, ... with _272 =3D _271 < var_11.0_40 so the vectorization is quite imperfect, mainly due to t1.C:9:32: note: =3D=3D> examining statement: _85 =3D var_11.0_40 > _86; t1.C:12:69: missed: not vectorized: relevant stmt not supported: _85 =3D var_11.0_40 > _86; t1.C:9:32: note: Building vector operands from scalars instead that doesn't yet explain what goes wrong here.=