https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94109

            Bug ID: 94109
           Summary: Memory leak introduced in 8.3.0->8.3.1
           Product: gcc
           Version: 8.3.1
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: fortran
          Assignee: unassigned at gcc dot gnu.org
          Reporter: antony at cosmologist dot info
  Target Milestone: ---

I see an apparent memory leak introduced in running code between

ubuntu-toolchain-r/test gfortran 8.3.0 OK

Source 20200106 build gfortran 8.3.1 bad (also current 8 and 10 git heads).

I have not tracked down where it is coming from, but there is a complete
example on git with travis reports:

8.3.1 issue
https://travis-ci.org/cmbant/CAMB/jobs/660297689

GCC 9 9.2.1 20191102 issue (with otherwise same config as 8.3.0 below)
https://travis-ci.org/cmbant/CAMB/jobs/660297688

8.3.0 OK
https://travis-ci.org/cmbant/CAMB/jobs/660297687

(see memory counts at bottom of trace as function of loop count, produced from
python).

To produce output locally do
git clone --branch test https://github.com/cmbant/CAMB.git

and run setup.py and then setup.py test (with py3.6+).

I'm hoping this narrowish version window will enable someone to guess at the
cause of the issue. I looked at this because someone reported a large memory
leak on gfortran 9.2 OS X that cannot be reproduced with ifort, or gfortran
versions 6-8.3.0 (on linux the leak seems much smaller).

The code uses multiple nested allocatable F2003 class types.

Reply via email to