diff --git a/examples/main_fof.c b/examples/main_fof.c index 104f2563d16b12adb490e98c1269c1918bfd4ece..af0e482cafe16805250fabee16bbfdf14504e530 100644 --- a/examples/main_fof.c +++ b/examples/main_fof.c @@ -688,7 +688,7 @@ int main(int argc, char *argv[]) { /* Perform the FOF search */ engine_fof(&e, /*dump_results=*/1, /*dump_debug=*/0, /*seed_black_holes=*/0, - /*buffers allocated=*/1); + /*buffers allocated=*/1); /* Write output. */ engine_dump_snapshot(&e); diff --git a/src/engine.h b/src/engine.h index cc911195a0e7210027636acb8b1df7a065c29360..248df75026519061f7e5f2944448d152eeddb809 100644 --- a/src/engine.h +++ b/src/engine.h @@ -635,7 +635,7 @@ int engine_estimate_nr_tasks(const struct engine *e); void engine_print_task_counts(const struct engine *e); void engine_fof(struct engine *e, const int dump_results, const int dump_debug_results, const int seed_black_holes, - const int foreign_buffers_allocated); + const int foreign_buffers_allocated); void engine_activate_gpart_comms(struct engine *e); /* Function prototypes, engine_maketasks.c. */ diff --git a/src/engine_fof.c b/src/engine_fof.c index b3dcced1735e946b8055eed246a761e6f57100d6..940143b852c0fac7a6cb737bf4a44800591e2158 100644 --- a/src/engine_fof.c +++ b/src/engine_fof.c @@ -106,11 +106,11 @@ void engine_activate_fof_tasks(struct engine *e) { * (including BH seed info)? * @param seed_black_holes Are we seeding black holes? * @param foreign_buffers_allocated Are the foreign buffers currently - * allocated? + * allocated? */ void engine_fof(struct engine *e, const int dump_results, const int dump_debug_results, const int seed_black_holes, - const int foreign_buffers_allocated) { + const int foreign_buffers_allocated) { #ifdef WITH_FOF @@ -122,7 +122,7 @@ void engine_fof(struct engine *e, const int dump_results, space_free_foreign_parts(e->s, /*clear pointers=*/1); #endif } - + /* Compute number of DM particles */ const long long total_nr_baryons = e->total_nr_parts + e->total_nr_sparts + e->total_nr_bparts; @@ -166,7 +166,7 @@ void engine_fof(struct engine *e, const int dump_results, engine_allocate_foreign_particles(e, /*fof=*/0); #endif } - + if (engine_rank == 0) message("Complete FOF search took: %.3f %s.", clocks_from_ticks(getticks() - tic), clocks_getunit()); diff --git a/src/engine_io.c b/src/engine_io.c index 37cc88b4c8d2848b3c0e7ba381dc2a130e6e4f72..f20f5f1991f467ea49486e8492027000a120126f 100644 --- a/src/engine_io.c +++ b/src/engine_io.c @@ -316,12 +316,12 @@ void engine_check_for_dumps(struct engine *e) { if ((e->policy & engine_policy_self_gravity) && e->s->periodic) pm_mesh_free(e->mesh); - /* Free the foreign particles to get more breathing space. - * If called, the FOF code itself will reallocate what it needs. */ + /* Free the foreign particles to get more breathing space. + * If called, the FOF code itself will reallocate what it needs. */ #ifdef WITH_MPI space_free_foreign_parts(e->s, /*clear_cell_pointers=*/1); #endif - + /* Do we want FoF group IDs in the snapshot? */ if (with_fof && e->snapshot_invoke_fof) { engine_fof(e, /*dump_results=*/1, /*dump_debug=*/0, @@ -356,7 +356,7 @@ void engine_check_for_dumps(struct engine *e) { if ((e->policy & engine_policy_self_gravity) && e->s->periodic) pm_mesh_allocate(e->mesh); #ifdef WITH_MPI - engine_allocate_foreign_particles(e, /*fof=*/ 0); + engine_allocate_foreign_particles(e, /*fof=*/0); #endif /* ... and find the next output time */ diff --git a/src/fof.c b/src/fof.c index 2a4fd9dc61171fe58657381a8ee9ef5104c41e41..d65bd032277886f0ccf2efe62bd4435b879e93d1 100644 --- a/src/fof.c +++ b/src/fof.c @@ -2519,10 +2519,9 @@ void fof_search_foreign_cells(struct fof_props *props, const struct space *s) { "took: %.3f %s.", clocks_from_ticks(getticks() - tic), clocks_getunit()); - /* Allocate buffers to receive the gpart fof information */ engine_allocate_foreign_particles(e, /*fof=*/1); - + /* Activate the tasks exchanging all the required gparts */ engine_activate_gpart_comms(e); @@ -2556,7 +2555,7 @@ void fof_search_foreign_cells(struct fof_props *props, const struct space *s) { /* Clean up memory. */ swift_free("fof_cell_pairs", cell_pairs); space_free_foreign_parts(e->s, /*clear pointers=*/1); - + if (verbose) message("Searching for foreign links took: %.3f %s.", clocks_from_ticks(getticks() - tic), clocks_getunit());