Commit 6ad43f47 authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

Merge branch 'black_hole_tasks' into star_formation_mpi_comms

Conflicts:
	tools/task_plots/analyse_tasks.py
	tools/task_plots/plot_tasks.py
parents 5ee42c0f 9355dbdd
......@@ -20,6 +20,9 @@ Snapshots:
delta_time: 0.2 # Time difference between consecutive outputs (in internal units)
compression: 1
Scheduler:
links_per_tasks: 75
# Parameters governing the conserved quantities statistics
Statistics:
delta_time: 1e-2 # Time between statistics output
......
......@@ -72,7 +72,7 @@ Scheduler:
cell_extra_sparts: 400 # (Optional) Number of spare sparts per top-level allocated at rebuild time for on-the-fly creation.
max_top_level_cells: 12 # (Optional) Maximal number of top-level cells in any dimension. The number of top-level cells will be the cube of this (this is the default value).
tasks_per_cell: 0.0 # (Optional) The average number of tasks per cell. If not large enough the simulation will fail (means guess...).
links_per_tasks: 10 # (Optional) The average number of links per tasks (before adding the communication tasks). If not large enough the simulation will fail (means guess...). Defaults to 10.
links_per_tasks: 25 # (Optional) The average number of links per tasks (before adding the communication tasks). If not large enough the simulation will fail (means guess...). Defaults to 10.
mpi_message_limit: 4096 # (Optional) Maximum MPI task message size to send non-buffered, KB.
engine_max_parts_per_ghost: 1000 # (Optional) Maximum number of parts per ghost.
engine_max_sparts_per_ghost: 1000 # (Optional) Maximum number of sparts per ghost.
......
......@@ -4118,6 +4118,7 @@ void engine_unskip(struct engine *e) {
const int with_ext_grav = e->policy & engine_policy_external_gravity;
const int with_stars = e->policy & engine_policy_stars;
const int with_feedback = e->policy & engine_policy_feedback;
const int with_black_holes = e->policy & engine_policy_black_holes;
#ifdef WITH_PROFILER
static int count = 0;
......@@ -4137,7 +4138,8 @@ void engine_unskip(struct engine *e) {
(with_ext_grav && c->nodeID == nodeID &&
cell_is_active_gravity(c, e)) ||
(with_feedback && cell_is_active_stars(c, e)) ||
(with_stars && c->nodeID == nodeID && cell_is_active_stars(c, e))) {
(with_stars && c->nodeID == nodeID && cell_is_active_stars(c, e)) ||
(with_black_holes && cell_is_active_black_holes(c, e))) {
if (num_active_cells != k)
memswap(&local_cells[k], &local_cells[num_active_cells], sizeof(int));
......@@ -5513,7 +5515,7 @@ void engine_config(int restart, struct engine *e, struct swift_params *params,
/* Estimated number of links per tasks */
e->links_per_tasks =
parser_get_opt_param_int(params, "Scheduler:links_per_tasks", 15);
parser_get_opt_param_int(params, "Scheduler:links_per_tasks", 25);
/* Init the scheduler. */
scheduler_init(&e->sched, e->s, maxtasks, nr_queues,
......
......@@ -2064,7 +2064,6 @@ void engine_make_extra_hydroloop_tasks_mapper(void *map_data, int num_elements,
scheduler_addunlock(sched, ci->hydro.super->black_holes.drift,
t_bh_density);
scheduler_addunlock(sched, ci->hydro.super->hydro.drift, t_bh_density);
scheduler_addunlock(sched, ci->hydro.super->hydro.sorts, t_bh_density);
scheduler_addunlock(sched, ci->hydro.super->black_holes.black_holes_in,
t_bh_density);
scheduler_addunlock(sched, t_bh_density,
......
......@@ -248,6 +248,8 @@ void space_rebuild_recycle_mapper(void *map_data, int num_elements,
c->stars.stars_in = NULL;
c->stars.stars_out = NULL;
c->black_holes.drift = NULL;
c->black_holes.black_holes_in = NULL;
c->black_holes.black_holes_out = NULL;
c->grav.drift = NULL;
c->grav.drift_out = NULL;
c->hydro.cooling = NULL;
......
......@@ -121,6 +121,7 @@ SUBTYPES = [
"tend_part",
"tend_gpart",
"tend_spart",
"tend_bpart",
"xv",
"rho",
"gpart",
......@@ -129,6 +130,7 @@ SUBTYPES = [
"stars_density",
"stars_feedback",
"sf_counts"
"bpart",
"bh_density",
"bh_feedback",
"count",
......
......@@ -206,6 +206,7 @@ SUBTYPES = [
"tend_part",
"tend_gpart",
"tend_spart",
"tend_bpart",
"xv",
"rho",
"gpart",
......@@ -214,6 +215,7 @@ SUBTYPES = [
"stars_density",
"stars_feedback",
"sf_counts",
"bpart",
"bh_density",
"bh_feedback",
"count",
......@@ -249,12 +251,16 @@ FULLTYPES = [
"send/tend_gpart",
"recv/tend_spart",
"send/tend_spart",
"recv/tend_bpart",
"send/tend_bpart",
"recv/gpart",
"send/gpart",
"recv/spart",
"send/spart",
"send/sf_counts",
"recv/sf_counts",
"recv/bpart",
"send/bpart",
"self/stars_density",
"pair/stars_density",
"sub_self/stars_density",
......
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