From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 10B843858D28; Tue, 12 Apr 2022 12:20:38 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 10B843858D28 From: "tnfchris at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug target/105219] [12 Regression] SVE: Wrong code with -O3 -msve-vector-bits=128 -mtune=thunderx Date: Tue, 12 Apr 2022 12:20:37 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: target X-Bugzilla-Version: 12.0 X-Bugzilla-Keywords: wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: tnfchris 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: 12.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 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: Tue, 12 Apr 2022 12:20:38 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D105219 --- Comment #8 from Tamar Christina --- looks like the code out of the vectorizer is fine, and between the two vers= ions it doesn't change. The big change is in the unroller, decides to drops one of the BBs for some reason. It turns the loop mask phi node from # loop_mask_374 =3D PHI into # loop_mask_374 =3D PHI and deletes the BB 68. And indeed -fdisable-tree-cunroll fixes the problem. It looks like BB68 in the broken version is being marked as unreachable by = DFA and removed. Curiously with no codegen difference in output of vect, or in dce6 and pcom, the DFA in cunroll find different number of BBs good: Incremental SSA update started at block: 3 Number of blocks in CFG: 88 Number of blocks to update: 37 ( 42%) Affected blocks: 4 18 28 34 45 47 50 51 53 54 56 58 59 60 61 62 63 64 65 66= 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 bad: Incremental SSA update started at block: 3 Number of blocks in CFG: 86 Number of blocks to update: 35 ( 41%) Affected blocks: 4 18 28 34 45 47 50 51 53 54 56 58 59 60 61 62 63 64 65 66= 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 why did it lose 2 BBs? Is there some info missing from the dump files here?=