This is the mail archive of the gcc@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: [tree-ssa] a tree-ssa beginner question - creating newvariables


On Tue, 2004-01-06 at 00:54, law@redhat.com wrote:

> You might want to do something like this (see create_tmp):
> 
>   tmp = create_tmp_var (type, name);
>   create_var_ann (tmp);
>   set_is_used (tmp);
>                                                                                
> 
>   /* We have just created a new variable.  Make sure it has a UID and
>      an appropriate memory tag, then put it in REFERENCED_VARS.  */
>   var_ann (tmp)->uid = num_referenced_vars;
>   var_ann (tmp)->mem_tag = var_ann (t)->mem_tag;
>   VARRAY_PUSH_TREE (referenced_vars, tmp);
> 
We have a new function to do all this.  Just do:

	tmp = create_tmp_var (type, name);
	add_referenced_tmp_var (tmp);



Diego.


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