From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17318 invoked by alias); 21 Apr 2014 10:12:54 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 17299 invoked by uid 48); 21 Apr 2014 10:12:50 -0000 From: "alberto.ramos at desy dot de" To: gcc-bugs@gcc.gnu.org Subject: [Bug fortran/60913] New: Memory leak with deferred operators Date: Mon, 21 Apr 2014 10:12:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: fortran X-Bugzilla-Version: unknown X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: alberto.ramos at desy dot de X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version bug_status bug_severity priority component assigned_to reporter attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-04/txt/msg01425.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60913 Bug ID: 60913 Summary: Memory leak with deferred operators Product: gcc Version: unknown Status: UNCONFIRMED Severity: normal Priority: P3 Component: fortran Assignee: unassigned at gcc dot gnu.org Reporter: alberto.ramos at desy dot de Created attachment 32648 --> http://gcc.gnu.org/bugzilla/attachment.cgi?id=32648&action=edit Module with an overloaded operator with a deferred routine When overloading an operator with a deferred procedure, gfortran leaks (i.e. seem that does not free) memory. I attach an example code that leaks around 60KB in my system with the following compilers: GNU Fortran (FreeBSD Ports Collection) 4.6.4 Copyright (C) 2011 Free Software Foundation, Inc. GNU Fortran (FreeBSD Ports Collection) 4.8.3 20140220 (prerelease) Copyright (C) 2013 Free Software Foundation, Inc. GNU Fortran (FreeBSD Ports Collection) 4.9.0 20140223 (experimental) Copyright (C) 2014 Free Software Foundation, Inc. Thanks, A.