Skip to content
Snippets Groups Projects
Commit 5a34ddcc authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

Code formatting

parent f9d4ed3b
Branches
Tags
1 merge request!320Dopair1 vectorisation merge
......@@ -413,7 +413,6 @@ __attribute__((always_inline)) INLINE void cache_read_two_partial_cells_sorted(
cj_cache->vy[i] = 1.f;
cj_cache->vz[i] = 1.f;
}
}
/* @brief Clean the memory allocated by a #cache object.
......
......@@ -991,7 +991,7 @@ void runner_dopair1_density_vec(struct runner *r, struct cell *ci,
if (!cell_is_drifted(ci, e) || !cell_is_drifted(cj, e))
error("Interacting undrifted cells.");
/* Get the sort ID. */
double shift[3] = {0.0, 0.0, 0.0};
const int sid = space_getsid(e->s, &ci, &cj, shift);
......
......@@ -109,10 +109,12 @@
/* Performs a horizontal add on the vector and adds the result to a float. */
#ifdef __ICC
#define VEC_HADD(a, b) b += _mm512_reduce_add_ps(a.v)
#else /* _mm512_reduce_add_ps not present in GCC compiler. TODO: Implement intrinsic version.*/
#define VEC_HADD(a, b) { \
for( int i=0; i<VEC_SIZE; i++) b += a.f[i]; \
}
#else /* _mm512_reduce_add_ps not present in GCC compiler. \
TODO: Implement intrinsic version.*/
#define VEC_HADD(a, b) \
{ \
for (int i = 0; i < VEC_SIZE; i++) b += a.f[i]; \
}
#endif
/* Calculates the number of set bits in the mask and adds the result to an int.
*/
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment