Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
SWIFT
SWIFTsim
Commits
5a34ddcc
Commit
5a34ddcc
authored
Apr 30, 2017
by
Matthieu Schaller
Browse files
Code formatting
parent
f9d4ed3b
Changes
3
Hide whitespace changes
Inline
Side-by-side
src/cache.h
View file @
5a34ddcc
...
...
@@ -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.
...
...
src/runner_doiact_vec.c
View file @
5a34ddcc
...
...
@@ -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
);
...
...
src/vector.h
View file @
5a34ddcc
...
...
@@ -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.
*/
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment