From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 26038 invoked by alias); 18 Jul 2010 20:47:22 -0000 Received: (qmail 26028 invoked by uid 22791); 18 Jul 2010 20:47:21 -0000 X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mail.codesourcery.com (HELO mail.codesourcery.com) (38.113.113.100) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 18 Jul 2010 20:47:17 +0000 Received: (qmail 13711 invoked from network); 18 Jul 2010 20:47:15 -0000 Received: from unknown (HELO ?84.152.201.232?) (bernds@127.0.0.2) by mail.codesourcery.com with ESMTPA; 18 Jul 2010 20:47:15 -0000 Message-ID: <4C436835.20307@codesourcery.com> Date: Sun, 18 Jul 2010 20:47:00 -0000 From: Bernd Schmidt User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.10) Gecko/20100625 Thunderbird/3.0.5 MIME-Version: 1.0 To: gcc-patches@gcc.gnu.org, rdsandiford@googlemail.com Subject: Re: Extend widening_mul pass to handle fixed-point types References: <87fwzhro8i.fsf@firetop.home> In-Reply-To: <87fwzhro8i.fsf@firetop.home> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit 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: 2010-07/txt/msg01455.txt.bz2 On 07/18/2010 02:03 PM, Richard Sandiford wrote: > + /* At present, WIDEN_MULT_EXPR only supports integer types, > + not fixed-point ones. Processing fixed-point types is only > + useful if the caller wants the unextended operands. */ > + if (TREE_CODE (type) == FIXED_POINT_TYPE) > + use_widen_mult_p = false; I don't like this bit. I'd break up this function into one that just extracts the unwidened operands, and another one that generates the widening multiply. The former can then be used for also generating widening-macc. Whether to generate anything for fixed-point should just depend on the availability of the optabs. Ok with that change. Bernd