From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16788 invoked by alias); 17 Jul 2012 07:52:40 -0000 Received: (qmail 16763 invoked by uid 22791); 17 Jul 2012 07:52:39 -0000 X-SWARE-Spam-Status: No, hits=-4.1 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,KHOP_RCVD_TRUST,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE X-Spam-Check-By: sourceware.org Received: from mail-wi0-f173.google.com (HELO mail-wi0-f173.google.com) (209.85.212.173) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Tue, 17 Jul 2012 07:52:24 +0000 Received: by wibhm6 with SMTP id hm6so2914420wib.8 for ; Tue, 17 Jul 2012 00:52:23 -0700 (PDT) Received: by 10.180.100.136 with SMTP id ey8mr1869741wib.15.1342511543536; Tue, 17 Jul 2012 00:52:23 -0700 (PDT) Received: from s42.loc (91-119-115-225.dynamic.xdsl-line.inode.at. [91.119.115.225]) by mx.google.com with ESMTPS id ef5sm38150496wib.3.2012.07.17.00.52.22 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 17 Jul 2012 00:52:22 -0700 (PDT) Received: from cow by s42.loc with local (Exim 4.80) (envelope-from ) id 1Sr2Zx-0001Ga-9B; Tue, 17 Jul 2012 09:52:21 +0200 Date: Tue, 17 Jul 2012 07:52:00 -0000 From: Bernhard Reutner-Fischer To: Sandeep Soni Cc: gcc patches , Diego Novillo Subject: Re: [gimplefe] Construction of individual gimple statements for gimple_cond and gimple_label Message-ID: <20120717075221.GA4773@mx.loc> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) 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: 2012-07/txt/msg00697.txt.bz2 On Wed, Jul 11, 2012 at 10:51:02AM +0530, Sandeep Soni wrote: >The patch adds support for creating individual gimple statements for >the gimple_cond and gimple_label statements. > >Diego, I need your help in generalizing to include all possible cases >of these statements. > >Here is the ChangeLog > >2012-07-10 Sandeep Soni > > * parser.c (gp_parse_expect_op1): Tidy. Returns tree operand. > Update all callers. > (gp_parse_expect_op2): Likewise. > (gp_parse_expect_true_label): Tidy. Returns a label. > Update all callers. > (gp_parse_expect_false_label): Likewise. > (gp_parse_cond_stmt): Tidy. Creates and returns a gimple cond > statement. > (gp_parse_label_stmt): Creates and returns the gimple label statement. > > >And the patch >Index: gcc/gimple/parser.c >=================================================================== >--- gcc/gimple/parser.c (revision 188546) >+++ gcc/gimple/parser.c (working copy) > >-static void >+static tree > gp_parse_expect_op1 (gimple_parser *parser) > { > const gimple_token *next_token; > next_token = gl_consume_token (parser->lexer); >+ tree op1 = NULL_TREE; I'm curious if the coding conventions were relaxed to allow for variable declarations that are not at the beginning of a function or scope? You seem to do this pretty often in the gimplefe.. cheers,