Changeset: 391a5eec2d91 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=391a5eec2d91 Modified Files: clients/Tests/MAL-signatures.stable.out clients/Tests/MAL-signatures.stable.out.int128 clients/Tests/exports.stable.out monetdb5/modules/mosaic/TODO_MOSAIC.txt monetdb5/modules/mosaic/mosaic.c monetdb5/modules/mosaic/mosaic.h monetdb5/modules/mosaic/mosaic.mal Branch: mosaic Log Message:
Remove unused functions. diffs (177 lines): diff --git a/clients/Tests/MAL-signatures.stable.out b/clients/Tests/MAL-signatures.stable.out --- a/clients/Tests/MAL-signatures.stable.out +++ b/clients/Tests/MAL-signatures.stable.out @@ -11453,7 +11453,6 @@ stdout of test 'MAL-signatures` in direc [ "mosaic", "select", "pattern mosaic.select(b:bat[:str], low:str, high:str, li:bit, hi:bit, anti:bit):bat[:oid] ", "MOSselect;", "" ] [ "mosaic", "select", "pattern mosaic.select(b:bat[:timestamp], cand:bat[:oid], low:timestamp, high:timestamp, li:bit, hi:bit, anti:bit):bat[:oid] ", "MOSselect;", "Overloaded selection routine" ] [ "mosaic", "select", "pattern mosaic.select(b:bat[:timestamp], low:timestamp, high:timestamp, li:bit, hi:bit, anti:bit):bat[:oid] ", "MOSselect;", "Overloaded selection routine" ] -[ "mosaic", "slice", "pattern mosaic.slice(bid:lng) (b0:bte, b1:bte, b2:bte, b3:bte, b4:bte, b5:bte, b6:bte, b7:bte) ", "MOSslice;", "Break column into verticalslices" ] [ "mosaic", "thetaselect", "pattern mosaic.thetaselect(b:bat[:bit], c:bat[:oid], low:bit, oper:str):bat[:oid] ", "MOSthetaselect;", "" ] [ "mosaic", "thetaselect", "pattern mosaic.thetaselect(b:bat[:bit], low:bit, oper:str):bat[:oid] ", "MOSthetaselect;", "" ] [ "mosaic", "thetaselect", "pattern mosaic.thetaselect(b:bat[:bte], c:bat[:oid], low:bte, oper:str):bat[:oid] ", "MOSthetaselect;", "" ] diff --git a/clients/Tests/MAL-signatures.stable.out.int128 b/clients/Tests/MAL-signatures.stable.out.int128 --- a/clients/Tests/MAL-signatures.stable.out.int128 +++ b/clients/Tests/MAL-signatures.stable.out.int128 @@ -15857,7 +15857,6 @@ stdout of test 'MAL-signatures` in direc [ "mosaic", "select", "pattern mosaic.select(b:bat[:str], low:str, high:str, li:bit, hi:bit, anti:bit):bat[:oid] ", "MOSselect;", "" ] [ "mosaic", "select", "pattern mosaic.select(b:bat[:timestamp], cand:bat[:oid], low:timestamp, high:timestamp, li:bit, hi:bit, anti:bit):bat[:oid] ", "MOSselect;", "Overloaded selection routine" ] [ "mosaic", "select", "pattern mosaic.select(b:bat[:timestamp], low:timestamp, high:timestamp, li:bit, hi:bit, anti:bit):bat[:oid] ", "MOSselect;", "Overloaded selection routine" ] -[ "mosaic", "slice", "pattern mosaic.slice(bid:lng) (b0:bte, b1:bte, b2:bte, b3:bte, b4:bte, b5:bte, b6:bte, b7:bte) ", "MOSslice;", "Break column into verticalslices" ] [ "mosaic", "thetaselect", "pattern mosaic.thetaselect(b:bat[:bit], c:bat[:oid], low:bit, oper:str):bat[:oid] ", "MOSthetaselect;", "" ] [ "mosaic", "thetaselect", "pattern mosaic.thetaselect(b:bat[:bit], low:bit, oper:str):bat[:oid] ", "MOSthetaselect;", "" ] [ "mosaic", "thetaselect", "pattern mosaic.thetaselect(b:bat[:bte], c:bat[:oid], low:bte, oper:str):bat[:oid] ", "MOSthetaselect;", "" ] diff --git a/clients/Tests/exports.stable.out b/clients/Tests/exports.stable.out --- a/clients/Tests/exports.stable.out +++ b/clients/Tests/exports.stable.out @@ -1535,14 +1535,11 @@ void MOSlayout_linear(MOStask *task, BAT void MOSlayout_prefix(MOStask *task, BAT *btech, BAT *bcount, BAT *binput, BAT *boutput, BAT *bproperties); void MOSlayout_raw(MOStask *task, BAT *btech, BAT *bcount, BAT *binput, BAT *boutput, BAT *bproperties); void MOSlayout_runlength(MOStask *task, BAT *btech, BAT *bcount, BAT *binput, BAT *boutput, BAT *bproperties); -BUN MOSlimit(void); const Method MOSmethods[]; str MOSprepareEstimate_dict(MOStask *task); str MOSprepareEstimate_dict256(MOStask *task); str MOSprojection(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); str MOSselect(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); -str MOSslice(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); -str MOSsliceInternal(bat *slices, BUN size, BAT *b); str MOSthetaselect(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); void MOSupdateHeader(MOStask *task); void MPresetProfiler(stream *fdout); diff --git a/monetdb5/modules/mosaic/TODO_MOSAIC.txt b/monetdb5/modules/mosaic/TODO_MOSAIC.txt --- a/monetdb5/modules/mosaic/TODO_MOSAIC.txt +++ b/monetdb5/modules/mosaic/TODO_MOSAIC.txt @@ -21,7 +21,6 @@ Find a more 'generic' model to estimate Create a plug-in estimation model framework. ####code issues#### -Get rid of unsused functions. limit/blk etc. See if the iteration algorithms can be improved. Use GDK naming conventions, e.g. o for stuff coming out if canditer_next. Update copyright in 2020. 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 @@ -145,11 +145,6 @@ MOSinit(MOStask* task, BAT *b) { task->padding = NULL; } -void MOSblk(MosaicBlk blk) -{ - printf("Block tag %d cnt "BUNFMT"\n", MOSgetTag(blk),MOSgetCnt(blk)); -} - str MOSlayout(BAT *b, BAT *btech, BAT *bcount, BAT *binput, BAT *boutput, BAT *bproperties) { @@ -1573,82 +1568,3 @@ MOSAnalysis(BAT *b, BAT *btech, BAT *bou return msg; } - -/* slice a fixed size atom into thin bte-wide columns, used for experiments */ -str -MOSsliceInternal(bat *slices, BUN size, BAT *b) -{ - BUN i; - BUN cnt= BATcount(b); - BAT *bats[8]; - bte *thin[8]; - assert(size < 8); - - for( i = 0; i< size; i++){ - bats[i] = COLnew((oid)0,TYPE_bte, cnt, TRANSIENT); - if ( bats[i] == NULL){ - for( ;i>0; i--) - BBPunfix(bats[--i]->batCacheid); - throw(MAL,"mosaic.slice", MAL_MALLOC_FAIL); - } - slices[i] = bats[i]->batCacheid; - thin[i]= (bte*) Tloc(bats[i],0); - BATsetcount(bats[i], cnt); - } - switch(b->ttype){ - case TYPE_int: - { union { - unsigned int val; - bte thin[4]; - } map; - unsigned int *val = (unsigned int*) Tloc(b,0); - for(i=0; i < cnt; i++, val++){ - map.val = *val; - *thin[0] = map.thin[0]; thin[0]++; - *thin[1] = map.thin[1]; thin[1]++; - *thin[2] = map.thin[2]; thin[2]++; - *thin[3] = map.thin[3]; thin[3]++; - } - } - break; - case TYPE_lng: - { union { - lng val; - bte thin[8]; - } map; - unsigned int *val = (unsigned int*) Tloc(b,0); - for(i=0; i < cnt; i++, val++){ - map.val = *val; - *thin[0] = map.thin[0]; thin[0]++; - *thin[1] = map.thin[1]; thin[1]++; - *thin[2] = map.thin[2]; thin[2]++; - *thin[3] = map.thin[3]; thin[3]++; - *thin[4] = map.thin[4]; thin[4]++; - *thin[5] = map.thin[5]; thin[5]++; - *thin[6] = map.thin[6]; thin[6]++; - *thin[7] = map.thin[7]; thin[7]++; - } - } - break; - default: - assert(0); - } - return MAL_SUCCEED; -} - -str -MOSslice(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci) -{ - bat slices[8]; - BAT *b; - BUN s; - - (void) cntxt; - s = (BUN) ATOMsize(getArgType(mb,pci,pci->retc)); - if( s > 8) - throw(MAL,"mosaic.slice", "illegal type witdh"); - b = BATdescriptor(* getArgReference_bat(stk,pci, pci->retc)); - if ( b == NULL) - throw(MAL,"mosaic.slice", RUNTIME_OBJECT_MISSING); - return MOSsliceInternal( slices, s,b); -} 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 @@ -239,10 +239,6 @@ mal_export str MOSthetaselect(Client cnt mal_export str MOSprojection(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); mal_export str MOSjoin(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); mal_export str MOSlayout(BAT *b, BAT *btech, BAT *bcount, BAT *binput, BAT *boutput, BAT *bproperties); -mal_export str MOSsliceInternal(bat *slices, BUN size, BAT *b); mal_export str MOSAnalysis(BAT *b, BAT *btech, BAT *output, BAT *factor, BAT *compress, BAT *decompress, str compressions); -mal_export str MOSslice(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); -mal_export void MOSblk(MosaicBlk blk); -mal_export BUN MOSlimit(void); #endif /* _MOSLIST_H */ diff --git a/monetdb5/modules/mosaic/mosaic.mal b/monetdb5/modules/mosaic/mosaic.mal --- a/monetdb5/modules/mosaic/mosaic.mal +++ b/monetdb5/modules/mosaic/mosaic.mal @@ -12,10 +12,6 @@ command decompress(b:bat[:any_1]) :bat[: address MOSdecompress comment "Apply dynamic decompression over chunks producing a temporary version"; -pattern slice(bid:lng)(b0:bte,b1:bte,b2:bte,b3:bte,b4:bte,b5:bte,b6:bte,b7:bte) -address MOSslice -comment "Break column into verticalslices"; - pattern select(b:bat[:bte], low:bte, high:bte, li:bit, hi:bit, anti:bit) :bat[:oid] address MOSselect; _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list