diff --git a/RecoLocalCalo/EcalRecProducers/plugins/alpaka/AmplitudeComputationCommonKernels.h b/RecoLocalCalo/EcalRecProducers/plugins/alpaka/AmplitudeComputationCommonKernels.h index e92bd37890158..f71136b4f5989 100644 --- a/RecoLocalCalo/EcalRecProducers/plugins/alpaka/AmplitudeComputationCommonKernels.h +++ b/RecoLocalCalo/EcalRecProducers/plugins/alpaka/AmplitudeComputationCommonKernels.h @@ -28,8 +28,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit { /// class Kernel_prep_1d_and_initialize { public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, EcalDigiDeviceCollection::ConstView digisDevEB, EcalDigiDeviceCollection::ConstView digisDevEE, EcalUncalibratedRecHitDeviceCollection::View uncalibRecHitsEB, @@ -328,8 +327,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit { /// class Kernel_prep_2d { public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc2D const& acc, EcalDigiDeviceCollection::ConstView digisDevEB, EcalDigiDeviceCollection::ConstView digisDevEE, EcalMultifitConditionsDevice::ConstView conditionsDev, @@ -466,11 +464,12 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit { } // namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit namespace alpaka::trait { + using namespace ALPAKA_ACCELERATOR_NAMESPACE; using namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit; //! The trait for getting the size of the block shared dynamic memory for Kernel_prep_1d_and_initialize. - template - struct BlockSharedMemDynSizeBytes { + template <> + struct BlockSharedMemDynSizeBytes { //! \return The size of the shared memory allocated for a block. template ALPAKA_FN_HOST_ACC static auto getBlockSharedMemDynSizeBytes(Kernel_prep_1d_and_initialize const&, diff --git a/RecoLocalCalo/EcalRecProducers/plugins/alpaka/AmplitudeComputationKernels.dev.cc b/RecoLocalCalo/EcalRecProducers/plugins/alpaka/AmplitudeComputationKernels.dev.cc index 552761653bb23..64aefd0109db8 100644 --- a/RecoLocalCalo/EcalRecProducers/plugins/alpaka/AmplitudeComputationKernels.dev.cc +++ b/RecoLocalCalo/EcalRecProducers/plugins/alpaka/AmplitudeComputationKernels.dev.cc @@ -55,8 +55,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit { /// class Kernel_minimize { public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, InputProduct::ConstView const& digisDevEB, InputProduct::ConstView const& digisDevEE, OutputProduct::View uncalibRecHitsEB, @@ -293,23 +292,25 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit { } // namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit namespace alpaka::trait { + using namespace ALPAKA_ACCELERATOR_NAMESPACE; using namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit; //! The trait for getting the size of the block shared dynamic memory for Kernel_minimize. - template - struct BlockSharedMemDynSizeBytes { + template <> + struct BlockSharedMemDynSizeBytes { //! \return The size of the shared memory allocated for a block. template ALPAKA_FN_HOST_ACC static auto getBlockSharedMemDynSizeBytes(Kernel_minimize const&, TVec const& threadsPerBlock, TVec const& elemsPerThread, TArgs const&...) -> std::size_t { - using ScalarType = ecal::multifit::SampleVector::Scalar; + using ScalarType = ::ecal::multifit::SampleVector::Scalar; // return the amount of dynamic shared memory needed - std::size_t bytes = 2 * threadsPerBlock[0u] * elemsPerThread[0u] * - calo::multifit::MapSymM::total * - sizeof(ScalarType); + std::size_t bytes = + 2 * threadsPerBlock[0u] * elemsPerThread[0u] * + calo::multifit::MapSymM::total * + sizeof(ScalarType); return bytes; } }; diff --git a/RecoLocalCalo/EcalRecProducers/plugins/alpaka/TimeComputationKernels.h b/RecoLocalCalo/EcalRecProducers/plugins/alpaka/TimeComputationKernels.h index 942a1500ead9a..d2cc8a4afe654 100644 --- a/RecoLocalCalo/EcalRecProducers/plugins/alpaka/TimeComputationKernels.h +++ b/RecoLocalCalo/EcalRecProducers/plugins/alpaka/TimeComputationKernels.h @@ -33,8 +33,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit { using ScalarType = ::ecal::multifit::SampleVector::Scalar; public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, ScalarType* const sample_values, ScalarType* const sample_value_errors, bool* const useless_sample_values, @@ -120,8 +119,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit { using ScalarType = ::ecal::multifit::SampleVector::Scalar; public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, EcalDigiDeviceCollection::ConstView digisDevEB, EcalDigiDeviceCollection::ConstView digisDevEE, ScalarType* const sample_values, @@ -523,8 +521,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit { using ScalarType = ::ecal::multifit::SampleVector::Scalar; public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, EcalDigiDeviceCollection::ConstView digisDevEB, EcalDigiDeviceCollection::ConstView digisDevEE, ScalarType* const sample_values, @@ -730,8 +727,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit { using ScalarType = ::ecal::multifit::SampleVector::Scalar; public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, EcalDigiDeviceCollection::ConstView digisDevEB, EcalDigiDeviceCollection::ConstView digisDevEE, EcalMultifitConditionsDevice::ConstView conditionsDev, @@ -777,8 +773,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit { using ScalarType = ::ecal::multifit::SampleVector::Scalar; public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, EcalDigiDeviceCollection::ConstView digisDevEB, EcalDigiDeviceCollection::ConstView digisDevEE, EcalMultifitConditionsDevice::ConstView conditionsDev, @@ -960,8 +955,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit { using ScalarType = ::ecal::multifit::SampleVector::Scalar; public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, EcalDigiDeviceCollection::ConstView digisDevEB, EcalDigiDeviceCollection::ConstView digisDevEE, EcalUncalibratedRecHitDeviceCollection::View uncalibRecHitsEB, @@ -1095,18 +1089,19 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit { } // namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit namespace alpaka::trait { + using namespace ALPAKA_ACCELERATOR_NAMESPACE; using namespace ALPAKA_ACCELERATOR_NAMESPACE::ecal::multifit; //! The trait for getting the size of the block shared dynamic memory for Kernel_time_compute_nullhypot. - template - struct BlockSharedMemDynSizeBytes { + template <> + struct BlockSharedMemDynSizeBytes { //! \return The size of the shared memory allocated for a block. template ALPAKA_FN_HOST_ACC static auto getBlockSharedMemDynSizeBytes(Kernel_time_compute_nullhypot const&, TVec const& threadsPerBlock, TVec const& elemsPerThread, TArgs const&...) -> std::size_t { - using ScalarType = ecal::multifit::SampleVector::Scalar; + using ScalarType = ::ecal::multifit::SampleVector::Scalar; // return the amount of dynamic shared memory needed std::size_t bytes = threadsPerBlock[0u] * elemsPerThread[0u] * 4 * sizeof(ScalarType); @@ -1115,14 +1110,14 @@ namespace alpaka::trait { }; //! The trait for getting the size of the block shared dynamic memory for Kernel_time_compute_makeratio. - template - struct BlockSharedMemDynSizeBytes { + template <> + struct BlockSharedMemDynSizeBytes { template ALPAKA_FN_HOST_ACC static auto getBlockSharedMemDynSizeBytes(Kernel_time_compute_makeratio const&, TVec const& threadsPerBlock, TVec const& elemsPerThread, TArgs const&...) -> std::size_t { - using ScalarType = ecal::multifit::SampleVector::Scalar; + using ScalarType = ::ecal::multifit::SampleVector::Scalar; std::size_t bytes = (8 * sizeof(ScalarType) + 3 * sizeof(bool)) * threadsPerBlock[0u] * elemsPerThread[0u]; return bytes; @@ -1130,14 +1125,14 @@ namespace alpaka::trait { }; //! The trait for getting the size of the block shared dynamic memory for Kernel_time_compute_findamplchi2_and_finish. - template - struct BlockSharedMemDynSizeBytes { + template <> + struct BlockSharedMemDynSizeBytes { template ALPAKA_FN_HOST_ACC static auto getBlockSharedMemDynSizeBytes(Kernel_time_compute_findamplchi2_and_finish const&, TVec const& threadsPerBlock, TVec const& elemsPerThread, TArgs const&...) -> std::size_t { - using ScalarType = ecal::multifit::SampleVector::Scalar; + using ScalarType = ::ecal::multifit::SampleVector::Scalar; std::size_t bytes = 2 * threadsPerBlock[0u] * elemsPerThread[0u] * sizeof(ScalarType); return bytes; @@ -1145,14 +1140,14 @@ namespace alpaka::trait { }; //! The trait for getting the size of the block shared dynamic memory for Kernel_time_computation_init. - template - struct BlockSharedMemDynSizeBytes { + template <> + struct BlockSharedMemDynSizeBytes { template ALPAKA_FN_HOST_ACC static auto getBlockSharedMemDynSizeBytes(Kernel_time_computation_init const&, TVec const& threadsPerBlock, TVec const& elemsPerThread, TArgs const&...) -> std::size_t { - using ScalarType = ecal::multifit::SampleVector::Scalar; + using ScalarType = ::ecal::multifit::SampleVector::Scalar; std::size_t bytes = 2 * threadsPerBlock[0u] * elemsPerThread[0u] * sizeof(ScalarType); return bytes; diff --git a/RecoLocalCalo/HGCalRecProducers/plugins/alpaka/HGCalLayerClustersSoAAlgoWrapper.dev.cc b/RecoLocalCalo/HGCalRecProducers/plugins/alpaka/HGCalLayerClustersSoAAlgoWrapper.dev.cc index fcbd1d328ab3e..a68c66ab5b315 100644 --- a/RecoLocalCalo/HGCalRecProducers/plugins/alpaka/HGCalLayerClustersSoAAlgoWrapper.dev.cc +++ b/RecoLocalCalo/HGCalRecProducers/plugins/alpaka/HGCalLayerClustersSoAAlgoWrapper.dev.cc @@ -13,8 +13,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE { // Set energy and number of hits in each clusters class HGCalLayerClustersSoAAlgoKernelEnergy { public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, const unsigned int numer_of_clusters, const HGCalSoARecHitsDeviceCollection::ConstView input_rechits_soa, const HGCalSoARecHitsExtraDeviceCollection::ConstView input_clusters_soa, @@ -38,8 +37,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE { // Kernel to find the max for every cluster class HGCalLayerClustersSoAAlgoKernelPositionByHits { public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, const unsigned int numer_of_clusters, float thresholdW0, float positionDeltaRho2, @@ -83,8 +81,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE { // Real Kernel position class HGCalLayerClustersSoAAlgoKernelPositionByHits2 { public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, const unsigned int numer_of_clusters, float thresholdW0, float positionDeltaRho2, @@ -121,8 +118,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE { // Besides the final position, add also the DetId of the seed of each cluster class HGCalLayerClustersSoAAlgoKernelPositionByHits3 { public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, const unsigned int numer_of_clusters, float thresholdW0, float positionDeltaRho2, diff --git a/RecoLocalCalo/HcalRecProducers/plugins/alpaka/Mahi.dev.cc b/RecoLocalCalo/HcalRecProducers/plugins/alpaka/Mahi.dev.cc index 5f4b721d31ae1..62bb71b5b4c3c 100644 --- a/RecoLocalCalo/HcalRecProducers/plugins/alpaka/Mahi.dev.cc +++ b/RecoLocalCalo/HcalRecProducers/plugins/alpaka/Mahi.dev.cc @@ -268,8 +268,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE { class Kernel_prep1d_sameNumberOfSamples { public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc2D const& acc, OProductType::View outputGPU, IProductTypef01::ConstView f01HEDigis, IProductTypef5::ConstView f5HBDigis, @@ -748,8 +747,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE { class Kernel_prep_pulseMatrices_sameNumberOfSamples { public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc3D const& acc, float* pulseMatrices, float* pulseMatricesM, float* pulseMatricesP, @@ -968,8 +966,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE { template class Kernel_minimize { public: - template >> - ALPAKA_FN_ACC void operator()(TAcc const& acc, + ALPAKA_FN_ACC void operator()(Acc1D const& acc, OProductType::View outputGPU, float const* amplitudes, float* pulseMatrices, @@ -1408,11 +1405,12 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE { } // namespace ALPAKA_ACCELERATOR_NAMESPACE namespace alpaka::trait { + using namespace ALPAKA_ACCELERATOR_NAMESPACE; using namespace ALPAKA_ACCELERATOR_NAMESPACE::hcal::reconstruction::mahi; //! The trait for getting the size of the block shared dynamic memory for Kernel_prep_1d_and_initialize. - template - struct BlockSharedMemDynSizeBytes { + template <> + struct BlockSharedMemDynSizeBytes { //! \return The size of the shared memory allocated for a block. template ALPAKA_FN_HOST_ACC static auto getBlockSharedMemDynSizeBytes(Kernel_prep1d_sameNumberOfSamples const&, @@ -1431,8 +1429,8 @@ namespace alpaka::trait { }; //! The trait for getting the size of the block shared dynamic memory for kernel_minimize. - template - struct BlockSharedMemDynSizeBytes, TAcc> { + template + struct BlockSharedMemDynSizeBytes, Acc1D> { //! \return The size of the shared memory allocated for a block. template ALPAKA_FN_HOST_ACC static auto getBlockSharedMemDynSizeBytes(Kernel_minimize const&,