This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Question on GGC
- From: "吴曦" <wu dot andrew dot xi at gmail dot com>
- To: gcc <gcc at gcc dot gnu dot org>
- Date: Thu, 27 Sep 2007 23:31:41 +0800
- Subject: Question on GGC
Hi.
I have several global variables which are of type rtx. They are used
in flow.c ia64.c and final.c. As stated in the internal doc with
types. I add GTY(()) marker after the keyword 'extern'. for example:
extern GTY(()) rtx a;
these 'extern's are added in regs.h which is included in flow.c ia64.c
and final.c
However, I init 'a' at ia64_compute_frame which is defined in ia64.c
but found 'a' incorrectly collected by ggc_collect. (I watch the
memory location which is allocated for a, and found it is collected by
GGC.
Is there any thing I forget to do ?
Any help is truly appreciated
Thanks :-)