From patchwork Mon Jan 4 12:13:30 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alan Lawrence X-Patchwork-Id: 562349 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id A82F41402ED for ; Mon, 4 Jan 2016 23:13:42 +1100 (AEDT) Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b=E4NzzOHQ; dkim-atps=neutral DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :subject:to:references:cc:from:message-id:date:mime-version :in-reply-to:content-type:content-transfer-encoding; q=dns; s= default; b=koipQ36Z/L9GypyZLZUYhqNIdNXh/nkhxPbtPDFpF1l6JmDJp07/4 AMt8lgtimJGdpA/loe+qWNZgZ6zkiZSAcCiiVGtVmy+fxX7N84pgf3bspMRXERio o0LszHVmcXjBnWya7Q4UlLzlGXoOcXa9s5qHR0kZ3JrK0w9HbuZ+T4= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender :subject:to:references:cc:from:message-id:date:mime-version :in-reply-to:content-type:content-transfer-encoding; s=default; bh=3DciGFzqZ+pcs1W+IxR7VEzbw7Q=; b=E4NzzOHQUwY8bosEYhfRm+z0aeel 2JIV1E//3WURFA3xIgyWsKpLO/cwoav+K7kiGLkjIjmyqmqeXGBYTRoS8wCh7Zkd Pf5KqyYpsl8O198RlH/kX0vZKTAMs2yZyYW3Uv/4hxpn6uH7GThCR7jHnwO6MXMc c8wwtjacR1WaBtA= Received: (qmail 66783 invoked by alias); 4 Jan 2016 12:13:36 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 65954 invoked by uid 89); 4 Jan 2016 12:13:35 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-0.5 required=5.0 tests=AWL, BAYES_00, KAM_LAZY_DOMAIN_SECURITY, RP_MATCHES_RCVD autolearn=no version=3.3.2 spammy=sra, Lawrence, lawrence, tree_to_uhwi X-HELO: foss.arm.com Received: from foss.arm.com (HELO foss.arm.com) (217.140.101.70) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Mon, 04 Jan 2016 12:13:34 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id ED7EB49; Mon, 4 Jan 2016 04:13:00 -0800 (PST) Received: from e105915-lin.cambridge.arm.com (e105915-lin.emea.arm.com [10.2.206.30]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 5A5A23F24D; Mon, 4 Jan 2016 04:13:32 -0800 (PST) Subject: Re: [PATCH 1/4] Make SRA scalarize constant-pool loads To: gcc-patches@gcc.gnu.org References: <1450703608-8617-2-git-send-email-alan.lawrence@arm.com> <1450958010-12882-1-git-send-email-alan.lawrence@arm.com> Cc: wschmidt@linux.vnet.ibm.com From: Alan Lawrence Message-ID: <568A61EA.4040603@foss.arm.com> Date: Mon, 4 Jan 2016 12:13:30 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.4.0 MIME-Version: 1.0 In-Reply-To: <1450958010-12882-1-git-send-email-alan.lawrence@arm.com> On 24/12/15 11:53, Alan Lawrence wrote: > Here's a new version that fixes the gcc.dg/guality/pr54970.c failures seen on > aarch64 and powerpc64. [snip] > This also fixes a bunch of other guality tests on AArch64 that were failing > prior to the patch series, and another bunch on PowerPC64 (bigendian -m32), listed below. Ach, sorry, not quite. That version avoids any regressions (e.g. in pr54970.c), but does not fix all those other tests, unless you also have this hunk (https://gcc.gnu.org/ml/gcc-patches/2015-08/msg01483.html): ...which I was using to increase test coverage of the SRA changes. (Alternatively, you can "fix" the tests by running the testsuite with a forced --param sra-max-scalarization-size. But this is only saying that the dwarf info now generated by scalarizing constant-pools, is better than whatever dwarf was being generated by whatever other part of the compiler before.) --Alan diff --git a/gcc/tree-sra.c b/gcc/tree-sra.c index a3ff2df..2a741b8 100644 --- a/gcc/tree-sra.c +++ b/gcc/tree-sra.c @@ -2651,7 +2651,8 @@ analyze_all_variable_accesses (void) && scalarizable_type_p (TREE_TYPE (var))) { if (tree_to_uhwi (TYPE_SIZE (TREE_TYPE (var))) - <= max_scalarization_size) + <= max_scalarization_size + || DECL_IN_CONSTANT_POOL (var)) { create_total_scalarization_access (var); completely_scalarize (var, TREE_TYPE (var), 0, var);