From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2076 invoked by alias); 24 Jun 2008 09:15:05 -0000 Received: (qmail 2029 invoked by uid 22791); 24 Jun 2008 09:15:05 -0000 X-Spam-Check-By: sourceware.org Received: from yx-out-1718.google.com (HELO yx-out-1718.google.com) (74.125.44.153) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 24 Jun 2008 09:14:35 +0000 Received: by yx-out-1718.google.com with SMTP id 36so418770yxh.26 for ; Tue, 24 Jun 2008 02:14:33 -0700 (PDT) Received: by 10.142.82.6 with SMTP id f6mr5132210wfb.43.1214298872544; Tue, 24 Jun 2008 02:14:32 -0700 (PDT) Received: by 10.143.162.1 with HTTP; Tue, 24 Jun 2008 02:14:32 -0700 (PDT) Message-ID: <84fc9c000806240214i38e62c88y75957c6eaaab567d@mail.gmail.com> Date: Tue, 24 Jun 2008 09:32:00 -0000 From: "Richard Guenther" To: "Rafael Espindola" Subject: Re: [lto][patch] remove local variables from types (after gimplification) Cc: gcc-patches , "Diego Novillo" In-Reply-To: <38a0d8450806230743s2e1bdcd9q71b6266b85eef73d@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <38a0d8450806230743s2e1bdcd9q71b6266b85eef73d@mail.gmail.com> X-IsSubscribed: yes 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: 2008-06/txt/msg01481.txt.bz2 On Mon, Jun 23, 2008 at 4:43 PM, Rafael Espindola wrote: > Richard pointed out that changing a pointer to VLA into a normal > pointer would introduce performance regressions on the lto branch. > > Since the memref branch is going to clean things up on this area and > we have to move forward on lto, Diego and I agreed it would be better > to just patch the types before LTO. > > Is the attached patch OK for LTO? I know there will be other places > that expect these fields to be non-NULL, but we can fix them as they > are hit. > > Bootstraping and regression testing it now. This works for me. Note that if either TYPE_SIZE_UNIT or TYPE_SIZE is NULL, both should be. Also the same handling of TYPE_MAX_VALUE should apply to TYPE_MIN_VALUE - and rather than setting them to zero I would suggest to set them to the types natural bounds based on its precision. And it looks like you miss TYPE_DOMAIN of ARRAY_TYPE, which contains the variable bounds of an array. Richard. > 2008-06-23 Rafael Espindola > > * calls.c (must_pass_in_stack_var_size): handle a NULL TYPE_SIZE. > * expr.c (store_field): handle a NULL TYPE_SIZE. > * tree.c (reset_type_lang_specific): set TYPE_SIZE_UNIT, > TYPE_SIZE and TYPE_MAX_VALUE to NULL_TREE if they are not INTEGER_CST. > > Cheers, > -- > Rafael Avila de Espindola > > Google Ireland Ltd. > Gordon House > Barrow Street > Dublin 4 > Ireland > > Registered in Dublin, Ireland > Registration Number: 368047 >