Hi, On Wed, 13 Mar 2013, Diego Novillo wrote:
> To use the builder: > > 1- Declare an instance 'gb' of gimple_builder_normal or > gimple_builder_ssa. E.g., gimple_builder_ssa gb; > > 2- Use gb.add_* to add a new statement to it. This > returns an SSA name or VAR_DECL with the value of the added > statement. > > 3- Call gb.insert_*() to insert the sequence of statements in the > builder into a statement iterator. I'm reiterating everything I said in http://gcc.gnu.org/ml/gcc/2012-11/msg00230.html Actually your interface now is worse than what Lawrence proposed back in November in that the add_* methods return a tree, instead of a gimple statement. I haven't seen any convincing reason why the builder class is necessary, instead of improving the current interface. IOW I don't like it much. Ciao, Michael.