diff options
-rw-r--r-- | Source/Laser/LaserParticleContainer.H | 28 | ||||
-rw-r--r-- | Source/Laser/LaserParticleContainer.cpp | 9 | ||||
-rw-r--r-- | Source/Laser/LaserProfiles.cpp | 8 |
3 files changed, 23 insertions, 22 deletions
diff --git a/Source/Laser/LaserParticleContainer.H b/Source/Laser/LaserParticleContainer.H index a73e9cf15..2fd42f168 100644 --- a/Source/Laser/LaserParticleContainer.H +++ b/Source/Laser/LaserParticleContainer.H @@ -44,23 +44,23 @@ public: virtual void PostRestart () final; - void gaussian_laser_profile (const int np, amrex::Real const * const Xp, - amrex::Real const * const Yp, amrex::Real t, - amrex::Real * const amplitude); + void gaussian_laser_profile (const int np, amrex::Real const * AMREX_RESTRICT const Xp, + amrex::Real const * AMREX_RESTRICT const Yp, amrex::Real t, + amrex::Real * AMREX_RESTRICT const amplitude); - void harris_laser_profile (const int np, amrex::Real const * const Xp, - amrex::Real const * const Yp, amrex::Real t, - amrex::Real * const amplitude); + void harris_laser_profile (const int np, amrex::Real const * AMREX_RESTRICT const Xp, + amrex::Real const * AMREX_RESTRICT const Yp, amrex::Real t, + amrex::Real * AMREX_RESTRICT const amplitude); void calculate_laser_plane_coordinates (const int np, const int thread_num, - amrex::Real * const AMREX_RESTRICT pplane_Xp, - amrex::Real * const AMREX_RESTRICT pplane_Yp); - - void update_laser_particle (const int np, amrex::Real * const puxp, - amrex::Real * const puyp, - amrex::Real * const puzp, - amrex::Real * const pwp, - amrex::Real const * const amplitude, + amrex::Real * AMREX_RESTRICT const pplane_Xp, + amrex::Real * AMREX_RESTRICT const pplane_Yp); + + void update_laser_particle (const int np, amrex::Real * AMREX_RESTRICT const puxp, + amrex::Real * AMREX_RESTRICT const puyp, + amrex::Real * AMREX_RESTRICT const puzp, + amrex::Real * AMREX_RESTRICT const pwp, + amrex::Real const * AMREX_RESTRICT const amplitude, const amrex::Real dt, const int thread_num); protected: diff --git a/Source/Laser/LaserParticleContainer.cpp b/Source/Laser/LaserParticleContainer.cpp index d57081957..9699ee06b 100644 --- a/Source/Laser/LaserParticleContainer.cpp +++ b/Source/Laser/LaserParticleContainer.cpp @@ -611,8 +611,8 @@ LaserParticleContainer::PushP (int lev, Real dt, void LaserParticleContainer::calculate_laser_plane_coordinates ( const int np, const int thread_num, - Real * const AMREX_RESTRICT pplane_Xp, - Real * const AMREX_RESTRICT pplane_Yp) + Real * AMREX_RESTRICT const pplane_Xp, + Real * AMREX_RESTRICT const pplane_Yp) { Real const * const AMREX_RESTRICT xp = m_xp[thread_num].dataPtr(); Real const * const AMREX_RESTRICT yp = m_yp[thread_num].dataPtr(); @@ -662,8 +662,9 @@ LaserParticleContainer::calculate_laser_plane_coordinates ( */ void LaserParticleContainer::update_laser_particle( - const int np, Real * const puxp, Real * const puyp, Real * const puzp, - Real * const pwp, Real const * const amplitude, const Real dt, + const int np, Real * AMREX_RESTRICT const puxp, Real * AMREX_RESTRICT const puyp, + Real * AMREX_RESTRICT const puzp, Real * AMREX_RESTRICT const pwp, + Real const * AMREX_RESTRICT const amplitude, const Real dt, const int thread_num) { Real * const AMREX_RESTRICT xp = m_xp[thread_num].dataPtr(); diff --git a/Source/Laser/LaserProfiles.cpp b/Source/Laser/LaserProfiles.cpp index 80197b54a..704107c2d 100644 --- a/Source/Laser/LaserProfiles.cpp +++ b/Source/Laser/LaserProfiles.cpp @@ -18,8 +18,8 @@ using namespace amrex; */ void LaserParticleContainer::gaussian_laser_profile ( - const int np, Real const * const Xp, Real const * const Yp, - Real t, Real * const amplitude) + const int np, Real const * AMREX_RESTRICT const Xp, Real const * AMREX_RESTRICT const Yp, + Real t, Real * AMREX_RESTRICT const amplitude) { Complex I(0,1); // Calculate a few factors which are independent of the macroparticle @@ -90,8 +90,8 @@ LaserParticleContainer::gaussian_laser_profile ( */ void LaserParticleContainer::harris_laser_profile ( - const int np, Real const * const Xp, Real const * const Yp, - Real t, Real * const amplitude) + const int np, Real const * AMREX_RESTRICT const Xp, Real const * AMREX_RESTRICT const Yp, + Real t, Real * AMREX_RESTRICT const amplitude) { // This function uses the Harris function as the temporal profile of the pulse const Real omega0 = 2.*MathConst::pi*PhysConst::c/wavelength; |