}
}
+// Declaring the class here to avoid long unreadable name in the profiler report
+//! \brief Class name for test kernel
+class DummyKernel;
/*!
* \brief Checks that device \c deviceInfo is sane (ie can run a kernel).
queue.submit([&](cl::sycl::handler& cgh) {
auto d_buffer = buffer.get_access<cl::sycl::access::mode::discard_write>(cgh);
cl::sycl::range<1> range{ numThreads };
- cgh.parallel_for<class DummyKernel>(range, [=](cl::sycl::id<1> threadId) {
+ cgh.parallel_for<DummyKernel>(range, [=](cl::sycl::id<1> threadId) {
d_buffer[threadId] = threadId.get(0);
});
}).wait_and_throw();
#include "gromacs/gpu_utils/gpueventsynchronizer_sycl.h"
#include "gromacs/utility/template_mp.h"
+//! \brief Class name for reduction kernel
+template<bool addRvecForce, bool accumulateForce>
+class ReduceKernel;
+
namespace gmx
{
};
}
-template<bool addRvecForce, bool accumulateForce>
-class ReduceKernelName;
-
template<bool addRvecForce, bool accumulateForce>
static void launchReductionKernel_(const int numAtoms,
const int atomStart,
queue.submit([&](cl::sycl::handler& cgh) {
auto kernel = reduceKernel<addRvecForce, accumulateForce>(
cgh, b_nbnxmForce, b_rvecForceToAdd, b_forceTotal, b_cell, atomStart);
- cgh.parallel_for<ReduceKernelName<addRvecForce, accumulateForce>>(rangeNumAtoms, kernel);
+ cgh.parallel_for<ReduceKernel<addRvecForce, accumulateForce>>(rangeNumAtoms, kernel);
});
}
#include "gromacs/utility/fatalerror.h"
#include "gromacs/utility/template_mp.h"
+//! \brief Class name for leap-frog kernel
+template<gmx::NumTempScaleValues numTempScaleValues, gmx::VelocityScalingType velocityScaling>
+class LeapFrogKernel;
+
namespace gmx
{
};
}
-// SYCL 1.2.1 requires providing a unique type for a kernel. Should not be needed for SYCL2020.
-template<NumTempScaleValues numTempScaleValues, VelocityScalingType velocityScaling>
-class LeapFrogKernelName;
-
template<NumTempScaleValues numTempScaleValues, VelocityScalingType velocityScaling, class... Args>
static cl::sycl::event launchLeapFrogKernel(const DeviceStream& deviceStream, int numAtoms, Args&&... args)
{
// Should not be needed for SYCL2020.
- using kernelNameType = LeapFrogKernelName<numTempScaleValues, velocityScaling>;
+ using kernelNameType = LeapFrogKernel<numTempScaleValues, velocityScaling>;
const cl::sycl::range<1> rangeAllAtoms(numAtoms);
cl::sycl::queue q = deviceStream.stream();
#include "gromacs/gpu_utils/gputraits_sycl.h"
#include "gromacs/utility/gmxassert.h"
+//! \brief Class name for scaling kernel
+class ScaleKernel;
+
namespace gmx
{
cl::sycl::event e = queue.submit([&](cl::sycl::handler& cgh) {
auto kernel = scaleKernel(cgh, d_coordinates, mu);
- cgh.parallel_for<class ScaleKernelName>(rangeAllAtoms, kernel);
+ cgh.parallel_for<ScaleKernel>(rangeAllAtoms, kernel);
});
// TODO: Although this only happens on the pressure coupling steps, this synchronization
// can affect the performance if nstpcouple is small. See Issue #4018
#include "nbnxm_sycl_kernel_utils.h"
#include "nbnxm_sycl_types.h"
+//! \brief Class name for NBNXM kernel
+template<bool doPruneNBL, bool doCalcEnergies, enum Nbnxm::ElecType elecType, enum Nbnxm::VdwType vdwType>
+class NbnxmKernel;
+
namespace Nbnxm
{
};
}
-// SYCL 1.2.1 requires providing a unique type for a kernel. Should not be needed for SYCL2020.
-template<bool doPruneNBL, bool doCalcEnergies, enum ElecType elecType, enum VdwType vdwType>
-class NbnxmKernelName;
-
template<bool doPruneNBL, bool doCalcEnergies, enum ElecType elecType, enum VdwType vdwType, class... Args>
cl::sycl::event launchNbnxmKernel(const DeviceStream& deviceStream, const int numSci, Args&&... args)
{
- // Should not be needed for SYCL2020.
- using kernelNameType = NbnxmKernelName<doPruneNBL, doCalcEnergies, elecType, vdwType>;
+ using kernelNameType = NbnxmKernel<doPruneNBL, doCalcEnergies, elecType, vdwType>;
/* Kernel launch config:
* - The thread block dimensions match the size of i-clusters, j-clusters,
using cl::sycl::access::mode;
using cl::sycl::access::target;
+//! \brief Class name for NBNXM prune-only kernel
+template<bool haveFreshList>
+class NbnxmKernelPruneOnly;
+
namespace Nbnxm
{
};
}
-// SYCL 1.2.1 requires providing a unique type for a kernel. Should not be needed for SYCL2020.
-template<bool haveFreshList>
-class NbnxmKernelPruneOnlyName;
-
template<bool haveFreshList, class... Args>
cl::sycl::event launchNbnxmKernelPruneOnly(const DeviceStream& deviceStream,
const int numSciInPart,
Args&&... args)
{
- // Should not be needed for SYCL2020.
- using kernelNameType = NbnxmKernelPruneOnlyName<haveFreshList>;
+ using kernelNameType = NbnxmKernelPruneOnly<haveFreshList>;
/* Kernel launch config:
* - The thread block dimensions match the size of i-clusters, j-clusters,