From 6b89843bd162dc523b16f9168db5578e979c62d3 Mon Sep 17 00:00:00 2001 From: Alan Gray Date: Tue, 29 Oct 2019 11:29:56 -0700 Subject: [PATCH] Remove dead code for nbnxm H2D coordinate copy event Change-Id: I83187ed470591f1fbc1c2573e59c14f8a6213ce7 --- src/gromacs/nbnxm/cuda/nbnxm_cuda.cu | 5 ----- src/gromacs/nbnxm/cuda/nbnxm_cuda_data_mgmt.cu | 1 - src/gromacs/nbnxm/cuda/nbnxm_cuda_types.h | 7 ------- src/gromacs/nbnxm/nbnxm.cpp | 5 ----- src/gromacs/nbnxm/nbnxm.h | 3 --- src/gromacs/nbnxm/nbnxm_gpu.h | 6 ------ 6 files changed, 27 deletions(-) diff --git a/src/gromacs/nbnxm/cuda/nbnxm_cuda.cu b/src/gromacs/nbnxm/cuda/nbnxm_cuda.cu index 7c7e7d097b..8ded53f7d1 100644 --- a/src/gromacs/nbnxm/cuda/nbnxm_cuda.cu +++ b/src/gromacs/nbnxm/cuda/nbnxm_cuda.cu @@ -887,11 +887,6 @@ void nbnxn_gpu_add_nbat_f_to_f(const AtomLocality atomL } } -void* nbnxn_get_x_on_device_event(const gmx_nbnxn_cuda_t *nb) -{ - return static_cast (nb->xAvailableOnDevice); -} - void nbnxn_wait_nonlocal_x_copy_D2H_done(gmx_nbnxn_cuda_t *nb) { nb->xNonLocalCopyD2HDone->waitForEvent(); diff --git a/src/gromacs/nbnxm/cuda/nbnxm_cuda_data_mgmt.cu b/src/gromacs/nbnxm/cuda/nbnxm_cuda_data_mgmt.cu index 67e7b581e7..e082725134 100644 --- a/src/gromacs/nbnxm/cuda/nbnxm_cuda_data_mgmt.cu +++ b/src/gromacs/nbnxm/cuda/nbnxm_cuda_data_mgmt.cu @@ -482,7 +482,6 @@ gpu_init(const gmx_device_info_t *deviceInfo, stat = cudaEventCreateWithFlags(&nb->misc_ops_and_local_H2D_done, cudaEventDisableTiming); CU_RET_ERR(stat, "cudaEventCreate on misc_ops_and_local_H2D_done failed"); - nb->xAvailableOnDevice = new GpuEventSynchronizer(); nb->xNonLocalCopyD2HDone = new GpuEventSynchronizer(); /* WARNING: CUDA timings are incorrect with multiple streams. diff --git a/src/gromacs/nbnxm/cuda/nbnxm_cuda_types.h b/src/gromacs/nbnxm/cuda/nbnxm_cuda_types.h index 4667d63c42..6c5043ea8b 100644 --- a/src/gromacs/nbnxm/cuda/nbnxm_cuda_types.h +++ b/src/gromacs/nbnxm/cuda/nbnxm_cuda_types.h @@ -267,13 +267,6 @@ struct gmx_nbnxn_cuda_t // local/nonlocal, if there is bonded GPU work, both flags will be true. gmx::EnumerationArray haveWork; - - GpuEventSynchronizer *xAvailableOnDevice; /**< event triggered when - coordinate buffer has been - copied to device by PP task and - any dependent task (e.g. transfer of coordinates - to the PME rank's GPU) can proceed. */ - /*! \brief Pointer to event synchronizer triggered when the local GPU buffer ops / reduction is complete * * \note That the synchronizer is managed outside of this module in StatePropagatorDataGpu. diff --git a/src/gromacs/nbnxm/nbnxm.cpp b/src/gromacs/nbnxm/nbnxm.cpp index eae838fa15..12f564b884 100644 --- a/src/gromacs/nbnxm/nbnxm.cpp +++ b/src/gromacs/nbnxm/nbnxm.cpp @@ -261,11 +261,6 @@ void nonbonded_verlet_t::insertNonlocalGpuDependency(const gmx::InteractionLocal Nbnxm::nbnxnInsertNonlocalGpuDependency(gpu_nbv, interactionLocality); } -void* nonbonded_verlet_t::get_x_on_device_event() -{ - return Nbnxm::nbnxn_get_x_on_device_event(gpu_nbv); -} - void nonbonded_verlet_t::wait_nonlocal_x_copy_D2H_done() { Nbnxm::nbnxn_wait_nonlocal_x_copy_D2H_done(gpu_nbv); diff --git a/src/gromacs/nbnxm/nbnxm.h b/src/gromacs/nbnxm/nbnxm.h index 2125e62f10..c42ee24fce 100644 --- a/src/gromacs/nbnxm/nbnxm.h +++ b/src/gromacs/nbnxm/nbnxm.h @@ -365,9 +365,6 @@ struct nonbonded_verlet_t */ void atomdata_init_add_nbat_f_to_f_gpu(GpuEventSynchronizer* localReductionDone); - /*! \brief return pointer to GPU event recorded when coordinates have been copied to device */ - void* get_x_on_device_event(); - /*! \brief Wait for non-local copy of coordinate buffer from device to host */ void wait_nonlocal_x_copy_D2H_done(); diff --git a/src/gromacs/nbnxm/nbnxm_gpu.h b/src/gromacs/nbnxm/nbnxm_gpu.h index 748484518f..34c1ef4865 100644 --- a/src/gromacs/nbnxm/nbnxm_gpu.h +++ b/src/gromacs/nbnxm/nbnxm_gpu.h @@ -327,12 +327,6 @@ void nbnxn_gpu_add_nbat_f_to_f(gmx::AtomLocality gmx_unused CUDA_FUNC_QUALIFIER void nbnxn_wait_x_on_device(gmx_nbnxn_gpu_t gmx_unused *nb) CUDA_FUNC_TERM; -/*! \brief return pointer to event recorded when coordinates have been copied to device - * \param[in] nb The nonbonded data GPU structure - */ -CUDA_FUNC_QUALIFIER -void* nbnxn_get_x_on_device_event(const gmx_nbnxn_gpu_t gmx_unused *nb) CUDA_FUNC_TERM_WITH_RETURN(nullptr); - /*! \brief Wait for non-local copy of coordinate buffer from device to host * \param[in] nb The nonbonded data GPU structure */ -- 2.22.0