diff --git a/src/cell.h b/src/cell.h index e8e5a9fbc304fd7c8b6974ed5b5ad2119da5ffc2..26ffbfd12162d395d1c18ef73ef3b7495aeec90a 100644 --- a/src/cell.h +++ b/src/cell.h @@ -428,9 +428,6 @@ struct cell { /*! Task propagating the multipole to the particles */ struct task *down; - /*! Tasks for FOF */ - struct task *fof_self, *fof_pair; - /*! Number of M-M tasks that are associated with this cell. */ short int nr_mm_tasks; @@ -828,6 +825,19 @@ cell_can_split_self_gravity_task(const struct cell *c) { return c->split && c->depth < space_subdepth_grav; } +/** + * @brief Can a self FOF task associated with a cell be split into smaller + * sub-tasks. + * + * @param c The #cell. + */ +__attribute__((always_inline)) INLINE static int cell_can_split_self_fof_task( + const struct cell *c) { + + /* Is the cell split ? */ + return c->split && c->grav.count > 400 && c->depth < 4; +} + /** * @brief Have particles in a pair of cells moved too much and require a rebuild * ?