1 #ifndef RecoTracker_PixelVertexFinding_plugins_alpaka_clusterTracksByDensity_h 2 #define RecoTracker_PixelVertexFinding_plugins_alpaka_clusterTracksByDensity_h 8 #include <alpaka/alpaka.hpp> 27 template <
typename TAcc>
28 ALPAKA_FN_ACC ALPAKA_FN_INLINE
void __attribute__((always_inline))
29 clusterTracksByDensity(
const TAcc& acc,
39 const uint32_t
threadIdxLocal(alpaka::getIdx<alpaka::Block, alpaka::Threads>(acc)[0u]);
50 float const* __restrict__
zt =
ws.zt();
51 float const* __restrict__
ezt2 =
ws.ezt2();
56 uint8_t* __restrict__
izt =
ws.izt();
57 int32_t* __restrict__
nn =
data.ndof();
58 int32_t* __restrict__
iv =
ws.iv();
67 auto&
hist = alpaka::declareSharedVar<Hist, __COUNTER__>(acc);
68 auto&
hws = alpaka::declareSharedVar<Hist::Counter[32], __COUNTER__>(acc);
73 alpaka::syncBlockThreads(acc);
77 printf(
"booked hist with %d bins, size %d for %d tracks\n",
hist.totbins(),
hist.capacity(),
nt);
87 izt[
i] = iz - INT8_MIN;
94 alpaka::syncBlockThreads(acc);
97 alpaka::syncBlockThreads(acc);
99 alpaka::syncBlockThreads(acc);
104 alpaka::syncBlockThreads(acc);
109 auto loop = [&](uint32_t
j) {
122 alpaka::syncBlockThreads(acc);
127 auto loop = [&](uint32_t
j) {
142 alpaka::syncBlockThreads(acc);
150 alpaka::syncBlockThreads(acc);
162 alpaka::syncBlockThreads(acc);
175 auto loop = [&](uint32_t
j) {
193 alpaka::syncBlockThreads(acc);
196 auto&
foundClusters = alpaka::declareSharedVar<unsigned int, __COUNTER__>(acc);
198 alpaka::syncBlockThreads(acc);
203 if (
iv[
i] ==
int(
i)) {
212 alpaka::syncBlockThreads(acc);
223 alpaka::syncBlockThreads(acc);
238 template <
typename TAcc>
253 #endif // RecoTracker_PixelVertexFinding_plugins_alpaka_clusterTracksByDensity_h
uint8_t *__restrict__ izt
ALPAKA_FN_ACC void operator()(const TAcc &acc, VtxSoAView pdata, WsSoAView pws, int minT, float eps, float errmax, float chi2max) const
const uint32_t threadIdxLocal(alpaka::getIdx< alpaka::Block, alpaka::Threads >(acc)[0u])
ALPAKA_FN_ACC ALPAKA_FN_INLINE void VtxSoAView & pdata
ALPAKA_FN_ACC ALPAKA_FN_INLINE void VtxSoAView WsSoAView int float eps
uint32_t & nvIntermediate
ALPAKA_FN_ACC ALPAKA_FN_INLINE void VtxSoAView WsSoAView int float float errmax
constexpr uint32_t MAXTRACKS
float const *__restrict__ ezt2
ZVertexSoAHeterogeneousLayout<>::View ZVertexSoAView
T1 atomicInc(T1 *a, T2 b)
ALPAKA_FN_ACC ALPAKA_FN_INLINE void VtxSoAView WsSoAView & pws
Abs< T >::type abs(const T &t)
ALPAKA_FN_ACC ALPAKA_FN_INLINE void VtxSoAView WsSoAView int minT
PixelVertexWSSoALayout<>::View PixelVertexWorkSpaceSoAView
::vertexFinder::PixelVertexWorkSpaceSoAView WsSoAView
ALPAKA_FN_ACC ALPAKA_FN_INLINE void VtxSoAView WsSoAView int float float float chi2max
float const *__restrict__ zt
::reco::ZVertexSoAView VtxSoAView
constexpr uint32_t MAXVTX
ALPAKA_FN_ACC ALPAKA_FN_INLINE void __attribute__((always_inline)) clusterTracksByDensity(const TAcc &acc