CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Private Attributes
TrackingRecHitDevice< TrackerTraits, TDev > Class Template Reference

#include <TrackingRecHitsDevice.h>

Inheritance diagram for TrackingRecHitDevice< TrackerTraits, TDev >:
PortableDeviceCollection< TrackingRecHitLayout< TrackerTraits >, TDev >

Public Types

using hitSoA = TrackingRecHitSoA< TrackerTraits >
 
- Public Types inherited from PortableDeviceCollection< TrackingRecHitLayout< TrackerTraits >, TDev >
using Buffer = cms::alpakatools::device_buffer< TDev, std::byte[]>
 
using ConstBuffer = cms::alpakatools::const_device_buffer< TDev, std::byte[]>
 
using ConstView = typename Layout::ConstView
 
using Layout = TrackingRecHitLayout< TrackerTraits >
 
using View = typename Layout::View
 

Public Member Functions

uint32_t const * hitsModuleStart () const
 
uint32_t nHits () const
 
int32_t offsetBPIX2 () const
 
 TrackingRecHitDevice ()=default
 
template<typename TQueue >
 TrackingRecHitDevice (TQueue queue, uint32_t nHits, int32_t offsetBPIX2, uint32_t const *hitsModuleStart)
 
template<typename TQueue >
void updateFromDevice (TQueue queue)
 
- Public Member Functions inherited from PortableDeviceCollection< TrackingRecHitLayout< TrackerTraits >, TDev >
Buffer buffer ()
 
ConstBuffer buffer () const
 
ConstBuffer const_buffer () const
 
ConstView const & const_view () const
 
Viewoperator* ()
 
ConstView const & operator* () const
 
Viewoperator-> ()
 
ConstView const * operator-> () const
 
PortableDeviceCollectionoperator= (PortableDeviceCollection const &)=delete
 
PortableDeviceCollectionoperator= (PortableDeviceCollection &&)=default
 
 PortableDeviceCollection ()=default
 
 PortableDeviceCollection (int32_t elements, TDev const &device)
 
 PortableDeviceCollection (int32_t elements, TQueue const &queue)
 
 PortableDeviceCollection (PortableDeviceCollection const &)=delete
 
 PortableDeviceCollection (PortableDeviceCollection &&)=default
 
Viewview ()
 
ConstView const & view () const
 
void zeroInitialise (TQueue &&queue)
 
 ~PortableDeviceCollection ()=default
 

Private Attributes

int32_t offsetBPIX2_ = 0
 

Detailed Description

template<typename TrackerTraits, typename TDev>
class TrackingRecHitDevice< TrackerTraits, TDev >

Definition at line 13 of file TrackingRecHitsDevice.h.

Member Typedef Documentation

◆ hitSoA

template<typename TrackerTraits, typename TDev>
using TrackingRecHitDevice< TrackerTraits, TDev >::hitSoA = TrackingRecHitSoA<TrackerTraits>

Definition at line 15 of file TrackingRecHitsDevice.h.

Constructor & Destructor Documentation

◆ TrackingRecHitDevice() [1/2]

template<typename TrackerTraits, typename TDev>
TrackingRecHitDevice< TrackerTraits, TDev >::TrackingRecHitDevice ( )
default

◆ TrackingRecHitDevice() [2/2]

template<typename TrackerTraits, typename TDev>
template<typename TQueue >
TrackingRecHitDevice< TrackerTraits, TDev >::TrackingRecHitDevice ( TQueue  queue,
uint32_t  nHits,
int32_t  offsetBPIX2,
uint32_t const *  hitsModuleStart 
)
inlineexplicit

Definition at line 26 of file TrackingRecHitsDevice.h.

References TrackingRecHitDevice< TrackerTraits, TDev >::offsetBPIX2().

29  auto start_d =
31  alpaka::memcpy(queue, start_d, start_h);
32 
35  alpaka::memcpy(queue, off_d, off_h);
36  }
std::enable_if_t< alpaka::isDevice< TDev > and not std::is_array_v< T >, device_view< TDev, T > > make_device_view(TDev const &device, T &data)
Definition: memory.h:260
constexpr uint16_t numberOfModules
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:80
std::enable_if_t< not std::is_array_v< T >, host_view< T > > make_host_view(T &data)
Definition: memory.h:153
uint32_t const * hitsModuleStart() const

Member Function Documentation

◆ hitsModuleStart()

template<typename TrackerTraits, typename TDev>
uint32_t const* TrackingRecHitDevice< TrackerTraits, TDev >::hitsModuleStart ( ) const
inline

◆ nHits()

template<typename TrackerTraits, typename TDev>
uint32_t TrackingRecHitDevice< TrackerTraits, TDev >::nHits ( ) const
inline

◆ offsetBPIX2()

template<typename TrackerTraits, typename TDev>
int32_t TrackingRecHitDevice< TrackerTraits, TDev >::offsetBPIX2 ( ) const
inline

◆ updateFromDevice()

template<typename TrackerTraits, typename TDev>
template<typename TQueue >
void TrackingRecHitDevice< TrackerTraits, TDev >::updateFromDevice ( TQueue  queue)
inline

Definition at line 46 of file TrackingRecHitsDevice.h.

References cms::alpakatools::make_device_view(), cms::alpakatools::make_host_view(), TrackingRecHitDevice< TrackerTraits, TDev >::offsetBPIX2(), TrackingRecHitDevice< TrackerTraits, TDev >::offsetBPIX2_, createBeamHaloJobs::queue, and PortableDeviceCollection< TrackingRecHitLayout< TrackerTraits >, TDev >::view().

46  {
49  alpaka::memcpy(queue, off_h, off_d);
50  }
std::enable_if_t< alpaka::isDevice< TDev > and not std::is_array_v< T >, device_view< TDev, T > > make_device_view(TDev const &device, T &data)
Definition: memory.h:260
std::enable_if_t< not std::is_array_v< T >, host_view< T > > make_host_view(T &data)
Definition: memory.h:153

Member Data Documentation

◆ offsetBPIX2_

template<typename TrackerTraits, typename TDev>
int32_t TrackingRecHitDevice< TrackerTraits, TDev >::offsetBPIX2_ = 0
private