This is the mail archive of the 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: Trivial speedup to aliasing

> On Jan 11, 2004, at 7:21 PM, Jan Hubicka wrote:
> >
> >Hi,
> >about 3% of Gerald's application compile time is consumed by splay 
> >tree walking
> >that comes from aliasing.  It seems to me that it is safe to replace 
> >this by
> >trivial varray as alias sets are always allocated consetuctively.  
> >With this
> >patch I can save almost all the overhead and get the lookup off the 
> >profiles.
> >I also measured 2 seconds out of 2 minutes GCC component compile time 
> >but it
> >may be noise.
> >
> >I noticed that varray.c requires GENERIC_PTR to be in GGC memory.  
> >This looks
> >wrong to me that when we do GGC we need to know the type anyway.
> This is what GTY ((param_is ("<typename>"))) is for.

Hmm, Zdenek noticed that too :)

> There are VARRAY_GENERIC arrays with ggc'd things in them that need to 
> be marked, so don't do this.
> We added a noggc counterpart on the tree-ssa branch.
> Personally, I don't like that generic_ptr is ggc_alloc'd either, but 
> unless you fix all the GTY'd generic varrays that need to be marked, 
> you can't do this.
Are there any to fix?

ibm:~/gcc5/gcc/gcc # find . -type f | xargs grep GENERIC_PTR
./ChangeLog.2:  * c-decl.c (field_decl_cmp): Use PTR instead of GENERIC_PTR.
./ChangeLog.2:  * varray.h (varray_data_tag, VARRAY_GENERIC_PTR_INIT): Likewise.
./ChangeLog.6:  * varray.h (VARRAY_TOP_GENERIC_PTR): Remove spurious parameter.
./FSFChangeLog.11:      (GENERIC_PTR,NULL_PTR,P_tmpdir): Delete.
./FSFChangeLog.11:      (NULL,GENERIC_PTR,NULL_PTR): Delete.
./alias.c:  return (alias_set_entry)VARRAY_GENERIC_PTR (alias_sets, alias_set);
./alias.c:      VARRAY_GENERIC_PTR (alias_sets, superset) = superset_entry;
./alias.c:  VARRAY_GENERIC_PTR_INIT (alias_sets, 10, "alias sets");
./genautomata.c:      VARRAY_GENERIC_PTR_INIT (_vla_ptr->varray, allocated_length, name);\
./genautomata.c:#define VLA_PTR_BEGIN(vla) ((void *) &VARRAY_GENERIC_PTR ((vla).varray, 0))
./genautomata.c:#define VLA_PTR_LAST(vla) (&VARRAY_GENERIC_PTR ((vla).varray,         \
./genautomata.c:    VARRAY_GENERIC_PTR (_vla_ptr->varray, _vla_ptr->length - 1) = (ptr);\
./genautomata.c:#define VLA_PTR(vla, n) VARRAY_GENERIC_PTR ((vla).varray, n)
./varray.h:#define VARRAY_GENERIC_PTR_INIT(va, num, name) \
./varray.h:#define VARRAY_GENERIC_PTR(VA,N)     VARRAY_CHECK (VA, N, generic)
./varray.h:#define VARRAY_PUSH_GENERIC_PTR(VA, X)       VARRAY_PUSH (VA, generic, X)
./varray.h:#define VARRAY_TOP_GENERIC_PTR(VA)   VARRAY_TOP (VA, generic)

But merging back nogcc counterpart from tree-ssa would make me happy


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