Changeset: ae59ab0cde06 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=ae59ab0cde06 Modified Files: monetdb5/modules/mosaic/mosaic.c monetdb5/modules/mosaic/mosaic.h sql/backends/monet5/sql.c sql/test/mosaic/Tests/mix.sql Branch: mosaic Log Message:
Lower the mosaic threshold diffs (68 lines): diff --git a/monetdb5/modules/mosaic/mosaic.c b/monetdb5/modules/mosaic/mosaic.c --- a/monetdb5/modules/mosaic/mosaic.c +++ b/monetdb5/modules/mosaic/mosaic.c @@ -404,7 +404,7 @@ MOScompressInternal(Client cntxt, bat *r assert(bsrc->timprints == NULL); } - if ( BATcount(bsrc) < MIN_INPUT_COUNT ){ + if ( BATcount(bsrc) < MOSAIC_THRESHOLD ){ /* no need to compress */ BBPkeepref(*ret = bsrc->batCacheid); return msg; @@ -1378,7 +1378,7 @@ MOSanalyseInternal(Client cntxt, int thr BBPunfix(bid); return 0; } - if ( BATcount(b) < MIN_INPUT_COUNT ){ + if ( BATcount(b) < MOSAIC_THRESHOLD ){ mnstr_printf(cntxt->fdout,"#ignore small %d %s\n",bid, BBP_logical(bid)); BBPunfix(bid); return 0; diff --git a/monetdb5/modules/mosaic/mosaic.h b/monetdb5/modules/mosaic/mosaic.h --- a/monetdb5/modules/mosaic/mosaic.h +++ b/monetdb5/modules/mosaic/mosaic.h @@ -34,7 +34,7 @@ //#define _DEBUG_MOSAIC_ /* do not invest in compressing BATs smaller than this */ -#define MIN_INPUT_COUNT 1 +#define MOSAIC_THRESHOLD 1 /* The compressor kinds currently hardwired */ #define MOSAIC_METHODS 8 diff --git a/sql/backends/monet5/sql.c b/sql/backends/monet5/sql.c --- a/sql/backends/monet5/sql.c +++ b/sql/backends/monet5/sql.c @@ -596,9 +596,9 @@ alter_table(Client cntxt, mvc *sql, char nc->base.rtime = nc->base.wtime = sql->session->tr->wtime; b = store_funcs.bind_col(sql->session->tr, nc, 0); + assert(b); cnt = BATcount(b); - assert(b); - if (cnt <10000){ + if (cnt < MOSAIC_THRESHOLD){ BBPunfix(b->batCacheid); continue; } @@ -626,7 +626,6 @@ alter_table(Client cntxt, mvc *sql, char d->bid = bid; d->cnt = cnt; mvc_storage(sql, nc, c->storage_type); - mvc_storage(sql, nc, c->storage_type); } } for (; n; n = n->next) { diff --git a/sql/test/mosaic/Tests/mix.sql b/sql/test/mosaic/Tests/mix.sql --- a/sql/test/mosaic/Tests/mix.sql +++ b/sql/test/mosaic/Tests/mix.sql @@ -18,7 +18,7 @@ select * from mix0; -- analyse the impact of the various compression schemes alter table mix0 set read only; -select * from mosaic_analysis('sys','mix0','i') order by factor desc; +--select * from mosaic_analysis('sys','mix0','i') order by factor desc; alter table mix0 alter column i set storage 'dictionary'; select * from mosaic_layout('sys','mix0','i') ; _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list