[tree-ssa][ GC, Virtual operands, and GCing between passes
Andrew MacLeod
amacleod@redhat.com
Wed Dec 10 04:46:00 GMT 2003
On Tue, 2003-12-09 at 18:36, Geoff Keating wrote:
> Andrew MacLeod <amacleod@redhat.com> writes:
>
> > Are we sure we want to GC between passes? :-|
> >
> > since VDEFs and VUSEs are tree nodes, I can't allocate the structure
> > which holds them anywhere except GC'd memory can I?
> >
> > ie
> >
> > a_3 = VDEF <a_2>
> >
> > This requires points to 2 trees.
> >
> > the GC system has to know not to collect the trees I am pointing to in
> > the 2 words of the vdef vector.
> >
> > but I dont want to GC the vdef vector.
>
> Why not?
>
Ok, so assuming I do it all in GCable form,
I have array of pointers to trees.
so
tree **defs;
I don't want what defs points to to be marked, since they are marked
otherwise, I just need the defs vector itself collected:
typedef struct def_optype_d GTY(())
{
unsigned num_defs;
tree ** GTY((skip(""))) defs;
} def_optype_t;
If I use skip like this, it doesnt do anything does it? meaning it
doesnt free defs?
typedef struct def_optype_d GTY(())
{
unsigned num_defss;
tree **GTY((length ("%h.num_defs"))) defs;
} vdef_optype_t;
I can tell it how long the vector is but then it claims it doesnt
understand the type "tree **", so it aborts.
Should it look like:
typedef struct def_optype_d GTY(())
{
unsigned num_defs;
tree ** GTY((length ("%h.num_vuses"),skip(""))) defs;
} def_optype_t;
or what do I need to do?
Andrew
More information about the Gcc
mailing list