Skip to content

Commit

Permalink
Renaming of kernels
Browse files Browse the repository at this point in the history
  • Loading branch information
VourMa committed Aug 16, 2024
1 parent d5e443a commit 787dfe1
Show file tree
Hide file tree
Showing 10 changed files with 75 additions and 75 deletions.
62 changes: 31 additions & 31 deletions RecoTracker/LSTCore/src/alpaka/Event.dev.cc
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ void lst::Event<Acc3D>::addHitToEvent(std::vector<float> const& x,
Vec3D const blocksPerGrid1{1, 1, max_blocks};
WorkDiv3D const hit_loop_workdiv = createWorkDiv(blocksPerGrid1, threadsPerBlock1, elementsPerThread);

hitLoopKernel hit_loop_kernel;
HitLoopKernel hit_loop_kernel;
alpaka::exec<Acc3D>(queue,
hit_loop_workdiv,
hit_loop_kernel,
Expand All @@ -209,7 +209,7 @@ void lst::Event<Acc3D>::addHitToEvent(std::vector<float> const& x,
Vec3D const blocksPerGrid2{1, 1, max_blocks};
WorkDiv3D const module_ranges_workdiv = createWorkDiv(blocksPerGrid2, threadsPerBlock2, elementsPerThread);

moduleRangesKernel module_ranges_kernel;
ModuleRangesKernel module_ranges_kernel;
alpaka::exec<Acc3D>(
queue, module_ranges_workdiv, module_ranges_kernel, *modulesBuffers_.data(), *hitsInGPU, nLowerModules_);
}
Expand Down Expand Up @@ -259,7 +259,7 @@ void lst::Event<Acc3D>::addPixelSegmentToEvent(std::vector<unsigned int> const&

WorkDiv1D const createMDArrayRangesGPU_workDiv = createWorkDiv<Vec1D>({1}, {1024}, {1});

lst::createMDArrayRangesGPU createMDArrayRangesGPU_kernel;
lst::CreateMDArrayRangesGPU createMDArrayRangesGPU_kernel;
alpaka::exec<Acc1D>(
queue, createMDArrayRangesGPU_workDiv, createMDArrayRangesGPU_kernel, *modulesBuffers_.data(), *rangesInGPU);

Expand All @@ -282,7 +282,7 @@ void lst::Event<Acc3D>::addPixelSegmentToEvent(std::vector<unsigned int> const&

WorkDiv1D const createSegmentArrayRanges_workDiv = createWorkDiv<Vec1D>({1}, {1024}, {1});

lst::createSegmentArrayRanges createSegmentArrayRanges_kernel;
lst::CreateSegmentArrayRanges createSegmentArrayRanges_kernel;
alpaka::exec<Acc1D>(queue,
createSegmentArrayRanges_workDiv,
createSegmentArrayRanges_kernel,
Expand Down Expand Up @@ -355,7 +355,7 @@ void lst::Event<Acc3D>::addPixelSegmentToEvent(std::vector<unsigned int> const&
Vec3D const blocksPerGrid{1, 1, max_blocks};
WorkDiv3D const addPixelSegmentToEvent_workdiv = createWorkDiv(blocksPerGrid, threadsPerBlock, elementsPerThread);

addPixelSegmentToEventKernel addPixelSegmentToEvent_kernel;
AddPixelSegmentToEventKernel addPixelSegmentToEvent_kernel;
alpaka::exec<Acc3D>(queue,
addPixelSegmentToEvent_workdiv,
addPixelSegmentToEvent_kernel,
Expand Down Expand Up @@ -386,7 +386,7 @@ void lst::Event<Acc3D>::createMiniDoublets() {

WorkDiv1D const createMDArrayRangesGPU_workDiv = createWorkDiv<Vec1D>({1}, {1024}, {1});

lst::createMDArrayRangesGPU createMDArrayRangesGPU_kernel;
lst::CreateMDArrayRangesGPU createMDArrayRangesGPU_kernel;
alpaka::exec<Acc1D>(
queue, createMDArrayRangesGPU_workDiv, createMDArrayRangesGPU_kernel, *modulesBuffers_.data(), *rangesInGPU);

Expand All @@ -408,7 +408,7 @@ void lst::Event<Acc3D>::createMiniDoublets() {
WorkDiv3D const createMiniDoubletsInGPUv2_workDiv =
createWorkDiv(blocksPerGridCreateMDInGPU, threadsPerBlockCreateMDInGPU, elementsPerThread);

lst::createMiniDoubletsInGPUv2 createMiniDoubletsInGPUv2_kernel;
lst::CreateMiniDoubletsInGPUv2 createMiniDoubletsInGPUv2_kernel;
alpaka::exec<Acc3D>(queue,
createMiniDoubletsInGPUv2_workDiv,
createMiniDoubletsInGPUv2_kernel,
Expand All @@ -419,7 +419,7 @@ void lst::Event<Acc3D>::createMiniDoublets() {

WorkDiv1D const addMiniDoubletRangesToEventExplicit_workDiv = createWorkDiv<Vec1D>({1}, {1024}, {1});

lst::addMiniDoubletRangesToEventExplicit addMiniDoubletRangesToEventExplicit_kernel;
lst::AddMiniDoubletRangesToEventExplicit addMiniDoubletRangesToEventExplicit_kernel;
alpaka::exec<Acc1D>(queue,
addMiniDoubletRangesToEventExplicit_workDiv,
addMiniDoubletRangesToEventExplicit_kernel,
Expand All @@ -446,7 +446,7 @@ void lst::Event<Acc3D>::createSegmentsWithModuleMap() {
WorkDiv3D const createSegmentsInGPUv2_workDiv =
createWorkDiv(blocksPerGridCreateSeg, threadsPerBlockCreateSeg, elementsPerThread);

lst::createSegmentsInGPUv2 createSegmentsInGPUv2_kernel;
lst::CreateSegmentsInGPUv2 createSegmentsInGPUv2_kernel;
alpaka::exec<Acc3D>(queue,
createSegmentsInGPUv2_workDiv,
createSegmentsInGPUv2_kernel,
Expand All @@ -457,7 +457,7 @@ void lst::Event<Acc3D>::createSegmentsWithModuleMap() {

WorkDiv1D const addSegmentRangesToEventExplicit_workDiv = createWorkDiv<Vec1D>({1}, {1024}, {1});

lst::addSegmentRangesToEventExplicit addSegmentRangesToEventExplicit_kernel;
lst::AddSegmentRangesToEventExplicit addSegmentRangesToEventExplicit_kernel;
alpaka::exec<Acc1D>(queue,
addSegmentRangesToEventExplicit_workDiv,
addSegmentRangesToEventExplicit_kernel,
Expand All @@ -474,7 +474,7 @@ void lst::Event<Acc3D>::createTriplets() {
if (tripletsInGPU == nullptr) {
WorkDiv1D const createTripletArrayRanges_workDiv = createWorkDiv<Vec1D>({1}, {1024}, {1});

lst::createTripletArrayRanges createTripletArrayRanges_kernel;
lst::CreateTripletArrayRanges createTripletArrayRanges_kernel;
alpaka::exec<Acc1D>(queue,
createTripletArrayRanges_workDiv,
createTripletArrayRanges_kernel,
Expand Down Expand Up @@ -535,7 +535,7 @@ void lst::Event<Acc3D>::createTriplets() {
WorkDiv3D const createTripletsInGPUv2_workDiv =
createWorkDiv(blocksPerGridCreateTrip, threadsPerBlockCreateTrip, elementsPerThread);

lst::createTripletsInGPUv2 createTripletsInGPUv2_kernel;
lst::CreateTripletsInGPUv2 createTripletsInGPUv2_kernel;
alpaka::exec<Acc3D>(queue,
createTripletsInGPUv2_workDiv,
createTripletsInGPUv2_kernel,
Expand All @@ -549,7 +549,7 @@ void lst::Event<Acc3D>::createTriplets() {

WorkDiv1D const addTripletRangesToEventExplicit_workDiv = createWorkDiv<Vec1D>({1}, {1024}, {1});

lst::addTripletRangesToEventExplicit addTripletRangesToEventExplicit_kernel;
lst::AddTripletRangesToEventExplicit addTripletRangesToEventExplicit_kernel;
alpaka::exec<Acc1D>(queue,
addTripletRangesToEventExplicit_workDiv,
addTripletRangesToEventExplicit_kernel,
Expand All @@ -575,7 +575,7 @@ void lst::Event<Acc3D>::createTrackCandidates(bool no_pls_dupclean, bool tc_pls_
WorkDiv3D const crossCleanpT3_workDiv =
createWorkDiv(blocksPerGrid_crossCleanpT3, threadsPerBlock_crossCleanpT3, elementsPerThread);

lst::crossCleanpT3 crossCleanpT3_kernel;
lst::CrossCleanpT3 crossCleanpT3_kernel;
alpaka::exec<Acc3D>(queue,
crossCleanpT3_workDiv,
crossCleanpT3_kernel,
Expand All @@ -587,7 +587,7 @@ void lst::Event<Acc3D>::createTrackCandidates(bool no_pls_dupclean, bool tc_pls_

WorkDiv1D const addpT3asTrackCandidatesInGPU_workDiv = createWorkDiv<Vec1D>({1}, {512}, {1});

lst::addpT3asTrackCandidatesInGPU addpT3asTrackCandidatesInGPU_kernel;
lst::AddpT3asTrackCandidatesInGPU addpT3asTrackCandidatesInGPU_kernel;
alpaka::exec<Acc1D>(queue,
addpT3asTrackCandidatesInGPU_workDiv,
addpT3asTrackCandidatesInGPU_kernel,
Expand All @@ -608,7 +608,7 @@ void lst::Event<Acc3D>::createTrackCandidates(bool no_pls_dupclean, bool tc_pls_
WorkDiv3D const removeDupQuintupletsInGPUBeforeTC_workDiv =
createWorkDiv(blocksPerGridRemoveDupQuints, threadsPerBlockRemoveDupQuints, elementsPerThread);

lst::removeDupQuintupletsInGPUBeforeTC removeDupQuintupletsInGPUBeforeTC_kernel;
lst::RemoveDupQuintupletsInGPUBeforeTC removeDupQuintupletsInGPUBeforeTC_kernel;
alpaka::exec<Acc3D>(queue,
removeDupQuintupletsInGPUBeforeTC_workDiv,
removeDupQuintupletsInGPUBeforeTC_kernel,
Expand All @@ -620,7 +620,7 @@ void lst::Event<Acc3D>::createTrackCandidates(bool no_pls_dupclean, bool tc_pls_
WorkDiv3D const crossCleanT5_workDiv =
createWorkDiv(blocksPerGrid_crossCleanT5, threadsPerBlock_crossCleanT5, elementsPerThread);

lst::crossCleanT5 crossCleanT5_kernel;
lst::CrossCleanT5 crossCleanT5_kernel;
alpaka::exec<Acc3D>(queue,
crossCleanT5_workDiv,
crossCleanT5_kernel,
Expand All @@ -635,7 +635,7 @@ void lst::Event<Acc3D>::createTrackCandidates(bool no_pls_dupclean, bool tc_pls_
WorkDiv3D const addT5asTrackCandidateInGPU_workDiv = createWorkDiv(
blocksPerGrid_addT5asTrackCandidateInGPU, threadsPerBlock_addT5asTrackCandidateInGPU, elementsPerThread);

lst::addT5asTrackCandidateInGPU addT5asTrackCandidateInGPU_kernel;
lst::AddT5asTrackCandidateInGPU addT5asTrackCandidateInGPU_kernel;
alpaka::exec<Acc3D>(queue,
addT5asTrackCandidateInGPU_workDiv,
addT5asTrackCandidateInGPU_kernel,
Expand All @@ -650,7 +650,7 @@ void lst::Event<Acc3D>::createTrackCandidates(bool no_pls_dupclean, bool tc_pls_
WorkDiv3D const checkHitspLS_workDiv =
createWorkDiv(blocksPerGridCheckHitspLS, threadsPerBlockCheckHitspLS, elementsPerThread);

lst::checkHitspLS checkHitspLS_kernel;
lst::CheckHitspLS checkHitspLS_kernel;
alpaka::exec<Acc3D>(
queue, checkHitspLS_workDiv, checkHitspLS_kernel, *modulesBuffers_.data(), *segmentsInGPU, true);
}
Expand All @@ -660,7 +660,7 @@ void lst::Event<Acc3D>::createTrackCandidates(bool no_pls_dupclean, bool tc_pls_
WorkDiv3D const crossCleanpLS_workDiv =
createWorkDiv(blocksPerGrid_crossCleanpLS, threadsPerBlock_crossCleanpLS, elementsPerThread);

lst::crossCleanpLS crossCleanpLS_kernel;
lst::CrossCleanpLS crossCleanpLS_kernel;
alpaka::exec<Acc3D>(queue,
crossCleanpLS_workDiv,
crossCleanpLS_kernel,
Expand All @@ -678,7 +678,7 @@ void lst::Event<Acc3D>::createTrackCandidates(bool no_pls_dupclean, bool tc_pls_
WorkDiv3D const addpLSasTrackCandidateInGPU_workDiv = createWorkDiv(
blocksPerGrid_addpLSasTrackCandidateInGPU, threadsPerBlock_addpLSasTrackCandidateInGPU, elementsPerThread);

lst::addpLSasTrackCandidateInGPU addpLSasTrackCandidateInGPU_kernel;
lst::AddpLSasTrackCandidateInGPU addpLSasTrackCandidateInGPU_kernel;
alpaka::exec<Acc3D>(queue,
addpLSasTrackCandidateInGPU_workDiv,
addpLSasTrackCandidateInGPU_kernel,
Expand Down Expand Up @@ -789,7 +789,7 @@ void lst::Event<Acc3D>::createPixelTriplets() {
WorkDiv3D const createPixelTripletsInGPUFromMapv2_workDiv =
createWorkDiv(blocksPerGrid, threadsPerBlock, elementsPerThread);

lst::createPixelTripletsInGPUFromMapv2 createPixelTripletsInGPUFromMapv2_kernel;
lst::CreatePixelTripletsInGPUFromMapv2 createPixelTripletsInGPUFromMapv2_kernel;
alpaka::exec<Acc3D>(queue,
createPixelTripletsInGPUFromMapv2_workDiv,
createPixelTripletsInGPUFromMapv2_kernel,
Expand Down Expand Up @@ -819,7 +819,7 @@ void lst::Event<Acc3D>::createPixelTriplets() {
WorkDiv3D const removeDupPixelTripletsInGPUFromMap_workDiv =
createWorkDiv(blocksPerGridDupPixTrip, threadsPerBlockDupPixTrip, elementsPerThread);

lst::removeDupPixelTripletsInGPUFromMap removeDupPixelTripletsInGPUFromMap_kernel;
lst::RemoveDupPixelTripletsInGPUFromMap removeDupPixelTripletsInGPUFromMap_kernel;
alpaka::exec<Acc3D>(queue,
removeDupPixelTripletsInGPUFromMap_workDiv,
removeDupPixelTripletsInGPUFromMap_kernel,
Expand All @@ -829,7 +829,7 @@ void lst::Event<Acc3D>::createPixelTriplets() {
void lst::Event<Acc3D>::createQuintuplets() {
WorkDiv1D const createEligibleModulesListForQuintupletsGPU_workDiv = createWorkDiv<Vec1D>({1}, {1024}, {1});

lst::createEligibleModulesListForQuintupletsGPU createEligibleModulesListForQuintupletsGPU_kernel;
lst::CreateEligibleModulesListForQuintupletsGPU createEligibleModulesListForQuintupletsGPU_kernel;
alpaka::exec<Acc1D>(queue,
createEligibleModulesListForQuintupletsGPU_workDiv,
createEligibleModulesListForQuintupletsGPU_kernel,
Expand Down Expand Up @@ -860,7 +860,7 @@ void lst::Event<Acc3D>::createQuintuplets() {
WorkDiv3D const createQuintupletsInGPUv2_workDiv =
createWorkDiv(blocksPerGridQuints, threadsPerBlockQuints, elementsPerThread);

lst::createQuintupletsInGPUv2 createQuintupletsInGPUv2_kernel;
lst::CreateQuintupletsInGPUv2 createQuintupletsInGPUv2_kernel;
alpaka::exec<Acc3D>(queue,
createQuintupletsInGPUv2_workDiv,
createQuintupletsInGPUv2_kernel,
Expand All @@ -877,7 +877,7 @@ void lst::Event<Acc3D>::createQuintuplets() {
WorkDiv3D const removeDupQuintupletsInGPUAfterBuild_workDiv =
createWorkDiv(blocksPerGridDupQuint, threadsPerBlockDupQuint, elementsPerThread);

lst::removeDupQuintupletsInGPUAfterBuild removeDupQuintupletsInGPUAfterBuild_kernel;
lst::RemoveDupQuintupletsInGPUAfterBuild removeDupQuintupletsInGPUAfterBuild_kernel;
alpaka::exec<Acc3D>(queue,
removeDupQuintupletsInGPUAfterBuild_workDiv,
removeDupQuintupletsInGPUAfterBuild_kernel,
Expand All @@ -887,7 +887,7 @@ void lst::Event<Acc3D>::createQuintuplets() {

WorkDiv1D const addQuintupletRangesToEventExplicit_workDiv = createWorkDiv<Vec1D>({1}, {1024}, {1});

lst::addQuintupletRangesToEventExplicit addQuintupletRangesToEventExplicit_kernel;
lst::AddQuintupletRangesToEventExplicit addQuintupletRangesToEventExplicit_kernel;
alpaka::exec<Acc1D>(queue,
addQuintupletRangesToEventExplicit_workDiv,
addQuintupletRangesToEventExplicit_kernel,
Expand All @@ -907,7 +907,7 @@ void lst::Event<Acc3D>::pixelLineSegmentCleaning(bool no_pls_dupclean) {
WorkDiv3D const checkHitspLS_workDiv =
createWorkDiv(blocksPerGridCheckHitspLS, threadsPerBlockCheckHitspLS, elementsPerThread);

lst::checkHitspLS checkHitspLS_kernel;
lst::CheckHitspLS checkHitspLS_kernel;
alpaka::exec<Acc3D>(
queue, checkHitspLS_workDiv, checkHitspLS_kernel, *modulesBuffers_.data(), *segmentsInGPU, false);
}
Expand Down Expand Up @@ -990,7 +990,7 @@ void lst::Event<Acc3D>::createPixelQuintuplets() {
WorkDiv3D const createPixelQuintupletsInGPUFromMapv2_workDiv =
createWorkDiv(blocksPerGridCreatePixQuints, threadsPerBlockCreatePixQuints, elementsPerThread);

lst::createPixelQuintupletsInGPUFromMapv2 createPixelQuintupletsInGPUFromMapv2_kernel;
lst::CreatePixelQuintupletsInGPUFromMapv2 createPixelQuintupletsInGPUFromMapv2_kernel;
alpaka::exec<Acc3D>(queue,
createPixelQuintupletsInGPUFromMapv2_workDiv,
createPixelQuintupletsInGPUFromMapv2_kernel,
Expand All @@ -1010,15 +1010,15 @@ void lst::Event<Acc3D>::createPixelQuintuplets() {
WorkDiv3D const removeDupPixelQuintupletsInGPUFromMap_workDiv =
createWorkDiv(blocksPerGridDupPix, threadsPerBlockDupPix, elementsPerThread);

lst::removeDupPixelQuintupletsInGPUFromMap removeDupPixelQuintupletsInGPUFromMap_kernel;
lst::RemoveDupPixelQuintupletsInGPUFromMap removeDupPixelQuintupletsInGPUFromMap_kernel;
alpaka::exec<Acc3D>(queue,
removeDupPixelQuintupletsInGPUFromMap_workDiv,
removeDupPixelQuintupletsInGPUFromMap_kernel,
*pixelQuintupletsInGPU);

WorkDiv1D const addpT5asTrackCandidateInGPU_workDiv = createWorkDiv<Vec1D>({1}, {256}, {1});

lst::addpT5asTrackCandidateInGPU addpT5asTrackCandidateInGPU_kernel;
lst::AddpT5asTrackCandidateInGPU addpT5asTrackCandidateInGPU_kernel;
alpaka::exec<Acc1D>(queue,
addpT5asTrackCandidateInGPU_workDiv,
addpT5asTrackCandidateInGPU_kernel,
Expand Down
4 changes: 2 additions & 2 deletions RecoTracker/LSTCore/src/alpaka/Hit.h
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ namespace lst {
return -1;
}

struct moduleRangesKernel {
struct ModuleRangesKernel {
template <typename TAcc>
ALPAKA_FN_ACC void operator()(TAcc const& acc,
lst::Modules modulesInGPU,
Expand All @@ -199,7 +199,7 @@ namespace lst {
}
};

struct hitLoopKernel {
struct HitLoopKernel {
template <typename TAcc>
ALPAKA_FN_ACC void operator()(TAcc const& acc,
uint16_t Endcap, // Integer corresponding to endcap in module subdets
Expand Down
10 changes: 5 additions & 5 deletions RecoTracker/LSTCore/src/alpaka/Kernels.h
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ namespace lst {
matched[1] = nMatched;
}

struct removeDupQuintupletsInGPUAfterBuild {
struct RemoveDupQuintupletsInGPUAfterBuild {
template <typename TAcc>
ALPAKA_FN_ACC void operator()(TAcc const& acc,
lst::Modules modulesInGPU,
Expand Down Expand Up @@ -192,7 +192,7 @@ namespace lst {
}
};

struct removeDupQuintupletsInGPUBeforeTC {
struct RemoveDupQuintupletsInGPUBeforeTC {
template <typename TAcc>
ALPAKA_FN_ACC void operator()(TAcc const& acc,
lst::Quintuplets quintupletsInGPU,
Expand Down Expand Up @@ -267,7 +267,7 @@ namespace lst {
}
};

struct removeDupPixelTripletsInGPUFromMap {
struct RemoveDupPixelTripletsInGPUFromMap {
template <typename TAcc>
ALPAKA_FN_ACC void operator()(TAcc const& acc, lst::PixelTriplets pixelTripletsInGPU) const {
auto const globalThreadIdx = alpaka::getIdx<alpaka::Grid, alpaka::Threads>(acc);
Expand Down Expand Up @@ -304,7 +304,7 @@ namespace lst {
}
};

struct removeDupPixelQuintupletsInGPUFromMap {
struct RemoveDupPixelQuintupletsInGPUFromMap {
template <typename TAcc>
ALPAKA_FN_ACC void operator()(TAcc const& acc, lst::PixelQuintuplets pixelQuintupletsInGPU) const {
auto const globalThreadIdx = alpaka::getIdx<alpaka::Grid, alpaka::Threads>(acc);
Expand All @@ -331,7 +331,7 @@ namespace lst {
}
};

struct checkHitspLS {
struct CheckHitspLS {
template <typename TAcc>
ALPAKA_FN_ACC void operator()(TAcc const& acc,
lst::Modules modulesInGPU,
Expand Down
Loading

0 comments on commit 787dfe1

Please sign in to comment.