From e976799c09d45b8835d4ab58c005700908b22736 Mon Sep 17 00:00:00 2001 From: Pedro Gonnet <pedro.gonnet@durham.ac.uk> Date: Tue, 27 Aug 2013 14:19:15 +0000 Subject: [PATCH] actually, was not a bug... Former-commit-id: e779ea7ad4c8772cf7957af0b1e171ca2586140b --- src/runner_doiact.h | 6 +++--- src/scheduler.c | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/runner_doiact.h b/src/runner_doiact.h index 411ebb7c1c..0812bb0da8 100644 --- a/src/runner_doiact.h +++ b/src/runner_doiact.h @@ -1731,7 +1731,7 @@ void DOSUB1 ( struct runner *r , struct cell *ci , struct cell *cj , int sid , i /* Recurse? */ if ( ci->split && cj->split && - fmaxf( ci->h_max , cj->h_max )*kernel_gamma + ci->dx_max + cj->dx_max < h ) { + fmaxf( ci->h_max , cj->h_max )*kernel_gamma + ci->dx_max + cj->dx_max < h/2 ) { /* Different types of flags. */ switch ( sid ) { @@ -2012,7 +2012,7 @@ void DOSUB2 ( struct runner *r , struct cell *ci , struct cell *cj , int sid , i /* Recurse? */ if ( ci->split && cj->split && - fmaxf( ci->h_max , cj->h_max )*kernel_gamma + ci->dx_max + cj->dx_max < h ) { + fmaxf( ci->h_max , cj->h_max )*kernel_gamma + ci->dx_max + cj->dx_max < h/2 ) { /* Different types of flags. */ switch ( sid ) { @@ -2295,7 +2295,7 @@ void DOSUB_SUBSET ( struct runner *r , struct cell *ci , struct part *parts , in /* Recurse? */ if ( ci->split && cj->split && - fmaxf( ci->h_max , cj->h_max )*kernel_gamma + ci->dx_max + cj->dx_max < h ) { + fmaxf( ci->h_max , cj->h_max )*kernel_gamma + ci->dx_max + cj->dx_max < h/2 ) { /* Get the type of pair if not specified explicitly. */ sid = space_getsid( s , &ci , &cj , shift ); diff --git a/src/scheduler.c b/src/scheduler.c index 6a33c5c59d..62a119ebb9 100644 --- a/src/scheduler.c +++ b/src/scheduler.c @@ -282,8 +282,8 @@ void scheduler_splittasks ( struct scheduler *s ) { /* Should this task be split-up? */ if ( ci->split && cj->split && - ci->h_max*kernel_gamma*space_stretch < hi && - cj->h_max*kernel_gamma*space_stretch < hj ) { + ci->h_max*kernel_gamma*space_stretch < hi/2 && + cj->h_max*kernel_gamma*space_stretch < hj/2 ) { /* Replace by a single sub-task? */ if ( scheduler_dosub && -- GitLab