Re: [PATCH] Fix bootstrap with -O3

2013-02-12 Thread Marek Polacek
On Sun, Feb 10, 2013 at 12:29:41AM +0100, Marc Glisse wrote:
 2013-02-07  Marek Polacek  pola...@redhat.com
 
  * c-parser.c (origtypes): Initialize to NULL.
 
 Maybe mention PR44938? (there may be a dup or two)

Ok, I added that.

 (I thought it was the name of the function that went inside the
 parentheses in a ChangeLog entry)

That's right, so I used something hopefully better this time around ;)
Ok for trunk now?

2013-02-12  Marek Polacek  pola...@redhat.com

PR c/44938
* c-parser.c (c_parser_postfix_expression_after_primar): Initialize
origtypes to NULL.

--- gcc/c-parser.c.mp   2013-02-07 17:50:10.286742403 +0100
+++ gcc/c-parser.c  2013-02-07 17:50:23.331781876 +0100
@@ -6864,7 +6864,7 @@ c_parser_postfix_expression_after_primar
   tree sizeof_arg[3];
   unsigned int i;
   vectree, va_gc *exprlist;
-  vectree, va_gc *origtypes;
+  vectree, va_gc *origtypes = NULL;
   while (true)
 {
   location_t op_loc = c_parser_peek_token (parser)-location;

Marek


Re: [PATCH] Fix bootstrap with -O3

2013-02-12 Thread Jakub Jelinek
On Tue, Feb 12, 2013 at 08:26:37PM +0100, Marek Polacek wrote:
 That's right, so I used something hopefully better this time around ;)
 Ok for trunk now?
 
 2013-02-12  Marek Polacek  pola...@redhat.com
 
   PR c/44938
   * c-parser.c (c_parser_postfix_expression_after_primar): Initialize

The function is called c_parser_postfix_expression_after_primary,
not c_parser_postfix_expression_after_primar, that is just diff truncating
too long names; please fix that up.

   origtypes to NULL.

Ok, thanks.

 --- gcc/c-parser.c.mp 2013-02-07 17:50:10.286742403 +0100
 +++ gcc/c-parser.c2013-02-07 17:50:23.331781876 +0100
 @@ -6864,7 +6864,7 @@ c_parser_postfix_expression_after_primar
tree sizeof_arg[3];
unsigned int i;
vectree, va_gc *exprlist;
 -  vectree, va_gc *origtypes;
 +  vectree, va_gc *origtypes = NULL;
while (true)
  {
location_t op_loc = c_parser_peek_token (parser)-location;
 
   Marek

Jakub


Re: [PATCH] Fix bootstrap with -O3

2013-02-12 Thread Marek Polacek
On Tue, Feb 12, 2013 at 08:52:27PM +0100, Jakub Jelinek wrote:
 On Tue, Feb 12, 2013 at 08:26:37PM +0100, Marek Polacek wrote:
  That's right, so I used something hopefully better this time around ;)
  Ok for trunk now?
  
  2013-02-12  Marek Polacek  pola...@redhat.com
  
  PR c/44938
  * c-parser.c (c_parser_postfix_expression_after_primar): Initialize
 
 The function is called c_parser_postfix_expression_after_primary,
 not c_parser_postfix_expression_after_primar, that is just diff truncating
 too long names; please fix that up.

Thanks for noticing, I used auto-completing of words...
I'll fix it up and commit.

Marek


Re: [PATCH] Fix bootstrap with -O3

2013-02-12 Thread Alec Teal

On 12/02/13 19:59, Marek Polacek wrote:


Thanks for noticing, I used auto-completing of words...
I'll fix it up and commit.

Marek


Why did this occur? I am curious.

Alec



Re: [PATCH] Fix bootstrap with -O3

2013-02-12 Thread Marek Polacek
On Tue, Feb 12, 2013 at 08:21:06PM +, Alec Teal wrote:
 Why did this occur? I am curious.

It is caused by -fipa-cp-clone, which -O3 entails.

Marek


Re: [PATCH] Fix bootstrap with -O3

2013-02-09 Thread Marc Glisse

On Thu, 7 Feb 2013, Marek Polacek wrote:


When bootstrapping with BOOT_FLAGS='-O3 -g', I get:
/home/polacek/src/gcc/gcc/c/c-parser.c: In function ‘c_expr 
c_parser_postfix_expression_after_primary(c_parser*, location_t, c_expr)’:
/home/polacek/src/gcc/gcc/c/c-parser.c:6908:16: error: ‘origtypes’ may be used 
uninitialized in this function [-Werror=maybe-uninitialized]
So this patch explicitly initializes origtypes to NULL.

Regtested/bootstrapped (with BOOT_FLAGS='-O3 -g') on x86_64-linux,
ok for trunk?

2013-02-07  Marek Polacek  pola...@redhat.com

* c-parser.c (origtypes): Initialize to NULL.


Maybe mention PR44938? (there may be a dup or two)

(I thought it was the name of the function that went inside the 
parentheses in a ChangeLog entry)


--
Marc Glisse