Changeset: b4377f09aa0f for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB/rev/b4377f09aa0f
Modified Files:
gdk/gdk.h
Branch: Jul2021
Log Message:
In case a bat is a view, fill in the iterator with the calculated size.
diffs (17 lines):
diff --git a/gdk/gdk.h b/gdk/gdk.h
--- a/gdk/gdk.h
+++ b/gdk/gdk.h
@@ -944,7 +944,12 @@ bat_iterator(BAT *b)
.shift = b->tshift,
.type = b->ttype,
.tseq = b->tseqbase,
- .hfree = b->theap->free,
+ /* don't use b->theap->free in case b is a slice */
+ .hfree = b->ttype ?
+ b->ttype == TYPE_msk ?
+ (((size_t) b->batCount + 31) / 32) * 4 :
+ (size_t) b->batCount << b->tshift :
+ 0,
.vhfree = b->tvheap ? b->tvheap->free : 0,
#ifndef NDEBUG
.locked = true,
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list