This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Store type in fieldoff_s, not FIELD_DECL


On Mon, Jul 25, 2005 at 03:39:46PM +0200, Richard Guenther wrote:
> 
> This enables us to sft fields without a FIELD_DECL in future
> (aka array elements).  Two parts, actually, to be applied on
> top of each other.
> 
> Bootstrapped and tested on x86_64-unknown-linux-gnu.
> 
> Ok for mainline?
> 
Well, we are in stage3 now.  Are you hoping to fix anything with
this?  It's not absolutely clear to me that we won't need the
FIELD_DECL in the new alias work planned for 4.2.

> *************** create_variable_info_for (tree decl, con
> *** 3127,3140 ****
>   	  const char *newname;
>   	  char *tempname;
>   
> ! 	  field = fo->field;
>   	  newindex = VEC_length (varinfo_t, varmap);
>   	  asprintf (&tempname, "%s.%s", vi->name, alias_get_name (field));
>   	  newname = ggc_strdup (tempname);
>   	  free (tempname);
>   	  newvi = new_var_info (decl, newindex, newname, newindex);
>   	  newvi->offset = fo->offset;
> ! 	  newvi->size = TREE_INT_CST_LOW (DECL_SIZE (field));
>   	  newvi->fullsize = vi->fullsize;
>   	  insert_into_field_list (vi, newvi);
>   	  VEC_safe_push (varinfo_t, heap, varmap, newvi);
> --- 3127,3140 ----
>   	  const char *newname;
>   	  char *tempname;
>   
> ! 	  field = fo->type;
>
You'd have to rename the local variable 'field'.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]