Changeset: 56bbe74324f4 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=56bbe74324f4 Modified Files: gdk/gdk_bbp.c Branch: Aug2018 Log Message:
Two small fixes to fix bug 6661. - Reduce time spent in micro sleep waiting for a BAT to become available. - Do not unload a BAT which has views on it. diffs (21 lines): diff --git a/gdk/gdk_bbp.c b/gdk/gdk_bbp.c --- a/gdk/gdk_bbp.c +++ b/gdk/gdk_bbp.c @@ -101,7 +101,7 @@ static volatile ATOMIC_TYPE BBPsize = 0; struct BBPfarm_t BBPfarms[MAXFARMS]; -#define KITTENNAP 4 /* used to suspend processing */ +#define KITTENNAP 1 /* used to suspend processing */ #define BBPNONAME "." /* filler for no name in BBP.dir */ /* * The hash index uses a bucket index (int array) of size mask that is @@ -2499,7 +2499,7 @@ decref(bat i, bool logical, bool release (BBP_lrefs(i) > 0 && (b == NULL || BATdirty(b) || !(BBP_status(i) & BBPPERSISTENT)))) { /* bat cannot be swapped out */ - } else if (b || (BBP_status(i) & BBPTMP)) { + } else if (b ? b->batSharecnt == 0 : (BBP_status(i) & BBPTMP)) { /* bat will be unloaded now. set the UNLOADING bit * while locked so no other thread thinks it's * available anymore */ _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list