This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Ping [PATCH, fortran] PR 41936 Memory leakage with allocatables and user-defined operators
- From: Paul Richard Thomas <paul dot richard dot thomas at gmail dot com>
- To: Dominique Dhumieres <dominiq at lps dot ens dot fr>
- Cc: "fortran at gcc dot gnu dot org" <fortran at gcc dot gnu dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>, Tobias Burnus <burnus at net-b dot de>, Mikael Morin <mikael dot morin at sfr dot fr>
- Date: Mon, 9 Jun 2014 20:56:42 +0200
- Subject: Re: Ping [PATCH, fortran] PR 41936 Memory leakage with allocatables and user-defined operators
- Authentication-results: sourceware.org; auth=none
- References: <20140609125957 dot 56B56105 at mailhost dot lps dot ens dot fr>
Dear Dominique,
Without the patch applied, trunk shows 360 bytes definitely missing in
3 blocks for the original testcase and 9 out of 92 allocs did not have
corresponding frees. WIth the patch, I get:
==20527==
==20527== HEAP SUMMARY:
==20527== in use at exit: 0 bytes in 0 blocks
==20527== total heap usage: 92 allocs, 92 frees, 54,502 bytes allocated
==20527==
==20527== All heap blocks were freed -- no leaks are possible
==20527==
==20527== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 2 from 2)
--20527--
--20527-- used_suppression: 2 glibc-2.5.x-on-SUSE-10.2-(PPC)-2a
/usr/lib64/valgrind/default.supp:1286
==20527==
==20527== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 2 from 2)
Not only that, it bootstraps and regtests OK.
So it definitely does what it is advertised to do :-)
OK for trunk and, I would suggest 4.9.
Cheers
Paul
PS ifort 13.01 has exactly the same fault....
On 9 June 2014 14:59, Dominique Dhumieres <dominiq@lps.ens.fr> wrote:
> Patch posted at https://gcc.gnu.org/ml/fortran/2014-05/msg00155.html.
>
> TIA
>
> Dominique
--
The knack of flying is learning how to throw yourself at the ground and miss.
--Hitchhikers Guide to the Galaxy