This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH: PR middle-end/40147: Memory leak in revision 147436
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Jan Hubicka <hubicka at ucw dot cz>
- Cc: "H.J. Lu" <hjl dot tools at gmail dot com>, gcc-patches at gcc dot gnu dot org
- Date: Thu, 14 May 2009 17:18:51 +0200
- Subject: Re: PATCH: PR middle-end/40147: Memory leak in revision 147436
- References: <20090514143354.GA6643@lucon.org> <20090514151400.GA5414@atrey.karlin.mff.cuni.cz>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Thu, May 14, 2009 at 05:14:00PM +0200, Jan Hubicka wrote:
> > We have a memory leark since memory_identifier_string isn't marked with
> > GTY(()). OK for trunk and 4.3/4.4 branches?
>
> OK, thanks
Do you need GTY(()) markers in both places? AFAIK you need it either
in the header on the extern decl and in that case not on the definition
in the .c file, or you don't put an extern decl in a header, add GTY(())
marker to the local definition and ensure the .c file is scanner for GC (add
gt-* include at the end of the file, add it to the makefile list).
Jakub