From patchwork Tue Dec 9 17:38:42 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sebastian Pop X-Patchwork-Id: 419201 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 D90BE1400DE for ; Wed, 10 Dec 2014 04:39:04 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:date :from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; q=dns; s=default; b=p7jlgtBoPaj5QlogE CeQBP0bQ0wDVpRwR9yaLhGYJu7zOJ0sTDpE2yai6OXdhM1FzKz0CLLV4ErpLv1DO OTPkSokmJVK36hibpIVaKERih7pCJFGdXKXvJf/Vu+PPTppI5BjHhdl/sWaF1Sev vu/bQL5rydJnXcOGqbB10staHM= 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:date :from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=default; bh=tqNjez2H3nURDuy45lml2pz 2FD4=; b=H7VoJg3riXr2DR4+yvfSZe3fbB5EO7rVZWwNh6rHkY1MIoEeVoDnfG+ KYPBN+thsQ3yJGtMPAdZcU+Cm+Sc8j2+Pyt4DcitnzPxEKrb90/119pq0aTxo0P4 fxZPZKd6gJKr63yIw7/hqkqnqpuKupkCzneMqed0skQ7qjfYwnWo= Received: (qmail 26125 invoked by alias); 9 Dec 2014 17:38:50 -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 26073 invoked by uid 89); 9 Dec 2014 17:38:49 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.6 required=5.0 tests=AWL, BAYES_00, FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-ie0-f178.google.com Received: from mail-ie0-f178.google.com (HELO mail-ie0-f178.google.com) (209.85.223.178) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Tue, 09 Dec 2014 17:38:47 +0000 Received: by mail-ie0-f178.google.com with SMTP id tp5so974982ieb.37 for ; Tue, 09 Dec 2014 09:38:45 -0800 (PST) X-Received: by 10.107.25.2 with SMTP id 2mr7681278ioz.70.1418146725571; Tue, 09 Dec 2014 09:38:45 -0800 (PST) Received: from f1.c.bardezibar.internal (81.37.148.146.bc.googleusercontent.com. [146.148.37.81]) by mx.google.com with ESMTPSA id x10sm1166507igl.19.2014.12.09.09.38.44 for (version=SSLv3 cipher=RC4-SHA bits=128/128); Tue, 09 Dec 2014 09:38:44 -0800 (PST) Date: Tue, 9 Dec 2014 17:38:42 +0000 From: Sebastian Pop To: Richard Biener Cc: Steve Ellcey , Jeff Law , James Greenhalgh , GCC Patches Subject: Re: [Patch] Improving jump-thread pass for PR 54742 Message-ID: <20141209173842.GA31443@f1.c.bardezibar.internal> References: <20141125172945.GA31146@f1.c.bardezibar.internal> <20141125211618.GA32340@f1.c.bardezibar.internal> <547CD855.50501@redhat.com> <20141204110428.GC18834@f1.c.bardezibar.internal> <20141204142956.GD18834@f1.c.bardezibar.internal> <548211B9.6020307@redhat.com> <20141206134728.GA29926@f1.c.bardezibar.internal> <20141206192113.GB29926@f1.c.bardezibar.internal> <1418075397.2196.76.camel@ubuntu-sellcey> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-IsSubscribed: yes Richard Biener wrote: > On Mon, Dec 8, 2014 at 10:49 PM, Steve Ellcey wrote: > > expected? Should this test also check flag_thread_jumps? Or should > > that be getting checked somewhere else? > > -fthread-jumps is an RTL optimization flag and ignored on GIMPLE. Does it make sense to add a -f[no-]tree-thread-jumps to enable/disable the tree jump threading? I could also add -f[no-]tree-fsm-thread-jumps. Opinions? On the llvm test-suite, I have seen one ICE with my fsm jump-thread patch. This patch fixes the problem: retval |= thread_through_loop_header (loop, may_peel_loop_headers); Ok to commit after regstrap? Thanks, Sebastian diff --git a/gcc/tree-ssa-threadupdate.c b/gcc/tree-ssa-threadupdate.c index 12f83ba..f8c736e 100644 --- a/gcc/tree-ssa-threadupdate.c +++ b/gcc/tree-ssa-threadupdate.c @@ -2564,6 +2564,7 @@ thread_through_all_blocks (bool may_peel_loop_headers) FOR_EACH_LOOP (loop, LI_FROM_INNERMOST) { if (!loop->header + || !loop_latch_edge (loop) || !bitmap_bit_p (threaded_blocks, loop->header->index)) continue;