Project

General

Profile

Bug #2693

Several memory leaks in mdrun

Added by Paul Bauer about 1 year ago. Updated 10 months ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
mdrun
Target version:
Affected version - extra info:
Affected version:
Difficulty:
hard
Close

Description

When trying to run simulations through the new API, several issues are reported on the ASAN build that point to severe memory leaks within mdrun.
I attached a log file for

 valgrind --leak-check=full bin/gmxapi-test

I have a patch that fixes some of the direct leaks, but I'm out of my depth for most of the stuff.

vallog (223 KB) vallog Paul Bauer, 10/12/2018 04:02 PM

Associated revisions

Revision 0926c8a6 (diff)
Added by Kevin Boyd 10 months ago

Fix memory leak at end of do_md

Without domain decomposition, the atomtypes field of localtop is
dynamically allocated and needs freeing after mdrun

Refs #2693

Change-Id: I45d18c503a87832332868e7fb9b63720548f243c

Revision 9ccd7f2b (diff)
Added by Kevin Boyd 10 months ago

Fix memory leaks in ns cleanup

Added some missing sfrees to cleanup function

refs #2693

Change-Id: I1e1455794778139d3a3866e00c05f4ed97aea07c

Revision 29da602d (diff)
Added by Kevin Boyd 10 months ago

Change t_extmass pointers to std::vector

Using std::vector in t_extmass fixes a leak in do_md.

Used arrayRefs to view arrays in NHC_trotter

Refs #2693

Change-Id: I6bd84952fb7a470879ddd665183680c865e22fc2

History

#1 Updated by Mark Abraham about 1 year ago

Yes, that's one of about 50 reasons we're not able to support an API in a useful way in GROMACS 2019. :-)

I'm not sure whether we have blanket suppressions somewhere for ASAN (more particularly, LeakSanitizer), but we certainly could. But I doubt there's a good way to separate the leaks from mdrun from any caused by the memory management in gmxapi.

#2 Updated by Paul Bauer 12 months ago

  • Target version changed from 2019 to future

Those are not going be fixed in 2019.

#3 Updated by Gerrit Code Review Bot 10 months ago

Gerrit received a related patchset '2' for Issue #2693.
Uploader: Kevin Boyd ()
Change-Id: gromacs~master~I2a74543c3d393fca2a8e44e02e00c5daa68df922
Gerrit URL: https://gerrit.gromacs.org/8830

#4 Updated by Gerrit Code Review Bot 10 months ago

Gerrit received a related patchset '1' for Issue #2693.
Uploader: Kevin Boyd ()
Change-Id: gromacs~master~I1e1455794778139d3a3866e00c05f4ed97aea07c
Gerrit URL: https://gerrit.gromacs.org/8831

#5 Updated by Gerrit Code Review Bot 10 months ago

Gerrit received a related patchset '3' for Issue #2693.
Uploader: Kevin Boyd ()
Change-Id: gromacs~master~I45d18c503a87832332868e7fb9b63720548f243c
Gerrit URL: https://gerrit.gromacs.org/8832

#6 Updated by Gerrit Code Review Bot 10 months ago

Gerrit received a related patchset '1' for Issue #2693.
Uploader: Kevin Boyd ()
Change-Id: gromacs~master~I6bd84952fb7a470879ddd665183680c865e22fc2
Gerrit URL: https://gerrit.gromacs.org/8847

Also available in: Atom PDF