From patchwork Wed Jul 20 20:07:40 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Eager X-Patchwork-Id: 105807 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]) by ozlabs.org (Postfix) with SMTP id 82304B6F68 for ; Thu, 21 Jul 2011 06:08:31 +1000 (EST) Received: (qmail 4831 invoked by alias); 20 Jul 2011 20:08:28 -0000 Received: (qmail 4821 invoked by uid 22791); 20 Jul 2011 20:08:25 -0000 X-SWARE-Spam-Status: No, hits=-1.5 required=5.0 tests=AWL, BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, RCVD_IN_DNSWL_NONE, TW_XF X-Spam-Check-By: sourceware.org Received: from caibbdcaaaaf.dreamhost.com (HELO homiemail-a40.g.dreamhost.com) (208.113.200.5) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 20 Jul 2011 20:07:41 +0000 Received: from homiemail-a40.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a40.g.dreamhost.com (Postfix) with ESMTP id 3F07974C064; Wed, 20 Jul 2011 13:07:41 -0700 (PDT) Received: from redwood.eagercon.com (c-76-102-3-160.hsd1.ca.comcast.net [76.102.3.160]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: eager@eagerm.com) by homiemail-a40.g.dreamhost.com (Postfix) with ESMTPSA id EC2B474C057; Wed, 20 Jul 2011 13:07:40 -0700 (PDT) Message-ID: <4E27358C.7050109@eagerm.com> Date: Wed, 20 Jul 2011 13:07:40 -0700 From: Michael Eager User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.18) Gecko/20110621 Fedora/3.1.11-1.fc15 Thunderbird/3.1.11 MIME-Version: 1.0 To: Alexandre Oliva CC: Bernd Schmidt , gcc-patches@gcc.gnu.org, Jakub Jelinek Subject: Re: introduce --param max-vartrack-expr-depth References: <4DE3784F.6050201@codesourcery.com> In-Reply-To: X-IsSubscribed: yes 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 On 05/31/2011 09:13 AM, Alexandre Oliva wrote: > On May 30, 2011, Bernd Schmidt wrote: > >> On 05/30/2011 12:35 PM, Alexandre Oliva wrote: >>> One of my patches for PR 48866 regressed guality/asm-1.c on >>> x86_64-linux-gnu because what used to be a single complex debug value >>> expression became a chain of debug temps holding simpler expressions, >>> and this chain exceeded the default recursion depth in resolving >>> location expressions. > >> What's the worst that can happen if you remove the limit altogether? > > Exponential behavior comes to mind. I will try a bootstrap with a very > high value, but for pathological cases we'd probably still need the > param anyway, so I'll check it in. Thanks for the reviews. I've run into a problem with this change when building microblaze-xilinx-elf. When compiling _divdi3.o, cselib_expand_value_rtx_1 returns a huge rtx tree for variable _r1 when max_depth is greater than 17. If -g is specified, this later results in attempting to generate a DWARF location list much larger than the 0xffff size limit, resulting in an assert failure. Changelog: 2011-07-20 Michael Eager * params.def (PARAM_MAX_VARTRACK_EXPR_DEPTH): Default to 10. 1960 Park Blvd., Palo Alto, CA 94306 650-325-8077 Index: gcc/params.def =================================================================== --- gcc/params.def (revision 176533) +++ gcc/params.def (working copy) @@ -845,7 +845,7 @@ DEFPARAM (PARAM_MAX_VARTRACK_EXPR_DEPTH, "max-vartrack-expr-depth", "Max. recursion depth for expanding var tracking expressions", - 20, 0, 0) + 10, 0, 0) -- Michael Eager eager@eagercon.com