Commit b6954567 authored by Matthieu Schaller's avatar Matthieu Schaller Committed by Matthieu Schaller
Browse files

Make sure the new task is activated correctly.

parent 101181ae
......@@ -2302,6 +2302,7 @@ int cell_unskip_gravity_tasks(struct cell *c, struct scheduler *s) {
if (c->timestep != NULL) scheduler_activate(s, c->timestep);
if (c->end_force != NULL) scheduler_activate(s, c->end_force);
if (c->grav_down != NULL) scheduler_activate(s, c->grav_down);
if (c->grav_mesh != NULL) scheduler_activate(s, c->grav_mesh);
if (c->grav_long_range != NULL) scheduler_activate(s, c->grav_long_range);
}
......
......@@ -3592,7 +3592,7 @@ void engine_marktasks_mapper(void *map_data, int num_elements,
}
/* Gravity stuff ? */
else if (t->type == task_type_grav_down ||
else if (t->type == task_type_grav_down || t->type == task_type_grav_mesh ||
t->type == task_type_grav_long_range ||
t->type == task_type_init_grav) {
if (cell_is_active_gravity(t->ci, e)) scheduler_activate(s, t);
......
......@@ -180,6 +180,7 @@ __attribute__((always_inline)) INLINE static enum task_actions task_acts_on(
case task_type_drift_gpart:
case task_type_grav_down:
case task_type_grav_mesh:
return task_action_gpart;
break;
......@@ -290,6 +291,7 @@ void task_unlock(struct task *t) {
break;
case task_type_drift_gpart:
case task_type_grav_mesh:
cell_gunlocktree(ci);
break;
......@@ -385,6 +387,7 @@ int task_lock(struct task *t) {
break;
case task_type_drift_gpart:
case task_type_grav_mesh:
if (ci->ghold) return 0;
if (cell_glocktree(ci) != 0) return 0;
break;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment