Changeset: 3e6bd2e01660 for MonetDB URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=3e6bd2e01660 Modified Files: clients/Tests/exports.stable.out monetdb5/modules/kernel/batmtime.mx Branch: default Log Message:
Removed accumulator version of batmtime operators. They are not used. diffs (255 lines): 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 @@ -1774,60 +1774,6 @@ void MSresetInstructions(MalBlkPtr mb, i void MSresetVariables(Client cntxt, MalBlkPtr mb, MalStkPtr glb, int start); void MSscheduleClient(str command, str challenge, bstream *fin, stream *fout); void MSserveClient(void *dummy); -str MTIMEaccum_date_EQ(int *ret, int *d, int *l, int *r); -str MTIMEaccum_date_EQ_cst(int *ret, int *r, int *l, date *cst); -str MTIMEaccum_date_GE(int *ret, int *d, int *l, int *r); -str MTIMEaccum_date_GE_cst(int *ret, int *r, int *l, date *cst); -str MTIMEaccum_date_GT(int *ret, int *d, int *l, int *r); -str MTIMEaccum_date_GT_cst(int *ret, int *r, int *l, date *cst); -str MTIMEaccum_date_LE(int *ret, int *d, int *l, int *r); -str MTIMEaccum_date_LE_cst(int *ret, int *r, int *l, date *cst); -str MTIMEaccum_date_LT(int *ret, int *d, int *l, int *r); -str MTIMEaccum_date_LT_cst(int *ret, int *r, int *l, date *cst); -str MTIMEaccum_date_NEQ(int *ret, int *d, int *l, int *r); -str MTIMEaccum_date_NEQ_cst(int *ret, int *r, int *l, date *cst); -str MTIMEaccum_date_cst_EQ(int *ret, int *r, date *cst, int *l); -str MTIMEaccum_date_cst_GE(int *ret, int *r, date *cst, int *l); -str MTIMEaccum_date_cst_GT(int *ret, int *r, date *cst, int *l); -str MTIMEaccum_date_cst_LE(int *ret, int *r, date *cst, int *l); -str MTIMEaccum_date_cst_LT(int *ret, int *r, date *cst, int *l); -str MTIMEaccum_date_cst_NEQ(int *ret, int *r, date *cst, int *l); -str MTIMEaccum_daytime_EQ(int *ret, int *d, int *l, int *r); -str MTIMEaccum_daytime_EQ_cst(int *ret, int *r, int *l, daytime *cst); -str MTIMEaccum_daytime_GE(int *ret, int *d, int *l, int *r); -str MTIMEaccum_daytime_GE_cst(int *ret, int *r, int *l, daytime *cst); -str MTIMEaccum_daytime_GT(int *ret, int *d, int *l, int *r); -str MTIMEaccum_daytime_GT_cst(int *ret, int *r, int *l, daytime *cst); -str MTIMEaccum_daytime_LE(int *ret, int *d, int *l, int *r); -str MTIMEaccum_daytime_LE_cst(int *ret, int *r, int *l, daytime *cst); -str MTIMEaccum_daytime_LT(int *ret, int *d, int *l, int *r); -str MTIMEaccum_daytime_LT_cst(int *ret, int *r, int *l, daytime *cst); -str MTIMEaccum_daytime_NEQ(int *ret, int *d, int *l, int *r); -str MTIMEaccum_daytime_NEQ_cst(int *ret, int *r, int *l, daytime *cst); -str MTIMEaccum_daytime_cst_EQ(int *ret, int *r, daytime *cst, int *l); -str MTIMEaccum_daytime_cst_GE(int *ret, int *r, daytime *cst, int *l); -str MTIMEaccum_daytime_cst_GT(int *ret, int *r, daytime *cst, int *l); -str MTIMEaccum_daytime_cst_LE(int *ret, int *r, daytime *cst, int *l); -str MTIMEaccum_daytime_cst_LT(int *ret, int *r, daytime *cst, int *l); -str MTIMEaccum_daytime_cst_NEQ(int *ret, int *r, daytime *cst, int *l); -str MTIMEaccum_timestamp_EQ(int *ret, int *d, int *l, int *r); -str MTIMEaccum_timestamp_EQ_cst(int *ret, int *r, int *l, timestamp *cst); -str MTIMEaccum_timestamp_GE(int *ret, int *d, int *l, int *r); -str MTIMEaccum_timestamp_GE_cst(int *ret, int *r, int *l, timestamp *cst); -str MTIMEaccum_timestamp_GT(int *ret, int *d, int *l, int *r); -str MTIMEaccum_timestamp_GT_cst(int *ret, int *r, int *l, timestamp *cst); -str MTIMEaccum_timestamp_LE(int *ret, int *d, int *l, int *r); -str MTIMEaccum_timestamp_LE_cst(int *ret, int *r, int *l, timestamp *cst); -str MTIMEaccum_timestamp_LT(int *ret, int *d, int *l, int *r); -str MTIMEaccum_timestamp_LT_cst(int *ret, int *r, int *l, timestamp *cst); -str MTIMEaccum_timestamp_NEQ(int *ret, int *d, int *l, int *r); -str MTIMEaccum_timestamp_NEQ_cst(int *ret, int *r, int *l, timestamp *cst); -str MTIMEaccum_timestamp_cst_EQ(int *ret, int *r, timestamp *cst, int *l); -str MTIMEaccum_timestamp_cst_GE(int *ret, int *r, timestamp *cst, int *l); -str MTIMEaccum_timestamp_cst_GT(int *ret, int *r, timestamp *cst, int *l); -str MTIMEaccum_timestamp_cst_LE(int *ret, int *r, timestamp *cst, int *l); -str MTIMEaccum_timestamp_cst_LT(int *ret, int *r, timestamp *cst, int *l); -str MTIMEaccum_timestamp_cst_NEQ(int *ret, int *r, timestamp *cst, int *l); str MTIMEbat_date_EQ(int *ret, int *l, int *r); str MTIMEbat_date_EQ_cst(int *ret, int *l, date *cst); str MTIMEbat_date_GE(int *ret, int *l, int *r); diff --git a/monetdb5/modules/kernel/batmtime.mx b/monetdb5/modules/kernel/batmtime.mx --- a/monetdb5/modules/kernel/batmtime.mx +++ b/monetdb5/modules/kernel/batmtime.mx @@ -43,16 +43,6 @@ command batcalc.@2(r:@1, l:bat[:oid,:@1] address MTIMEbat_@1_cst_@3 comment "Compare a bat of @1 against a singleton"; -command batcalc.@2(a:bat[:oid,:bit], l:bat[:oid,:@1], r:bat[:oid,:@1]) :bat[:oid,:bit] -address MTIMEaccum_@1_@3 -comment "Compare a bat of @1 against each other"; -command batcalc.@2(a:bat[:oid,:bit], l:bat[:oid,:@1], r:@1) :bat[:oid,:bit] -address MTIMEaccum_@1_@3_cst; -command batcalc.@2(a:bat[:oid,:bit], r:@1, l:bat[:oid,:@1]) :bat[:oid,:bit] -address MTIMEaccum_@1_cst_@3 -comment "Compare a bat of @1 against a singleton"; - - @= compareGrp @:compareOp(@1,==,EQ)@ @:compareOp(@1,!=,NEQ)@ @@ -113,9 +103,6 @@ comment "Unary check for nil over the ta batmtime_export str MTIMEbat_@1_@2(int *ret, int *l, int *r); batmtime_export str MTIMEbat_@1_@2_cst(int *ret, int *l, @1 *cst); batmtime_export str MTIMEbat_@1_cst_@2(int *ret, @1 *cst, int *l); -batmtime_export str MTIMEaccum_@1_@2(int *ret, int *d, int *l, int *r); -batmtime_export str MTIMEaccum_@1_@2_cst(int *ret, int *r, int *l, @1 *cst); -batmtime_export str MTIMEaccum_@1_cst_@2(int *ret, int *r, @1 *cst, int *l); @c #define resultBAT(Type,Error)\ @@ -198,68 +185,6 @@ str MTIMEbat_@1_@2(int *ret, int *l, int return MAL_SUCCEED; } -str MTIMEaccum_@1_@2(int *ret, int *d, int *l, int *r) -{ - BAT *bn, *b, *right; - @1 *p, *q, *t; - bit *o; - - if ((b = BATdescriptor(*l)) == NULL) - throw(MAL, "batcalc.@2", RUNTIME_OBJECT_MISSING); - if ((right = BATdescriptor(*r)) == NULL) { - BBPreleaseref(b->batCacheid); - throw(MAL, "batcalc.@2", RUNTIME_OBJECT_MISSING); - } - if ((bn = BATdescriptor(*d)) == NULL) { - BBPreleaseref(b->batCacheid);BBPreleaseref(right->batCacheid); - throw(MAL, "batcalc.@2", RUNTIME_OBJECT_MISSING); - } - if( BATcount(bn) != BATcount(b) ) - throw(MAL, "batcalc.@2", ILLEGAL_ARGUMENT " Requires bats of identical size"); - if( BATcount(bn) != BATcount(right) ) - throw(MAL, "batcalc.@2", ILLEGAL_ARGUMENT " Requires bats of identical size"); - - o = (bit*)Tloc(bn,BUNfirst(bn)); - p = (@1*)Tloc(b,BUNfirst(b)); - q = (@1*)Tloc(b,BUNlast(b)); - t = (@1*)Tloc(right,BUNfirst(right)); - - BATaccessBegin(b, USE_TAIL, MMAP_SEQUENTIAL); - BATaccessBegin(right, USE_TAIL, MMAP_SEQUENTIAL); - if (b->T->nonil && right->T->nonil) { - for (;p<q; p++, t++, o++) - @1@2(o,p,t); - } else - if (b->T->nonil) - for (;p<q; p++, t++, o++) - if ( @1_isnil(*t)) - *o = bit_nil; - else @1@2(o,p,t); - else - if (right->T->nonil) - for (;p<q; p++, t++, o++) - if ( @1_isnil(*p) ) - *o = bit_nil; - else @1@2(o,p,t); - else - for (;p<q; p++, t++, o++) - if ( @1_isnil(*p) || @1_isnil(*t)) - *o = bit_nil; - else @1@2(o,p,t); - - BATaccessEnd(right, USE_TAIL, MMAP_SEQUENTIAL); - BATaccessEnd(b, USE_TAIL, MMAP_SEQUENTIAL); - - BATsetcount(bn, BATcount(b)); - bn->tsorted = 0; - bn->trevsorted = 0; - BATkey(BATmirror(bn),FALSE); - BBPkeepref(*ret= bn->batCacheid); - BBPreleaseref(right->batCacheid); - BBPreleaseref(b->batCacheid); - return MAL_SUCCEED; -} - str MTIMEbat_@1_@2_cst(int *ret, int *l, @1 *cst) { BAT *bn, *b; @@ -356,91 +281,6 @@ str MTIMEbat_@1_cst_@2(int *ret, @1 *cst return MAL_SUCCEED; } -str MTIMEaccum_@1_@2_cst(int *ret, int *r, int *l, @1 *cst) -{ - BAT *bn, *b; - @1 *p, *q; - bit *o; - - if ((bn = BATdescriptor(*r)) == NULL) - throw(MAL, "batcalc.@2", RUNTIME_OBJECT_MISSING); - if ((b = BATdescriptor(*l)) == NULL) { - BBPreleaseref(bn->batCacheid); - @4; - throw(MAL, "batcalc.@2", RUNTIME_OBJECT_MISSING); - } - if( BATcount(bn) != BATcount(b) ) - throw(MAL, "batcalc.@2", ILLEGAL_ARGUMENT " Requires bats of identical size"); - - o = (bit*)Tloc(bn,BUNfirst(bn)); - p = (@1*)Tloc(b,BUNfirst(b)); - q = (@1*)Tloc(b,BUNlast(b)); - - BATaccessBegin(b, USE_TAIL, MMAP_SEQUENTIAL); - if ( @1_isnil(*cst)) - for (;p<q; p++, o++) - *o = bit_nil; - else - if (b->T->nonil) - for (;p<q; p++, o++) - @1@2(o,p,cst); - else - for (;p<q; p++, o++) - if ( @1_isnil(*p) ) - *o = bit_nil; - else @1@2(o,p,cst); - - BATaccessEnd(b, USE_TAIL, MMAP_SEQUENTIAL); - bn->tsorted = 0; - bn->trevsorted = 0; - BATkey(BATmirror(bn),FALSE); - BBPkeepref(*ret= bn->batCacheid); - BBPreleaseref(b->batCacheid); - return MAL_SUCCEED; -} - -str MTIMEaccum_@1_cst_@2(int *ret, int *r, @1 *cst, int *l) -{ - BAT *bn, *b; - @1 *p, *q; - bit *o; - - if ((bn = BATdescriptor(*r)) == NULL) - throw(MAL, "batcalc.@2", RUNTIME_OBJECT_MISSING); - if ((b = BATdescriptor(*l)) == NULL) { - BBPreleaseref(bn->batCacheid); - throw(MAL, "batcalc.@2", RUNTIME_OBJECT_MISSING); - } - if( BATcount(bn) != BATcount(b) ) - throw(MAL, "batcalc.@2", ILLEGAL_ARGUMENT " Requires bats of identical size"); - - o = (bit*)Tloc(bn,BUNfirst(bn)); - p = (@1*)Tloc(b,BUNfirst(b)); - q = (@1*)Tloc(b,BUNlast(b)); - - BATaccessBegin(b, USE_TAIL, MMAP_SEQUENTIAL); - if ( @1_isnil(*cst)) - for (;p<q; p++, o++) - *o = bit_nil; - else - if (b->T->nonil) - for (;p<q; p++, o++) - @1@2(o,cst,p); - else - for (;p<q; p++, o++) - if ( @1_isnil(*p) ) - *o = bit_nil; - else @1@2(o,cst,p); - BATaccessEnd(b, USE_TAIL, MMAP_SEQUENTIAL); - - bn->tsorted = 0; - bn->trevsorted = 0; - BATkey(BATmirror(bn),FALSE); - BBPkeepref(*ret= bn->batCacheid); - BBPreleaseref(b->batCacheid); - return MAL_SUCCEED; -} - @= implCmpGrpDef @:implDef(@1,EQ)@ @:implDef(@1,NEQ)@ _______________________________________________ Checkin-list mailing list Checkin-list@monetdb.org http://mail.monetdb.org/mailman/listinfo/checkin-list