From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 63223 invoked by alias); 2 Mar 2015 16:24:53 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 63170 invoked by uid 48); 2 Mar 2015 16:24:49 -0000 From: "msebor at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug testsuite/63175] [4.9/5 regression] FAIL: gcc.dg/vect/costmodel/ppc/costmodel-bb-slp-9a.c scan-tree-dump-times slp2" basic block vectorized using SLP" 1 Date: Mon, 02 Mar 2015 16:24:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: testsuite X-Bugzilla-Version: 4.9.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: msebor at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 4.9.3 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2015-03/txt/msg00155.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63175 --- Comment #17 from Martin Sebor --- Following up on my comment #14, and as requested on gcc-patches, the test case below is vectorized with GCC 4.8.2 for T being either 32 bits wide (e.g., int) or 64-bits wide (e.g., long or long long) but not with the fix referenced in comment #13. The difference between the test in costmodel-bb-slp-9a.c and the code here is that unlike the source, the destination of the copy isn't aligned on an even element boundary. const T a [] = { 1, 2, 3, 4, 5 }; extern T b[sizeof a / sizeof *a]; void g (void) { const T *p = a; T *q = b + 1; *q++ = *p++; *q++ = *p++; *q++ = *p++; *q++ = *p++; } In addition to this failure (mentioned on the list) the latest trunk also fails to vectorize the following code which is successfully vectorized by 4.8.2. The difference is that the arrays are only declared here while in costmodel-bb-slp-9a.c they are defined. I only noticed this now, and so it's not being exercised in the proposed enhanced test submitted to gcc-patches last Friday, extern const T a []; extern T b[]; void g (void) { const T *p = a + 1; T *q = b; *q++ = *p++; *q++ = *p++; *q++ = *p++; *q++ = *p++; }