From patchwork Tue Sep 24 10:34:53 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Richard Biener X-Patchwork-Id: 277427 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 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 48B7B2C00BE for ; Tue, 24 Sep 2013 20:35:03 +1000 (EST) 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:in-reply-to:message-id:references :mime-version:content-type; q=dns; s=default; b=HYhV6isupypykl5A e3ICogt8vdlpDTbOTUIUdzUnTOnbecIRqpg97TJO0FgSZQntdNHOxrR1IhWVBhEZ G7zANOjoHL1sRIaUDBKmFws/6NWVeD2vV7DYsOfy2DewURIDDoUE9vN9p8WyfGDs PbS3aOIPv4qVVTnl/QxjECT+cfU= 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:in-reply-to:message-id:references :mime-version:content-type; s=default; bh=u9pQFSFhAhotMjF2omskkB AZ1xs=; b=oPw9HVEI61nSju+jm+ggjfkny1mAoOFjhTUM28nigmjiwWBw4+A+Kp lqfsbdipRzaXYU/Vz7jG/Eb7fRZO5DneXSlXtwpTkmmtp7rStCaU0AOTrv9qJK6n G8Jyi+KiMFP3BEyEOvoxGYpXblgePBSydqIyleNrucnshxw5e4BLc= Received: (qmail 19581 invoked by alias); 24 Sep 2013 10:34:57 -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 19568 invoked by uid 89); 24 Sep 2013 10:34:57 -0000 Received: from cantor2.suse.de (HELO mx2.suse.de) (195.135.220.15) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Tue, 24 Sep 2013 10:34:57 +0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.1 required=5.0 tests=AWL, BAYES_00, RDNS_NONE autolearn=no version=3.3.2 X-HELO: mx2.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 86D4EA531D; Tue, 24 Sep 2013 12:34:54 +0200 (CEST) Date: Tue, 24 Sep 2013 12:34:53 +0200 (CEST) From: Richard Biener To: Richard Biener Cc: Eric Botcazou , Christophe Lyon , GCC Patches , Kugan , Jakub Jelinek , Ramana Radhakrishnan , Richard Earnshaw Subject: Re: [ping][PATCH][1 of 2] Add value range info to SSA_NAME for zero sign extension elimination in RTL In-Reply-To: Message-ID: References: <1874990.LctCbIxve3@polaris> User-Agent: Alpine 2.00 (LNX 1167 2008-08-23) MIME-Version: 1.0 On Tue, 24 Sep 2013, Richard Biener wrote: > On Mon, Sep 23, 2013 at 10:34 PM, Eric Botcazou wrote: > >> I have committed it for you (rev 202831), with a few modifications > >> (ChangeLog formatting, typos). > >> Here is what I have committed: > >> > >> 2013-09-23 Kugan Vivekanandarajah > >> > >> * gimple-pretty-print.c (dump_ssaname_info): New function. > >> (dump_gimple_phi): Call it. > >> (pp_gimple_stmt_1): Likewise. > >> * tree-core.h (tree_ssa_name): New union ssa_name_info_type field. > >> (range_info_def): Declare. > >> * tree-pretty-print.c (pp_double_int): New function. > >> (dump_generic_node): Call it. > >> * tree-pretty-print.h (pp_double_int): Declare. > >> * tree-ssa-alias.c (dump_alias_info): Check pointer type. > >> * tree-ssanames.h (range_info_def): New structure. > >> (value_range_type): Move definition here. > >> (set_range_info, value_range_type, duplicate_ssa_name_range_info): > >> Declare. > >> * tree-ssanames.c (make_ssa_name_fn): Check pointer type at > >> initialization. > >> (set_range_info): New function. > >> (get_range_info): Likewise. > >> (duplicate_ssa_name_range_info): Likewise. > >> (duplicate_ssa_name_fn): Check pointer type and call > >> duplicate_ssa_name_range_info. > >> * tree-ssa-copy.c (fini_copy_prop): Likewise. > >> * tree-vrp.c (value_range_type): Remove definition, now in > >> tree-ssanames.h. > >> (vrp_finalize): Call set_range_info to update value range of > >> SSA_NAMEs. > >> * tree.h (SSA_NAME_PTR_INFO): Macro changed to access via union. > >> (SSA_NAME_RANGE_INFO): New macro. > > > > Nice patch, but the formatting is totally wrong wrt spaces, please reformat > > using 2-space indentation and 8-space TABs, as already used in the files. > > > > The patch has also introduced 2 regressions in Ada: > > > > === acats tests === > > FAIL: c37211b > > FAIL: c37211c > > > > === acats Summary === > > # of expected passes 2318 > > # of unexpected failures 2 > > > > > > Program received signal SIGSEGV, Segmentation fault. > > vrp_finalize () at /home/eric/svn/gcc/gcc/tree-vrp.c:9458 > > 9458 if (POINTER_TYPE_P (TREE_TYPE (name)) > > (gdb) bt > > I'm testing a trivial patch to fix that. Bootstrapped and tested on x86_64-unknown-linux-gnu, applied. Richard. 2013-09-24 Richard Biener * tree-vrp.c (vrp_finalize): Check for SSA name presence. Index: gcc/tree-vrp.c =================================================================== --- gcc/tree-vrp.c (revision 202860) +++ gcc/tree-vrp.c (working copy) @@ -9455,7 +9455,8 @@ vrp_finalize (void) { tree name = ssa_name (i); - if (POINTER_TYPE_P (TREE_TYPE (name)) + if (!name + || POINTER_TYPE_P (TREE_TYPE (name)) || (vr_value[i]->type == VR_VARYING) || (vr_value[i]->type == VR_UNDEFINED)) continue;