WarpX
|
This is a functor for performing a "smart copy" that works in both host and device code. More...
#include <SmartCopy.H>
Public Member Functions | |
template<typename DstData , typename SrcData > | |
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void | operator() (DstData &dst, const SrcData &src, int i_src, int i_dst, amrex::RandomEngine const &engine) const noexcept |
Public Attributes | |
int | m_num_copy_real |
const int * | m_src_comps_r |
const int * | m_dst_comps_r |
int | m_num_copy_int |
const int * | m_src_comps_i |
const int * | m_dst_comps_i |
const InitializationPolicy * | m_policy_real |
const InitializationPolicy * | m_policy_int |
This is a functor for performing a "smart copy" that works in both host and device code.
A "smart" copy does the following. First, the destination particle components are initialized to the default values for that component type. Second, if a given component name is found in both the src and the dst, then the src value is copied.
Particle positions and id numbers are always copied.
You don't create this directly - use the SmartCopyFactory object below.
|
inlinenoexcept |
const int* SmartCopy::m_dst_comps_i |
const int* SmartCopy::m_dst_comps_r |
int SmartCopy::m_num_copy_int |
int SmartCopy::m_num_copy_real |
const InitializationPolicy* SmartCopy::m_policy_int |
const InitializationPolicy* SmartCopy::m_policy_real |
const int* SmartCopy::m_src_comps_i |
const int* SmartCopy::m_src_comps_r |