Commit eb8ebccc authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

task_type_psort --> task_type_part_sort

parent 74bca7ae
...@@ -755,7 +755,7 @@ void engine_maketasks(struct engine *e) { ...@@ -755,7 +755,7 @@ void engine_maketasks(struct engine *e) {
/* Add the space sorting tasks. */ /* Add the space sorting tasks. */
for (int i = 0; i < e->nr_threads; i++) for (int i = 0; i < e->nr_threads; i++)
scheduler_addtask(sched, task_type_psort, task_subtype_none, i, 0, NULL, scheduler_addtask(sched, task_type_part_sort, task_subtype_none, i, 0, NULL,
NULL, 0); NULL, 0);
/* Run through the highest level of cells and add pairs. */ /* Run through the highest level of cells and add pairs. */
...@@ -2050,7 +2050,7 @@ void engine_init(struct engine *e, struct space *s, float dt, int nr_threads, ...@@ -2050,7 +2050,7 @@ void engine_init(struct engine *e, struct space *s, float dt, int nr_threads,
/* Create the sorting tasks. */ /* Create the sorting tasks. */
for (int i = 0; i < e->nr_threads; i++) for (int i = 0; i < e->nr_threads; i++)
scheduler_addtask(&e->sched, task_type_psort, task_subtype_none, i, 0, NULL, scheduler_addtask(&e->sched, task_type_part_sort, task_subtype_none, i, 0, NULL,
NULL, 0); NULL, 0);
scheduler_ranktasks(&e->sched); scheduler_ranktasks(&e->sched);
......
...@@ -1057,7 +1057,7 @@ void *runner_main(void *data) { ...@@ -1057,7 +1057,7 @@ void *runner_main(void *data) {
case task_type_grav_down: case task_type_grav_down:
runner_dograv_down(r, t->ci); runner_dograv_down(r, t->ci);
break; break;
case task_type_psort: case task_type_part_sort:
space_do_parts_sort(); space_do_parts_sort();
break; break;
case task_type_split_cell: case task_type_split_cell:
......
...@@ -127,7 +127,7 @@ void scheduler_splittasks(struct scheduler *s) { ...@@ -127,7 +127,7 @@ void scheduler_splittasks(struct scheduler *s) {
} }
/* Skip sorting tasks. */ /* Skip sorting tasks. */
if (t->type == task_type_psort) continue; if (t->type == task_type_part_sort) continue;
/* Empty task? */ /* Empty task? */
if (t->ci == NULL || (t->type == task_type_pair && t->cj == NULL)) { if (t->ci == NULL || (t->type == task_type_pair && t->cj == NULL)) {
......
...@@ -582,7 +582,7 @@ void space_parts_sort(struct space *s, size_t *ind, size_t N, int min, int max, ...@@ -582,7 +582,7 @@ void space_parts_sort(struct space *s, size_t *ind, size_t N, int min, int max,
space_sort_struct.waiting = 1; space_sort_struct.waiting = 1;
/* Launch the sorting tasks. */ /* Launch the sorting tasks. */
engine_launch(s->e, s->e->nr_threads, (1 << task_type_psort), 0); engine_launch(s->e, s->e->nr_threads, (1 << task_type_part_sort), 0);
/* Verify space_sort_struct. */ /* Verify space_sort_struct. */
/* for (int i = 1; i < N; i++) /* for (int i = 1; i < N; i++)
......
...@@ -45,7 +45,8 @@ ...@@ -45,7 +45,8 @@
const char *taskID_names[task_type_count] = { const char *taskID_names[task_type_count] = {
"none", "sort", "self", "pair", "sub", "init", "none", "sort", "self", "pair", "sub", "init",
"ghost", "drift", "kick", "send", "recv", "grav_pp", "ghost", "drift", "kick", "send", "recv", "grav_pp",
"grav_mm", "grav_up", "grav_down", "psort", "split_cell", "rewait"}; "grav_mm", "grav_up", "grav_down", "part_sort", "gpart_sort",
"split_cell", "rewait"};
const char *subtaskID_names[task_type_count] = {"none", "density", const char *subtaskID_names[task_type_count] = {"none", "density",
"force", "grav"}; "force", "grav"};
...@@ -78,9 +79,9 @@ float task_overlap(const struct task *ta, const struct task *tb) { ...@@ -78,9 +79,9 @@ float task_overlap(const struct task *ta, const struct task *tb) {
/* First check if any of the two tasks are of a type that don't /* First check if any of the two tasks are of a type that don't
use cells. */ use cells. */
if (ta == NULL || tb == NULL || ta->type == task_type_none || if (ta == NULL || tb == NULL || ta->type == task_type_none ||
ta->type == task_type_psort || ta->type == task_type_split_cell || ta->type == task_type_part_sort || ta->type == task_type_split_cell ||
ta->type == task_type_rewait || tb->type == task_type_none || ta->type == task_type_rewait || tb->type == task_type_none ||
tb->type == task_type_psort || tb->type == task_type_split_cell || tb->type == task_type_part_sort || tb->type == task_type_split_cell ||
tb->type == task_type_rewait) tb->type == task_type_rewait)
return 0.0f; return 0.0f;
......
...@@ -45,7 +45,8 @@ enum task_types { ...@@ -45,7 +45,8 @@ enum task_types {
task_type_grav_mm, task_type_grav_mm,
task_type_grav_up, task_type_grav_up,
task_type_grav_down, task_type_grav_down,
task_type_psort, task_type_part_sort,
task_type_gpart_sort,
task_type_split_cell, task_type_split_cell,
task_type_rewait, task_type_rewait,
task_type_count task_type_count
......
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