diff --git a/src/hydro/Gadget2/hydro_iact.h b/src/hydro/Gadget2/hydro_iact.h index 8738b4be09931df4c938f1dff3adeed11468dcfc..d0ab9c04cee5037cbf61c0a617645299446493d5 100644 --- a/src/hydro/Gadget2/hydro_iact.h +++ b/src/hydro/Gadget2/hydro_iact.h @@ -103,6 +103,15 @@ __attribute__((always_inline)) INLINE static void runner_iact_density( pj->density.rot_v[2] += facj * curlvr[2]; } +/** + * @brief Density loop (Vectorized version) + */ +__attribute__((always_inline)) INLINE static void runner_iact_vec_density( + float *R2, float *Dx, float *Hi, float *Hj, struct part **pi, + struct part **pj) { + error("A vectorised version of the Gadget2 density interaction function does not exist yet! Configure with '--disable-vec' to call the non-vectorised version.") +} + /** * @brief Density loop (non-symmetric version) */ @@ -151,6 +160,15 @@ __attribute__((always_inline)) INLINE static void runner_iact_nonsym_density( pi->density.rot_v[2] += fac * curlvr[2]; } +/** + * @brief Density loop (non-symmetric vectorized version) + */ +__attribute__((always_inline)) INLINE static void +runner_iact_nonsym_vec_density(float *R2, float *Dx, float *Hi, float *Hj, + struct part **pi, struct part **pj) { + error("A vectorised version of the Gadget2 non-symmetric density interaction function does not exist yet! Configure with '--disable-vec' to call the non-vectorised version.") +} + /** * @brief Force loop */ @@ -248,6 +266,15 @@ __attribute__((always_inline)) INLINE static void runner_iact_force( pj->entropy_dt -= 0.5f * mi * visc_term * dvdr; } +/** + * @brief Force loop (Vectorized version) + */ +__attribute__((always_inline)) INLINE static void runner_iact_vec_force( + float *R2, float *Dx, float *Hi, float *Hj, struct part **pi, + struct part **pj) { + error("A vectorised version of the Gadget2 force interaction function does not exist yet! Configure with '--disable-vec' to call the non-vectorised version.") +} + /** * @brief Force loop (non-symmetric version) */ @@ -338,4 +365,13 @@ __attribute__((always_inline)) INLINE static void runner_iact_nonsym_force( pi->entropy_dt += 0.5f * mj * visc_term * dvdr; } +/** + * @brief Force loop (Vectorized non-symmetric version) + */ +__attribute__((always_inline)) INLINE static void runner_iact_nonsym_vec_force( + float *R2, float *Dx, float *Hi, float *Hj, struct part **pi, + struct part **pj) { + error("A vectorised version of the Gadget2 non-symmetric density interaction function does not exist yet! Configure with '--disable-vec' to call the non-vectorised version.") +} + #endif /* SWIFT_RUNNER_IACT_LEGACY_H */ diff --git a/src/hydro/Minimal/hydro_iact.h b/src/hydro/Minimal/hydro_iact.h index c9da185b8a29eafe2a58420ae5de3a05ff043225..ba066c980c41650399f68bbbc5f1cee7472b8c71 100644 --- a/src/hydro/Minimal/hydro_iact.h +++ b/src/hydro/Minimal/hydro_iact.h @@ -61,6 +61,15 @@ __attribute__((always_inline)) INLINE static void runner_iact_density( pj->density.wcount_dh -= xj * wj_dx; } +/** + * @brief Density loop (Vectorized version) + */ +__attribute__((always_inline)) INLINE static void runner_iact_vec_density( + float *R2, float *Dx, float *Hi, float *Hj, struct part **pi, + struct part **pj) { + error("A vectorised version of the Minimal density interaction function does not exist yet! Configure with '--disable-vec' to call the non-vectorised version.") +} + /** * @brief Density loop (non-symmetric version) */ @@ -85,6 +94,15 @@ __attribute__((always_inline)) INLINE static void runner_iact_nonsym_density( pi->density.wcount_dh -= xi * wi_dx; } +/** + * @brief Density loop (non-symmetric vectorized version) + */ +__attribute__((always_inline)) INLINE static void +runner_iact_nonsym_vec_density(float *R2, float *Dx, float *Hi, float *Hj, + struct part **pi, struct part **pj) { + error("A vectorised version of the Minimal non-symmetric density interaction function does not exist yet! Configure with '--disable-vec' to call the non-vectorised version.") +} + /** * @brief Force loop */ @@ -157,6 +175,15 @@ __attribute__((always_inline)) INLINE static void runner_iact_force( pj->force.v_sig = fmaxf(pj->force.v_sig, v_sig); } +/** + * @brief Force loop (Vectorized version) + */ +__attribute__((always_inline)) INLINE static void runner_iact_vec_force( + float *R2, float *Dx, float *Hi, float *Hj, struct part **pi, + struct part **pj) { + error("A vectorised version of the Minimal force interaction function does not exist yet! Configure with '--disable-vec' to call the non-vectorised version.") +} + /** * @brief Force loop (non-symmetric version) */ @@ -222,4 +249,14 @@ __attribute__((always_inline)) INLINE static void runner_iact_nonsym_force( pi->force.v_sig = fmaxf(pi->force.v_sig, v_sig); } +/** + * @brief Force loop (Vectorized non-symmetric version) + */ +__attribute__((always_inline)) INLINE static void runner_iact_nonsym_vec_force( + float *R2, float *Dx, float *Hi, float *Hj, struct part **pi, + struct part **pj) { + error("A vectorised version of the Minimal non-symmetric density interaction function does not exist yet! Configure with '--disable-vec' to call the non-vectorised version.") +} + + #endif /* SWIFT_RUNNER_IACT_MINIMAL_H */