1 #ifndef RecoLocalTracker_SiPixelClusterizer_plugins_gpuClusterChargeCut_h 2 #define RecoLocalTracker_SiPixelClusterizer_plugins_gpuClusterChargeCut_h 17 template <
typename TrackerTraits>
21 uint16_t* __restrict__
id,
22 uint16_t
const* __restrict__
adc,
25 uint32_t
const* __restrict__
moduleId,
44 auto thisModuleId =
id[firstPixel];
48 thisModuleId =
id[firstPixel];
65 printf(
"Warning too many clusters in module %d in block %d: %d > %d\n",
78 if (
id[
i] != thisModuleId)
89 if (thisModuleId % 100 == 1)
91 printf(
"start cluster charge cut for module %d in block %d\n", thisModuleId,
blockIdx.x);
103 if (
id[
i] != thisModuleId)
123 __shared__ uint16_t
ws[32];
124 constexpr
auto maxThreads = 1024;
125 auto minClust = nclus > maxThreads ? maxThreads : nclus;
134 uint32_t prevBlockEnd = ((
i / maxThreads) * maxThreads) - 1;
149 if (
id[
i] != thisModuleId)
164 #endif // RecoLocalTracker_SiPixelClusterizer_plugins_gpuClusterChargeCut_h
__shared__ uint8_t ok[maxNumClustersPerModules]
uint16_t *__restrict__ uint16_t const *__restrict__ uint32_t const *__restrict__ uint32_t *__restrict__ nClustersInModule
constexpr int nMaxModules
auto const good
min quality of good
__shared__ int32_t charge[maxNumClustersPerModules]
float clusterChargeCut(const edm::ParameterSet &conf, const char *name="clusterChargeCut")
constexpr uint16_t numberOfModules
constexpr int32_t getThresholdForLayerOnCondition(bool isLayer1) const noexcept
constexpr uint32_t maxNumClustersPerModules
assert(nMaxModules< maxNumModules)
constexpr uint16_t maxNumModules
uint16_t *__restrict__ uint16_t const *__restrict__ uint32_t const *__restrict__ uint32_t *__restrict__ uint32_t const *__restrict__ int32_t *__restrict__ clusterId
constexpr uint16_t invalidModuleId
uint16_t *__restrict__ uint16_t const *__restrict__ uint32_t const *__restrict__ uint32_t *__restrict__ uint32_t const *__restrict__ int32_t *__restrict__ uint32_t numElements
uint16_t *__restrict__ uint16_t const *__restrict__ uint32_t const *__restrict__ moduleStart
__shared__ uint16_t newclusId[maxNumClustersPerModules]
static constexpr uint32_t layerStart[numberOfLayers+1]
uint16_t *__restrict__ uint16_t const *__restrict__ uint32_t const *__restrict__ uint32_t *__restrict__ uint32_t const *__restrict__ moduleId
bool __syncthreads_and(bool x)
T1 atomicAdd(T1 *a, T2 b)
uint16_t *__restrict__ uint16_t const *__restrict__ adc