From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5452 invoked by alias); 12 Oct 2011 08:12:34 -0000 Received: (qmail 5437 invoked by uid 22791); 12 Oct 2011 08:12:32 -0000 X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 tests=AWL,BAYES_00 X-Spam-Check-By: sourceware.org Received: from mel.act-europe.fr (HELO mel.act-europe.fr) (194.98.77.210) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 12 Oct 2011 08:12:16 +0000 Received: from localhost (localhost [127.0.0.1]) by filtered-smtp.eu.adacore.com (Postfix) with ESMTP id AEBC3CB0314; Wed, 12 Oct 2011 10:12:16 +0200 (CEST) Received: from mel.act-europe.fr ([127.0.0.1]) by localhost (smtp.eu.adacore.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id o1ov593dXil7; Wed, 12 Oct 2011 10:12:07 +0200 (CEST) Received: from [192.168.1.2] (bon31-9-83-155-120-49.fbx.proxad.net [83.155.120.49]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mel.act-europe.fr (Postfix) with ESMTP id D4E10CB0250; Wed, 12 Oct 2011 10:12:06 +0200 (CEST) From: Eric Botcazou To: Oleg Endo Subject: Re: Combine Pass Behavior Date: Wed, 12 Oct 2011 09:44:00 -0000 User-Agent: KMail/1.9.9 Cc: gcc@gcc.gnu.org References: <1318301863.19997.311.camel@yam-132-YW-E178-FTW> In-Reply-To: <1318301863.19997.311.camel@yam-132-YW-E178-FTW> MIME-Version: 1.0 Content-Disposition: inline Message-Id: <201110121008.09411.ebotcazou@adacore.com> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org X-SW-Source: 2011-10/txt/msg00192.txt.bz2 > The actual problem (or maybe my misunderstanding) is that it > combines the two original insns, then does some substitutions and tries > to match the combined and transformed insn against those defined in the > machine description. If it can't find anything there it reverts > everything and proceeds with the next insn pair. It never tries out the > straight forward option in the first place (which is not to transform > the combination). The combiner pass does some form of canonicalization to better combine, see expand_compound_operation and make_compound_operation. > Is the scenario above intended behavior of the combine pass or an > accident? Or maybe even something else wrong in the machine description > that makes it behave like that? See how the i386 back-end copes with this for its "test" instruction. -- Eric Botcazou