From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 813 invoked by alias); 13 Jan 2013 08:50:28 -0000 Received: (qmail 804 invoked by uid 22791); 13 Jan 2013 08:50:27 -0000 X-SWARE-Spam-Status: No, hits=-3.6 required=5.0 tests=AWL,BAYES_00,DKIM_ADSP_CUSTOM_MED,DKIM_SIGNED,DKIM_VALID,FREEMAIL_FROM,KHOP_RCVD_TRUST,NML_ADSP_CUSTOM_MED,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE X-Spam-Check-By: sourceware.org Received: from mail-we0-f178.google.com (HELO mail-we0-f178.google.com) (74.125.82.178) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 13 Jan 2013 08:50:22 +0000 Received: by mail-we0-f178.google.com with SMTP id x43so1526447wey.37 for ; Sun, 13 Jan 2013 00:50:21 -0800 (PST) X-Received: by 10.180.101.104 with SMTP id ff8mr6806669wib.11.1358067021045; Sun, 13 Jan 2013 00:50:21 -0800 (PST) Received: from localhost ([2.26.203.77]) by mx.google.com with ESMTPS id t17sm7834738wiv.6.2013.01.13.00.50.19 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Sun, 13 Jan 2013 00:50:19 -0800 (PST) From: Richard Sandiford To: gcc-patches@gcc.gnu.org Mail-Followup-To: gcc-patches@gcc.gnu.org, rdsandiford@googlemail.com Subject: RFA: Allow widening multiplication in tree-ssa/slsr-8.c Date: Sun, 13 Jan 2013 08:50:00 -0000 Message-ID: <874nilzctx.fsf@talisman.default> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org X-SW-Source: 2013-01/txt/msg00651.txt.bz2 gcc.dg/tree-ssa/slsr-8.c does "(int) index * (size_t) element_size", which on LP64 targets can use a widening multiplication. Of course, for simple element sizes like these, we end up using a shift instead, but that's a decision that's rightly made later. Tested on x86_64-linux-gnu, mips64-linux-gnu and mipsisa64-elf. OK to install? Richard gcc/testsuite/ * gcc.dg/tree-ssa/slsr-8.c: Allow widening multiplications. Index: gcc/testsuite/gcc.dg/tree-ssa/slsr-8.c =================================================================== --- gcc/testsuite/gcc.dg/tree-ssa/slsr-8.c 2013-01-13 08:05:03.403375571 +0000 +++ gcc/testsuite/gcc.dg/tree-ssa/slsr-8.c 2013-01-13 08:46:05.246550444 +0000 @@ -18,6 +18,7 @@ f (int s, int *c) } /* There are 4 ' * ' instances in the decls (since "int * iftmp.0;" is - added), 1 parm, 2 in the code. */ -/* { dg-final { scan-tree-dump-times " \\* " 7 "optimized" } } */ + added), 1 parm, 2 in the code. The second one in the code can be + a widening mult. */ +/* { dg-final { scan-tree-dump-times " w?\\* " 7 "optimized" } } */ /* { dg-final { cleanup-tree-dump "optimized" } } */