Changeset: dba013ff1707 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/dba013ff1707
Modified Files:
gdk/gdk_bbp.c
sql/storage/store.c
Branch: Jan2022
Log Message:
Merge with Jul2021 branch.
diffs (48 lines):
diff --git a/gdk/gdk_bbp.c b/gdk/gdk_bbp.c
--- a/gdk/gdk_bbp.c
+++ b/gdk/gdk_bbp.c
@@ -1896,7 +1896,7 @@ vheap_entry(FILE *fp, BATiter *bi, BUN s
GDKfree(fname);
}
}
- return fprintf(fp, " %zu %zu %d", bi->vhfree, bi->vh->size, 0);
+ return fprintf(fp, " %zu %zu %d", bi->vhfree, size == 0 ? 0 :
bi->vh->size, 0);
}
static gdk_return
@@ -3957,7 +3957,11 @@ BBPsync(int cnt, bat *restrict subcommit
break;
}
bi = bat_iterator(BBP_desc(i));
- if (b) {
+ assert(sizes == NULL || size <= bi.count);
+ assert(sizes == NULL || bi.width == 0 ||
(bi.type == TYPE_msk ? ((size + 31) / 32) * 4 : size << bi.shift) <= bi.hfree);
+ if (size > bi.count) /* includes sizes==NULL */
+ size = bi.count;
+ if (b && size != 0) {
/* wait for BBPSAVING so that we
* can set it, wait for
* BBPUNLOADING before
@@ -3974,10 +3978,6 @@ BBPsync(int cnt, bat *restrict subcommit
BBP_status_on(i, BBPSAVING);
if (lock)
MT_lock_unset(&GDKswapLock(i));
- assert(sizes == NULL || size <=
bi.count);
- assert(sizes == NULL || bi.width == 0
|| (bi.type == TYPE_msk ? ((size + 31) / 32) * 4 : size << bi.shift) <=
bi.hfree);
- if (size > bi.count)
- size = bi.count;
MT_rwlock_rdlock(&b->thashlock);
ret = BATsave_locked(b, &bi, size);
MT_rwlock_rdunlock(&b->thashlock);
diff --git a/sql/storage/store.c b/sql/storage/store.c
--- a/sql/storage/store.c
+++ b/sql/storage/store.c
@@ -2229,7 +2229,7 @@ store_apply_deltas(sqlstore *store)
store_lock(store);
ulng oldest = store_oldest_pending(store);
store_unlock(store);
- TRC_DEBUG(SQL_STORE, "Store aplly deltas (" ULLFMT ")\n", oldest-1);
+ TRC_DEBUG(SQL_STORE, "Store apply deltas (" ULLFMT ")\n", oldest-1);
if (oldest)
res = store->logger_api.flush(store, oldest-1);
flusher.working = false;
_______________________________________________
checkin-list mailing list -- [email protected]
To unsubscribe send an email to [email protected]