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
4debd3c4
Commit
4debd3c4
authored
Nov 08, 2016
by
Matthieu Schaller
Browse files
Only sort particles in top-level cells if you have particles
parent
fcbab9ea
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/space.c
View file @
4debd3c4
...
...
@@ -600,7 +600,7 @@ void space_rebuild(struct space *s, int verbose) {
#endif
/* WITH_MPI */
/* Sort the parts according to their cells. */
space_parts_sort
(
s
,
ind
,
nr_parts
,
0
,
s
->
nr_cells
-
1
,
verbose
);
if
(
nr_parts
>
0
)
space_parts_sort
(
s
,
ind
,
nr_parts
,
0
,
s
->
nr_cells
-
1
,
verbose
);
/* Re-link the gparts. */
if
(
nr_parts
>
0
&&
nr_gparts
>
0
)
part_relink_gparts
(
s
->
parts
,
nr_parts
,
0
);
...
...
@@ -660,7 +660,7 @@ void space_rebuild(struct space *s, int verbose) {
#endif
/* Sort the gparts according to their cells. */
space_gparts_sort
(
s
,
gind
,
nr_gparts
,
0
,
s
->
nr_cells
-
1
,
verbose
);
if
(
nr_gparts
>
0
)
space_gparts_sort
(
s
,
gind
,
nr_gparts
,
0
,
s
->
nr_cells
-
1
,
verbose
);
/* Re-link the parts. */
if
(
nr_parts
>
0
&&
nr_gparts
>
0
)
...
...
Matthieu Schaller
@matthieu
mentioned in issue
#240 (closed)
·
Nov 08, 2016
mentioned in issue
#240 (closed)
mentioned in issue #240
Toggle commit list
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