3 #include <Cabana_AoSoA.hpp>
4 #include <Kokkos_Core.hpp>
9 using ParticleDataTypes = Cabana::MemberTypes<double[6],double[3],long long int, long long int>;
46 return *(
reinterpret_cast<const SimdVector*
>(
this));
66 KOKKOS_INLINE_FUNCTION
bool is_active(
int i_simd)
const{
67 return (
gid[i_simd]>0);
71 return (
gid[i_simd]<=0);
77 for (
int i_simd = 0; i_simd<SIMD_SIZE; i_simd++){
112 long long int gid[VEC_LEN];
114 long long int flag[VEC_LEN];
118 return (
gid[i_vec]>0);
122 return (
gid[i_vec]<=0);
147 template<
class Device>
157 template<
class Device>
177 template<
class Device>
Cabana::MemberTypes< double[6]> PhaseDataTypes
Definition: particles.hpp:14
KOKKOS_INLINE_FUNCTION int divide_and_round_up(int a, int b)
Definition: globals.hpp:203
KOKKOS_INLINE_FUNCTION void update_dphm(SimdPhase &dphm, const SimdPhase &dpht)
Definition: particles.tpp:21
KOKKOS_INLINE_FUNCTION const SimdVector & v() const
Definition: particles.hpp:45
KOKKOS_INLINE_FUNCTION void update_phases(SimdPhase &ph_new, const SimdPhase &ph, double local_dt, const SimdPhase &dph)
Definition: particles.tpp:6
KOKKOS_INLINE_FUNCTION void simd_2_AoSoA(VecParticles *part, const SimdParticles &part_one, int a_vec, int s_vec)
Definition: particles.tpp:54
double rho[VEC_LEN]
Definition: particles.hpp:96
KOKKOS_INLINE_FUNCTION AoSoAIndices(int idx)
Definition: particles.hpp:158
Simd< double > w1
Definition: particles.hpp:22
Definition: particles.hpp:102
VecConstants ct
Definition: particles.hpp:111
Definition: particles.hpp:128
int add_vec_buffer(int n_ptl)
Definition: particles.hpp:194
Definition: particles.hpp:92
int a
The index in the inner array of the AoSoA.
Definition: particles.hpp:150
Definition: particles.hpp:109
KOKKOS_INLINE_FUNCTION bool is_active(int i_vec) const
Definition: particles.hpp:117
KOKKOS_INLINE_FUNCTION void update_dpht(SimdPhase &dpht, const SimdPhase &dph, const SimdPhase &dphm)
Definition: particles.tpp:37
KOKKOS_INLINE_FUNCTION bool is_active(int i_simd) const
Definition: particles.hpp:66
KOKKOS_INLINE_FUNCTION void AoSoA_2_simd(SimdParticles &part_one, const VecParticles *part, int a_vec, int s_vec)
Definition: particles.tpp:80
double data[T *VEC_LEN]
Definition: particles.hpp:129
Simd< double > rho
Definition: particles.hpp:21
int p_range< DeviceType >(int num_particle)
Definition: particles.hpp:187
KOKKOS_INLINE_FUNCTION bool is_inactive(int i_vec) const
Definition: particles.hpp:121
double w2[VEC_LEN]
Definition: particles.hpp:98
double mu[VEC_LEN]
Definition: particles.hpp:103
Simd< double > r
Definition: particles.hpp:18
KOKKOS_INLINE_FUNCTION SimdVector2D & x()
Definition: particles.hpp:27
KOKKOS_INLINE_FUNCTION SimdVector & v()
Definition: particles.hpp:39
Definition: particles.hpp:133
double w0[VEC_LEN]
Definition: particles.hpp:104
SimdPhase ph
Definition: particles.hpp:59
long long int gid[VEC_LEN]
Definition: particles.hpp:112
Simd< double > f0
Definition: particles.hpp:54
double f0[VEC_LEN]
Definition: particles.hpp:105
Definition: particles.hpp:58
VecPhase ph
Definition: particles.hpp:110
Definition: particles.hpp:51
double data[T]
Definition: particles.hpp:134
Cabana::MemberTypes< double[6], double[3], long long int > ParticleDataTypes
Definition: particles.hpp:11
int s
The index in the outer array of the AoSoA.
Definition: particles.hpp:149
Simd< double > z
Definition: particles.hpp:19
Simd< long long int > gid
Definition: particles.hpp:61
Simd< double > w0
Definition: particles.hpp:53
KOKKOS_INLINE_FUNCTION void deactivate(int i_simd)
Definition: particles.hpp:85
Simd< double > phi
Definition: particles.hpp:20
Definition: particles.hpp:17
SimdConstants ct
Definition: particles.hpp:60
double phi[VEC_LEN]
Definition: particles.hpp:95
Simd< double > w2
Definition: particles.hpp:23
double r[VEC_LEN]
Definition: particles.hpp:93
int p_range(int num_particle)
Definition: particles.hpp:178
Simd< double > mu
Definition: particles.hpp:52
KOKKOS_INLINE_FUNCTION const SimdVector2D & x() const
Definition: particles.hpp:33
Definition: particles.hpp:148
double z[VEC_LEN]
Definition: particles.hpp:94
KOKKOS_INLINE_FUNCTION void deactivate(const Simd< bool > &mask)
Definition: particles.hpp:76
KOKKOS_INLINE_FUNCTION bool is_inactive(int i_simd) const
Definition: particles.hpp:70
double w1[VEC_LEN]
Definition: particles.hpp:97