[gimplefe] Patch for recognizing function declarations

2012-07-31 Thread Sandeep Soni
Hi Diego, The following patch recognizes function declarations. I am now trying to create a gimple sequence of all the statements within the function body. The chagelog is as follows: 2012-07-31 Sandeep Soni * parser.c (gl_token_starts_decl): Modify. Matches function decls

Re: [gimplefe] Construction of individual gimple statements for gimple_cond and gimple_label

2012-07-17 Thread Sandeep Soni
On Tue, Jul 17, 2012 at 6:16 PM, Diego Novillo wrote: > > Not so much, anymore > (http://gcc.gnu.org/codingconventions.html#Variable). When gimplefe > is merged into trunk, we will be using the C++ conventions which now > allow this. > > No need to change anything, Sandy. Ah..Saved by the skin

Re: [gimplefe] Construction of individual gimple statements for gimple_cond and gimple_label

2012-07-17 Thread Sandeep Soni
On Tue, Jul 17, 2012 at 1:22 PM, Bernhard Reutner-Fischer wrote: > > 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, Not really. I guess

Re: [gimplefe] Fixing the bug for gimple_assign statement with ternary operands

2012-07-10 Thread Sandeep Soni
On Fri, Jul 6, 2012 at 7:26 PM, Diego Novillo wrote: > On 12-07-06 00:38 , Sandeep Soni wrote: > >> I am halfway through the patch for building gimple_cond statements. I >> will be able to complete the patch over the weekend. I am also working >> towards a patch that ge

[gimplefe] Construction of individual gimple statements for gimple_cond and gimple_label

2012-07-10 Thread Sandeep Soni
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

[gimplefe] Fixing the bug for gimple_assign statement with ternary operands

2012-07-05 Thread Sandeep Soni
complete the patch over the weekend. I am also working towards a patch that generalizes the assignment statements considering all possible types of assignments. Tested on x86. ChangeLog as follows: 2012-06-06 Sandeep Soni * parser.c (gp_parse_expect_rhs_op): Tidy. Returns the tree

Re: [gimplefe] creating individual gimple_assign statements

2012-06-23 Thread Sandeep Soni
On Thu, Jun 21, 2012 at 11:33 AM, Diego Novillo wrote: > On 12-06-20 23:04 , Sandeep Soni wrote: >> >> Hi, >> >> This patch creates basic gimple_assign statements. It is a little raw >> not considering all types of gimple_assign statements for which I have >&

[gimplefe] creating individual gimple_assign statements

2012-06-20 Thread Sandeep Soni
Hi, This patch creates basic gimple_assign statements. It is a little raw not considering all types of gimple_assign statements for which I have already started working. Here is the Changelog. 2012-06-09 Sandeep Soni * parser.c (gimple_symtab_get): New

[gimplefe] Tests for type declarations and variable declarations

2012-06-12 Thread Sandeep Soni
The patch adds some preliminary tests for type declarations and varaible declarations for the gimple front end. Following is the ChangeLog Entry. 2012-06-12 Sandeep Soni gimple.dg/20120611-1.gimple : New. gimple.dg/20120611-2.gimple : New. gimple.dg/20120611-3.gimple

Re: [gimplefe] patch that fixes the bug for the failure test case

2012-06-12 Thread Sandeep Soni
On Tue, Jun 12, 2012 at 6:57 PM, Diego Novillo wrote: > On 12-06-08 22:25 , Sandeep Soni wrote: >> >> Hi, >> >> This patch fixes the failure test case that I had submitted the last time. >> >> The changeLog is testsuite/gChangeLog.gimplefe is as f

[gimplefe] patch that fixes the bug for the failure test case

2012-06-08 Thread Sandeep Soni
Hi, This patch fixes the failure test case that I had submitted the last time. The changeLog is testsuite/gChangeLog.gimplefe is as follows. 2012-06-09 Sandeep Soni * gimple.dg/20120605-2.gimple : New. While the changelog in gimple/ChangeLog is as follows 2012-06-09 Sandeep

[gimplefe] Adding more preliminary tests

2012-06-04 Thread Sandeep Soni
`/home/sandeep/gimple_build/gcc' Here is the changeLog.in testsuite/ChangeLog.gimplefe 2012-06-05 Sandeep Soni *gimple.dg/20120604-1.gimple : New. *gimple.dg/20120604-2.gimple : New. *gimple.dg/20120605-1.gimple: New. *gimple.dg/20120605-2.gimple: New.

Re: [gimplefe] Fix parsing of assign_stmt (issue6247046)

2012-05-27 Thread Sandeep Soni
On Fri, May 25, 2012 at 8:34 PM, Diego Novillo wrote: > Fix parser initialization and parsing of gimple_assign. > > This patch fixes the parser to use the new line map table > initialization code. It was not setting the allocation function > pointers properly. > > Additionally, we were only expect

Re: [gimplefe] [patch] splits cpp_lshift and cpp_rshift tokens into discrete cpp_less and cpp_greater tokens respectively

2012-03-14 Thread Sandeep Soni
On Tue, Mar 13, 2012 at 9:42 PM, Diego Novillo wrote: > On 08/03/12 20:47 , Sandeep Soni wrote: > >> +/* Splits the token TOKEN into two tokens FIRST_TOKEN and SECOND_TOKEN. >> +   Note that the split should work only if the type of the TOKEN is >> +   either CPP_RSHIFT

[gimplefe] [patch] splits cpp_lshift and cpp_rshift tokens into discrete cpp_less and cpp_greater tokens respectively

2012-03-08 Thread Sandeep Soni
Hi, The current patch splits cpp_lshift and cpp_rshift tokens into cpp_less and cpp_greater tokens respectively.The necessary changes due to this are made throughout the parser. The changelog is as follows. Up for review. 2012-03-08 Sandeep Soni * parser.c (gl_lex_token): For every

Re: [gimplefe][patch] The symbol table for declarations

2012-03-01 Thread Sandeep Soni
On Wed, Feb 29, 2012 at 8:14 PM, Diego Novillo wrote: > On 24/02/12 01:03 , Sandeep Soni wrote: > >> +  name_token = gl_consume_expected_token (parser->lexer, CPP_NAME); >> +  name = gl_token_as_text (name_token); >> + >> +  e = ggc_alloc_cleared_gimple

Re: [gimplefe][patch] The symbol table for declarations

2012-02-23 Thread Sandeep Soni
On Wed, Nov 30, 2011 at 9:48 AM, Sandeep Soni wrote: > Sorry. Wrong patch. New patch attached. > > I am getting the following error in the new patch though. > > ../../gimple-front-end/gcc/gimple/parser.c: In function ‘gp_parse_var_decl’: > ../../gimple-front-end/gcc/gimple/par

Re: [gimplefe][patch] The symbol table for declarations

2011-11-29 Thread Sandeep Soni
Sorry. Wrong patch. New patch attached. I am getting the following error in the new patch though. ../../gimple-front-end/gcc/gimple/parser.c: In function ‘gp_parse_var_decl’: ../../gimple-front-end/gcc/gimple/parser.c:927:3: error: implicit declaration of function ‘ggc_alloc_cleared_gimple_symtab

[gimplefe][patch] The symbol table for declarations

2011-11-17 Thread Sandeep Soni
On Wed, Oct 12, 2011 at 7:01 PM, Diego Novillo wrote: > > On 11-10-10 17:47 , Sandeep Soni wrote: >> >> Hi, >> The following patch is a basic attempt to build a symbol table that >> stores the names of all the declarations made in the input file. &g

[gimplefe][patch] The symbol table for declarations

2011-10-10 Thread Sandeep Soni
rser->lexer->filename == NULL) return; + gimple_symtab = +htab_create_ggc (1021, gimple_symtab_entry_hash, +gimple_symtab_eq_hash, NULL); gl_lex (parser->lexer); gp_parse (parser); gp_finish (parser); The changelog is as follows: 2011-10-11 Sandeep Soni *

[gimplefe][patch] A bugfix for a missed symbol

2011-10-10 Thread Sandeep Soni
: + gl_consume_expected_token (parser->lexer, CPP_LESS); gl_consume_expected_token (parser->lexer, CPP_NUMBER); gl_consume_expected_token (parser->lexer, CPP_RSHIFT); break; The changelog is: 2011-10-11 Sandeep Soni * parser.c (gp_parse_var_decl): Fixed a bu

Re: [patch][gimplefe] Preliminary variable declaration support

2011-05-12 Thread Sandeep Soni
On Wed, May 11, 2011 at 1:19 AM, Diego Novillo wrote: > > Please add a ChangeLog entry.  OK with that change. Committed after adding the ChangeLog entry. -- Cheers Sandy

[patch][gimplefe] Preliminary variable declaration support

2011-05-09 Thread Sandeep Soni
This patch is just a slight modification to an earlier patch that I submitted which was non-working. This is working. It just recognizes variable declarations and might be helpful for ketaki to start with things. It is now more or less up to date with the information on the wiki although not exactl