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

Use the same sorted-cell check in DOPAIR_SUBSET as the other DOPAIR functions.

parent 355f322c
No related branches found
No related tags found
1 merge request!343Subset sorting
...@@ -634,8 +634,10 @@ void DOPAIR_SUBSET(struct runner *r, struct cell *restrict ci, ...@@ -634,8 +634,10 @@ void DOPAIR_SUBSET(struct runner *r, struct cell *restrict ci,
const int flipped = runner_flip[sid]; const int flipped = runner_flip[sid];
sid = sortlistID[sid]; sid = sortlistID[sid];
/* Have the cells been sorted? */ /* Has the cell cj been sorted? */
if (!(cj->sorted & (1 << sid))) error("Interacting unsorted cells."); if (!(cj->sorted & (1 << sid)) ||
cj->dx_max_sort_old > space_maxreldx * cj->dmin)
error("Interacting unsorted cells.");
/* Pick-out the sorted lists. */ /* Pick-out the sorted lists. */
const struct entry *restrict sort_j = &cj->sort[sid * (cj->count + 1)]; const struct entry *restrict sort_j = &cj->sort[sid * (cj->count + 1)];
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment