From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id C4EFD39029B4; Fri, 7 Jun 2024 14:19:35 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org C4EFD39029B4 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1717769975; bh=vDMqLLgoMmJweourbvfVaKJsBj8xofz9jcpSR2KR8J4=; h=From:To:Subject:Date:In-Reply-To:References:From; b=jN3PhJcn/z4eEyG756hznKMMZbDrenPef/fewNI2NHDEAMk25Dqu6nxQoWzUB85zE D4WHquEcW6NDinMmQIxQjilmc87FZ6F8IjYxV3B3bxUE7AeELdXLpL4VZepQEuTAMq Zca3GbKgrI52CPgoLKvJIpM9Dx7fLuVPDxmPSYew= From: "pinskia at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/115363] Missing loop vectorization due to loop bound load not being pulled out Date: Fri, 07 Jun 2024 14:19:34 +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: 15.0 X-Bugzilla-Keywords: missed-optimization X-Bugzilla-Severity: enhancement X-Bugzilla-Who: pinskia at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- 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=3D115363 --- Comment #2 from Andrew Pinski --- (In reply to Richard Biener from comment #1) > Invariant motion doesn't do versioning for aliasing. But in fact once the > loop iterates array[k] can no longer alias this->size but this is difficu= lt > to exploit (peeling the loop once would help). So I should mention that this was noticed from some code internally which is optimized by LLVM's polly (graphite) infrastructure and yes it is an import= ant loop in this code.=