#include <AlpakaService.h>
Definition at line 17 of file AlpakaService.h.
◆ AlpakaService()
Definition at line 24 of file AlpakaService.cc.
References l1ct::clear(), cms::alpakatools::devices(), CUDAService::enabled(), enabled_, ForwardName::getName(), dqmiodumpmetadata::n, Skims_PA_cff::name, MillePedeFileConverter_cfg::out, AlCaHLTBitMon_QueryRunRegistry::string, and makePlotsFromDump::suffix.
27 #ifdef ALPAKA_ACC_GPU_CUDA_ENABLED 30 #endif // ALPAKA_ACC_GPU_CUDA_ENABLED 41 #ifdef ALPAKA_ACC_GPU_CUDA_ENABLED 42 if (not cudaService->
enabled()) {
47 #endif // ALPAKA_ACC_GPU_CUDA_ENABLED 50 auto const&
devices = cms::alpakatools::devices<Platform>();
52 const std::string platform = boost::core::demangle(
typeid(Platform).
name());
53 edm::LogWarning(
"AlpakaService") <<
"Could not find any devices on platform " << platform <<
".\n" 54 <<
"Disabling " << ALPAKA_TYPE_ALIAS_NAME(
AlpakaService) <<
".";
60 const char*
suffix[] = {
"s.",
":",
"s:"};
63 out << ALPAKA_TYPE_ALIAS_NAME(
AlpakaService) <<
" succesfully initialised.\n";
64 out <<
"Found " <<
n <<
" device" <<
suffix[
n < 2 ?
n : 2];
65 for (
auto const& device :
devices) {
71 cms::alpakatools::getQueueCache<Queue>().
clear();
72 cms::alpakatools::getEventCache<Event>().
clear();
75 cms::alpakatools::getHostCachingAllocator<Queue>();
76 for (
auto const& device :
devices)
77 cms::alpakatools::getDeviceCachingAllocator<Device, Queue>(device);
AlpakaService(edm::ParameterSet const &config, edm::ActivityRegistry &)
Log< level::Info, false > LogInfo
std::string getName(const G4String &)
Log< level::Warning, false > LogWarning
◆ ~AlpakaService()
ALPAKA_ACCELERATOR_NAMESPACE::AlpakaService::~AlpakaService |
( |
| ) |
|
Definition at line 80 of file AlpakaService.cc.
References l1ct::clear().
82 cms::alpakatools::getHostCachingAllocator<Queue>().freeAllCached();
83 for (
auto const& device : cms::alpakatools::devices<Platform>())
84 cms::alpakatools::getDeviceCachingAllocator<Device, Queue>(device).freeAllCached();
87 cms::alpakatools::getQueueCache<Queue>().
clear();
88 cms::alpakatools::getEventCache<Event>().
clear();
◆ enabled()
bool ALPAKA_ACCELERATOR_NAMESPACE::AlpakaService::enabled |
( |
| ) |
const |
|
inline |
◆ fillDescriptions()
◆ enabled_
bool ALPAKA_ACCELERATOR_NAMESPACE::AlpakaService::enabled_ = false |
|
private |
◆ verbose_
bool ALPAKA_ACCELERATOR_NAMESPACE::AlpakaService::verbose_ = false |
|
private |