#include <ElectronicsMappingGPU.h>
Definition at line 14 of file ElectronicsMappingGPU.h.
◆ ElectronicsMappingGPU()
hcal::raw::ElectronicsMappingGPU::ElectronicsMappingGPU |
( |
HcalElectronicsMap const & |
mapping | ) |
|
Definition at line 12 of file ElectronicsMappingGPU.cc.
References runTauDisplay::eid, eid2did_, eid2tid_, mps_fire::i, and taus_updatedMVAIds_cff::mapping.
14 auto const& eidsPrecision =
mapping.allElectronicsIdPrecision();
15 for (uint32_t
i = 0;
i < eidsPrecision.size(); ++
i) {
16 auto const&
eid = eidsPrecision[
i];
22 auto const& eidsTrigger =
mapping.allElectronicsIdTrigger();
23 for (uint32_t
i = 0;
i < eidsTrigger.size();
i++) {
24 auto const&
eid = eidsTrigger[
i];
std::vector< uint32_t, cms::cuda::HostAllocator< uint32_t > > eid2did_
static const int maxLinearIndex
std::vector< uint32_t, cms::cuda::HostAllocator< uint32_t > > eid2tid_
◆ ~ElectronicsMappingGPU()
hcal::raw::ElectronicsMappingGPU::~ElectronicsMappingGPU |
( |
| ) |
|
|
default |
◆ getProduct()
Definition at line 37 of file ElectronicsMappingGPU.cc.
References cudaCheck, hcal::raw::ElectronicsMappingGPU::Product::eid2did, eid2did_, hcal::raw::ElectronicsMappingGPU::Product::eid2tid, eid2tid_, and product_.
38 auto const& product =
product_.dataForCurrentDeviceAsync(
39 cudaStream, [
this](ElectronicsMappingGPU::Product& product, cudaStream_t cudaStream) {
41 cudaCheck(cudaMalloc((
void**)&product.eid2did, this->eid2did_.size() *
sizeof(uint32_t)));
42 cudaCheck(cudaMalloc((
void**)&product.eid2tid, this->eid2tid_.size() *
sizeof(uint32_t)));
45 cudaCheck(cudaMemcpyAsync(product.eid2did,
46 this->eid2did_.data(),
47 this->
eid2did_.size() *
sizeof(uint32_t),
48 cudaMemcpyHostToDevice,
50 cudaCheck(cudaMemcpyAsync(product.eid2tid,
51 this->eid2tid_.data(),
52 this->
eid2tid_.size() *
sizeof(uint32_t),
53 cudaMemcpyHostToDevice,
std::vector< uint32_t, cms::cuda::HostAllocator< uint32_t > > eid2did_
cms::cuda::ESProduct< Product > product_
#define cudaCheck(ARG,...)
std::vector< uint32_t, cms::cuda::HostAllocator< uint32_t > > eid2tid_
◆ eid2did_
◆ eid2tid_
◆ product_