1
0
mirror of https://github.com/paboyle/Grid.git synced 2024-11-10 15:55:37 +00:00

Single SIMD lane operations for CUDA

This commit is contained in:
paboyle 2018-06-27 21:28:06 +01:00
parent efa84ca50a
commit 38e2a32ac9

View File

@ -214,6 +214,16 @@ public:
{
mult(&phi(), &U(mu), &chi());
}
static accelerator_inline void multLinkGpu(int lane,
typename SiteHalfSpinor::scalar_object &phi,
const SiteDoubledGaugeField &U,
const typename SiteHalfSpinor::scalar_object &chi,
int mu)
{
auto U_l = extractLaneGpu(lane,U(mu));
phi() = U_l * chi();
}
static accelerator_inline void multLinkProp(SitePropagator &phi,
const SiteDoubledGaugeField &U,
@ -355,6 +365,16 @@ public:
mult(&phi(), &UU(), &chi());
}
static accelerator_inline void multLinkGpu(int lane,
typename SiteHalfSpinor::scalar_object &phi,
const SiteDoubledGaugeField &U,
const typename SiteHalfSpinor::scalar_object &chi,
int mu)
{
auto U_l = U(mu);
phi() = U_l * chi();
}
static accelerator_inline void multLinkProp(SitePropagator &phi,
const SiteDoubledGaugeField &U,
const SitePropagator &chi,int mu)