Re: [patch] Stop gengtype from emitting empty loops

2012-07-24 Thread Richard Guenther
On Tue, Jul 24, 2012 at 11:31 AM, Laurynas Biveinis laurynas.bivei...@gmail.com wrote: For scalar fields or skipped fields, gengtype produces empty loops. This patch checks for that case and breaks out if an empty loop body is detected: Bootstrappedtested on powerpc64-unknown-linux-gnu. OK?

Re: [patch] Stop gengtype from emitting empty loops

2012-07-24 Thread Laurynas Biveinis
I think it merely points to a bogus GTY annotation, not sure if we want to gobble this kind of gengtype hacks which only benefit -O0 ... The annotation is libcpp/include/line-map.h In the example above x1 (for token +) is going to be the same as y1. x0 is the spelling location

Re: [patch] Stop gengtype from emitting empty loops

2012-07-24 Thread Steven Bosscher
On Tue, Jul 24, 2012 at 12:11 PM, Laurynas Biveinis laurynas.bivei...@gmail.com wrote: I think it merely points to a bogus GTY annotation, not sure if we want to gobble this kind of gengtype hacks which only benefit -O0 ... The annotation is libcpp/include/line-map.h In the example

Re: [patch] Stop gengtype from emitting empty loops

2012-07-24 Thread Laurynas Biveinis
2012/7/24 Steven Bosscher stevenb@gmail.com: On Tue, Jul 24, 2012 at 12:11 PM, Laurynas Biveinis laurynas.bivei...@gmail.com wrote: I think it merely points to a bogus GTY annotation, not sure if we want to gobble this kind of gengtype hacks which only benefit -O0 ... This one indeed

Re: [patch] Stop gengtype from emitting empty loops

2012-07-24 Thread Laurynas Biveinis
I think it merely points to a bogus GTY annotation, not sure if we want to gobble this kind of gengtype hacks which only benefit -O0 ... ../../trunk/gcc/../libcpp/include/line-map.h:168: option `length' may not be applied to arrays of scalar types ../../trunk/gcc/emit-rtl.c:5913: option

Re: [patch] Stop gengtype from emitting empty loops

2012-07-24 Thread Steven Bosscher
On Tue, Jul 24, 2012 at 5:20 PM, Laurynas Biveinis laurynas.bivei...@gmail.com wrote: s/arrays of scalar types/arrays of atomic types, add a ChangeLog entry and the snippet above is approved ;) Can you commit it along with your fixes? I think it'd be good to keep this and your fixes together in

Re: [patch] Stop gengtype from emitting empty loops

2012-07-24 Thread Tom Tromey
Laurynas == Laurynas Biveinis laurynas.bivei...@gmail.com writes: Laurynas 2012-06-24 Laurynas Bivienis laurynas.bivei...@gmail.com Laurynas * include/line-map.h (line_map_macro): Use the atomic GTY option Laurynas for the macro_locations field. Laurynas gcc/java: Laurynas

Re: [patch] Stop gengtype from emitting empty loops

2012-07-24 Thread Laurynas Biveinis
s/arrays of scalar types/arrays of atomic types, add a ChangeLog entry and the snippet above is approved ;) Can you commit it along with your fixes? I think it'd be good to keep this and your fixes together in a single commit. OK -- Laurynas