From: Kevin Boyd Date: Tue, 23 Jun 2020 09:57:40 +0000 (+0000) Subject: [WIP] Run regression tests under ASAN X-Git-Url: http://biod.pnpi.spb.ru/gitweb/?a=commitdiff_plain;h=49d692c29401ff0b064b4ac8299ee7a426f355d6;p=alexxy%2Fgromacs.git [WIP] Run regression tests under ASAN Suppression gets regression tests passing for complex, free energy, rotation. TODO - essential dynamics does not work for non-leak reasons, issues in perl script --- diff --git a/admin/gitlab-ci/gromacs.gitlab-ci.yml b/admin/gitlab-ci/gromacs.gitlab-ci.yml index 13df73910b..3802f3dd7f 100644 --- a/admin/gitlab-ci/gromacs.gitlab-ci.yml +++ b/admin/gitlab-ci/gromacs.gitlab-ci.yml @@ -578,8 +578,7 @@ gromacs:clang-8-cuda-10.1:release:build: retry: max: 1 script: - # This should go away once we are able to run ASAN on mdrun - - export ASAN_OPTIONS="detect_leaks=0" + - export LSAN_OPTIONS="suppressions=$CI_PROJECT_DIR/admin/lsan-suppressions.txt:print_suppressions=0" # Needed to run MPI enabled code in the docker images, until we set up different users - export OMPI_ALLOW_RUN_AS_ROOT=1 - export OMPI_ALLOW_RUN_AS_ROOT_CONFIRM=1 diff --git a/admin/lsan-suppressions.txt b/admin/lsan-suppressions.txt new file mode 100644 index 0000000000..f04a688a8f --- /dev/null +++ b/admin/lsan-suppressions.txt @@ -0,0 +1,55 @@ +# Known leaks - leak keywords are the lowest-level function/method of the leak call stack that is not reused by other +# routines. +leak:add_to_list +leak:atoms_to_constraints +leak:atoms_to_settles +leak:balance_fep_lists +leak:cpp_opts +leak:dd_init_bondeds +leak:dd_make_local_constraints +leak:dd_move_f +leak:dd_partition_system +leak:diagonalize_orires_tensors +leak:do_cpte_matrices +leak:do_edsam +leak:do_inputrec +leak:do_single_flood +leak:get_ir +leak:get_zone_pulse_cgs +leak:gmx::DomainDecompositionBuilder::Impl::build +leak:gmx_check +leak:gmx_make_edi +leak:gmx_mtop_ilistloop_init +leak:gmx_pme_init +leak:gmx_pme_receive_f +leak:init_buffer_flags +leak:init_disres +leak:init_dfhist_state +leak:init_df_history +leak:init_edsam +leak:init_ekinstate +leak:init_interaction_const +leak:init_orires +leak:init_rot +leak:init_swapcoords +leak:make_bondeds_zone +leak:make_dd_indices +leak:make_exclusions_zone +leak:make_fep_list +leak:make_ljpme_c6grid +leak:make_pull_groups +leak:make_reverse_top +leak:make_rotation_groups +leak:make_swap_groups +leak:make_tables +leak:mdoutf_write_to_trajectory_files +# Stack trace does not report a function beyond gmx_srenew_impl, so the file is suppressed instead. +leak:pairlist.cpp +leak:read_rotparams +leak:set_ddgrid_parameters +leak:set_reference_positions +leak:set_state_entries +leak:visitOption + +# External suppressions +leak:xdr_string diff --git a/cmake/gmxBuildTypeASAN.cmake b/cmake/gmxBuildTypeASAN.cmake index 0896fdf911..5d854e3ab0 100644 --- a/cmake/gmxBuildTypeASAN.cmake +++ b/cmake/gmxBuildTypeASAN.cmake @@ -1,7 +1,7 @@ # # This file is part of the GROMACS molecular simulation package. # -# Copyright (c) 2014,2016,2018, by the GROMACS development team, led by +# Copyright (c) 2014,2016,2018,2020, by the GROMACS development team, led by # Mark Abraham, David van der Spoel, Berk Hess, and Erik Lindahl, # and including many others, as listed in the AUTHORS file in the # top-level source directory and at http://www.gromacs.org. @@ -33,7 +33,7 @@ # the research papers on the package. Check out http://www.gromacs.org. # Custom build type "ASAN", to be used to run the -# AddressSanatizer memory checker. +# AddressSanitizer memory checker. set(_flags "-O1 -g -fsanitize=address -fno-omit-frame-pointer")