Re: [cxx-conversion] Add Record Builder Class

2013-02-18 Thread Nathan Sidwell
On 02/12/13 19:47, Lawrence Crowl wrote: Add class record_builder to ease construction of records and unions. Use it in some appropriate places. Nathan please review the vxworks changes. config/vxworks.c Replace vxworks_emutls_var_fields() with vxworks_emutls_object_type().

Re: [cxx-conversion] Add Record Builder Class

2013-02-15 Thread Richard Biener
On Thu, Feb 14, 2013 at 8:44 PM, Lawrence Crowl cr...@google.com wrote: On 2/14/13, Richard Biener richard.guent...@gmail.com wrote: On Tue, Feb 12, 2013 at 8:47 PM, Lawrence Crowl cr...@google.com wrote: Add class record_builder to ease construction of records and unions. Use it in some

Re: [cxx-conversion] Add Record Builder Class

2013-02-15 Thread Gabriel Dos Reis
On Fri, Feb 15, 2013 at 3:04 AM, Richard Biener richard.guent...@gmail.com wrote: Note that there is no such thing as a middle-end or back-end type. but we do conceptually have them. -- Gaby

Re: [cxx-conversion] Add Record Builder Class

2013-02-14 Thread Richard Biener
On Tue, Feb 12, 2013 at 8:47 PM, Lawrence Crowl cr...@google.com wrote: Add class record_builder to ease construction of records and unions. Use it in some appropriate places. Nathan please review the vxworks changes. tree.h New class record_builder. tree.c Implement

Re: [cxx-conversion] Add Record Builder Class

2013-02-14 Thread Diego Novillo
On Thu, Feb 14, 2013 at 4:26 AM, Richard Biener richard.guent...@gmail.com wrote: Note that tag_name does not allow the way C++ uses this (it can be a TYPE_DECL). Overall I'm not sure this is a good abstraction unless you manage to make the frontends use it. I think that is a mistake. This

Re: [cxx-conversion] Add Record Builder Class

2013-02-14 Thread Richard Biener
On Thu, Feb 14, 2013 at 12:56 PM, Diego Novillo dnovi...@google.com wrote: On Thu, Feb 14, 2013 at 4:26 AM, Richard Biener richard.guent...@gmail.com wrote: Note that tag_name does not allow the way C++ uses this (it can be a TYPE_DECL). Overall I'm not sure this is a good abstraction

Re: [cxx-conversion] Add Record Builder Class

2013-02-14 Thread Diego Novillo
On Thu, Feb 14, 2013 at 7:52 AM, Richard Biener richard.guent...@gmail.com wrote: Because it's otherwise almost unused. No usual gimple pass builds up record types. What's the point in introducing the abstraction if most of the users cannot use it? There may be few users on the gimple side,

Re: [cxx-conversion] Add Record Builder Class

2013-02-14 Thread Richard Biener
On Thu, Feb 14, 2013 at 2:01 PM, Diego Novillo dnovi...@google.com wrote: On Thu, Feb 14, 2013 at 7:52 AM, Richard Biener richard.guent...@gmail.com wrote: Because it's otherwise almost unused. No usual gimple pass builds up record types. What's the point in introducing the abstraction if

Re: [cxx-conversion] Add Record Builder Class

2013-02-14 Thread Diego Novillo
On Thu, Feb 14, 2013 at 8:06 AM, Richard Biener richard.guent...@gmail.com wrote: On Thu, Feb 14, 2013 at 2:01 PM, Diego Novillo dnovi...@google.com wrote: On Thu, Feb 14, 2013 at 7:52 AM, Richard Biener richard.guent...@gmail.com wrote: Because it's otherwise almost unused. No usual gimple

Re: [cxx-conversion] Add Record Builder Class

2013-02-14 Thread Lawrence Crowl
On 2/14/13, Richard Biener richard.guent...@gmail.com wrote: On Tue, Feb 12, 2013 at 8:47 PM, Lawrence Crowl cr...@google.com wrote: Add class record_builder to ease construction of records and unions. Use it in some appropriate places. tree -default_emutls_var_fields (tree type,

Re: [cxx-conversion] Add Record Builder Class

2013-02-13 Thread Diego Novillo
On Tue, Feb 12, 2013 at 2:47 PM, Lawrence Crowl cr...@google.com wrote: @@ -182,24 +163,9 @@ default_emutls_var_init (tree to, tree d static tree get_emutls_object_type (void) { - tree type, type_name, field; - - type = emutls_object_type; - if (type) -return type; - -

Re: [cxx-conversion] Add Record Builder Class

2013-02-13 Thread Lawrence Crowl
On 2/13/13, Diego Novillo dnovi...@google.com wrote: On Tue, Feb 12, 2013 at 2:47 PM, Lawrence Crowl cr...@google.com wrote: @@ -182,24 +163,9 @@ default_emutls_var_init (tree to, tree d static tree get_emutls_object_type (void) { - tree type, type_name, field; - - type =

Re: [cxx-conversion] Add Record Builder Class

2013-02-13 Thread Diego Novillo
Thanks. The patch is OK for the branch. You can address Nathan's review after he's back and gets a chance to look at it. Let me know when the patch is in. I've got another merge in process. Diego.

Re: [cxx-conversion] Add Record Builder Class

2013-02-13 Thread Lawrence Crowl
On 2/13/13, Diego Novillo dnovi...@google.com wrote: Thanks. The patch is OK for the branch. You can address Nathan's review after he's back and gets a chance to look at it. Let me know when the patch is in. I've got another merge in process. Committed. -- Lawrence Crowl

[cxx-conversion] Add Record Builder Class

2013-02-12 Thread Lawrence Crowl
Add class record_builder to ease construction of records and unions. Use it in some appropriate places. Nathan please review the vxworks changes. tree.h New class record_builder. tree.c Implement record_builder member functions. asan.c Change asan_global_struct to use