From 334b45d3c251a9c33515225cb92b6dbcf9092765 Mon Sep 17 00:00:00 2001 From: Matti Kortelainen Date: Thu, 16 Feb 2023 16:26:57 +0100 Subject: [PATCH] Remove call to alpaka::getDev() in test code when allocating TestDeviceCollection I don't remember why I used alpaka::getDev(), and I can't now think of any good reason for that. --- .../AlpakaTest/plugins/alpaka/TestAlpakaGlobalProducer.cc | 2 +- .../AlpakaTest/plugins/alpaka/TestAlpakaGlobalProducerOffset.cc | 2 +- .../AlpakaTest/plugins/alpaka/TestAlpakaStreamProducer.cc | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/HeterogeneousCore/AlpakaTest/plugins/alpaka/TestAlpakaGlobalProducer.cc b/HeterogeneousCore/AlpakaTest/plugins/alpaka/TestAlpakaGlobalProducer.cc index 952f614fed3ba..84afac96b78d3 100644 --- a/HeterogeneousCore/AlpakaTest/plugins/alpaka/TestAlpakaGlobalProducer.cc +++ b/HeterogeneousCore/AlpakaTest/plugins/alpaka/TestAlpakaGlobalProducer.cc @@ -29,7 +29,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE { void produce(edm::StreamID, device::Event& iEvent, device::EventSetup const& iSetup) const override { [[maybe_unused]] auto const& esData = iSetup.getData(esToken_); - portabletest::TestDeviceCollection deviceProduct{size_, alpaka::getDev(iEvent.queue())}; + portabletest::TestDeviceCollection deviceProduct{size_, iEvent.queue()}; // run the algorithm, potentially asynchronously algo_.fill(iEvent.queue(), deviceProduct); diff --git a/HeterogeneousCore/AlpakaTest/plugins/alpaka/TestAlpakaGlobalProducerOffset.cc b/HeterogeneousCore/AlpakaTest/plugins/alpaka/TestAlpakaGlobalProducerOffset.cc index a43afada0f586..5e4364b66ce75 100644 --- a/HeterogeneousCore/AlpakaTest/plugins/alpaka/TestAlpakaGlobalProducerOffset.cc +++ b/HeterogeneousCore/AlpakaTest/plugins/alpaka/TestAlpakaGlobalProducerOffset.cc @@ -30,7 +30,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE { void produce(edm::StreamID, device::Event& iEvent, device::EventSetup const& iSetup) const override { auto const& esData = iSetup.getData(esToken_); - portabletest::TestDeviceCollection deviceProduct{esData->metadata().size(), alpaka::getDev(iEvent.queue())}; + portabletest::TestDeviceCollection deviceProduct{esData->metadata().size(), iEvent.queue()}; // run the algorithm, potentially asynchronously algo_.fill(iEvent.queue(), deviceProduct, x_); diff --git a/HeterogeneousCore/AlpakaTest/plugins/alpaka/TestAlpakaStreamProducer.cc b/HeterogeneousCore/AlpakaTest/plugins/alpaka/TestAlpakaStreamProducer.cc index f4f9ff60104e4..3d83f637647c3 100644 --- a/HeterogeneousCore/AlpakaTest/plugins/alpaka/TestAlpakaStreamProducer.cc +++ b/HeterogeneousCore/AlpakaTest/plugins/alpaka/TestAlpakaStreamProducer.cc @@ -34,7 +34,7 @@ namespace ALPAKA_ACCELERATOR_NAMESPACE { [[maybe_unused]] auto inpData = iEvent.getHandle(getToken_); [[maybe_unused]] auto const& esData = iSetup.getData(esToken_); - auto deviceProduct = std::make_unique(size_, alpaka::getDev(iEvent.queue())); + auto deviceProduct = std::make_unique(size_, iEvent.queue()); // run the algorithm, potentially asynchronously algo_.fill(iEvent.queue(), *deviceProduct);