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] Move loop structures to gc memory


On May 15, 2007, at 2:49 PM, Ian Lance Taylor wrote:
No, for example, we could enhance the GTY markings to say "this field
in cfun points to a linked list of structs, linked by this field.

But, you can already do that.


For each instance of the struct, these fields in the struct point into GC
memory."

And this.


Then a list of, e.g., loop structs would automatically become GC roots with no additional work required.

And this.


? Now I am confused again. :-)

my_data {
	my_data *next;
	char *otherfied ((GTY("skip")));
};

struct cfun_t GTY(()) {
	my_data *next;
	bla otherdata;
} *cfun;

?


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