### Don't lock the tree for the grav_init task. Don't call the unsorted pairs at...

`Don't lock the tree for the grav_init task. Don't call the unsorted pairs at all. Skip the entire zeroing loop when no xparts in runner_do_sort()`
parent ea8cd415
 ... ... @@ -423,13 +423,17 @@ void runner_do_sort(struct runner *r, struct cell *c, int flags, int clock) { /* Otherwise, just sort. */ else { /* Fill the sort array. */ for (int k = 0; k < count; k++) { if (xparts != NULL) { /* Reset the sort distance if we are in a local cell */ if (xparts != NULL) { for (int k = 0; k < count; k++) { xparts[k].x_diff_sort = 0.0f; xparts[k].x_diff_sort = 0.0f; xparts[k].x_diff_sort = 0.0f; } } /* Fill the sort array. */ for (int k = 0; k < count; k++) { const double px = {parts[k].x, parts[k].x, parts[k].x}; for (int j = 0; j < 13; j++) if (flags & (1 << j)) { ... ...
 ... ... @@ -110,8 +110,6 @@ #define _TIMER_DOPAIR_SUBSET(f) PASTE(timer_dopair_subset, f) #define TIMER_DOPAIR_SUBSET _TIMER_DOPAIR_SUBSET(FUNCTION) #include "runner_doiact_nosort.h" /** * @brief Compute the interactions between a cell pair (non-symmetric). * ... ... @@ -572,13 +570,6 @@ void DOPAIR_SUBSET(struct runner *r, struct cell *restrict ci, struct engine *e = r->e; #ifdef WITH_MPI if (ci->nodeID != cj->nodeID) { DOPAIR_SUBSET_NOSORT(r, ci, parts_i, ind, count, cj); return; } #endif #ifdef WITH_OLD_VECTORIZATION int icount = 0; float r2q[VEC_SIZE] __attribute__((aligned(16))); ... ... @@ -1103,13 +1094,6 @@ void DOPAIR2(struct runner *r, struct cell *ci, struct cell *cj) { struct engine *restrict e = r->e; #ifdef WITH_MPI if (ci->nodeID != cj->nodeID) { DOPAIR2_NOSORT(r, ci, cj); return; } #endif #ifdef WITH_OLD_VECTORIZATION int icount1 = 0; float r2q1[VEC_SIZE] __attribute__((aligned(16))); ... ...
 ... ... @@ -283,10 +283,6 @@ void task_unlock(struct task *t) { /* Act based on task type. */ switch (type) { case task_type_init_grav: cell_munlocktree(ci); break; case task_type_kick1: case task_type_kick2: case task_type_timestep: ... ... @@ -373,11 +369,6 @@ int task_lock(struct task *t) { #endif break; case task_type_init_grav: if (ci->mhold) return 0; if (cell_mlocktree(ci) != 0) return 0; break; case task_type_kick1: case task_type_kick2: case task_type_timestep: ... ...
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