Changeset: ffe4dfada652 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=ffe4dfada652
Added Files:
sql/test/BugTracker-2017/Tests/semijoinunion.Bug-6150.sql
sql/test/BugTracker-2017/Tests/semijoinunion.Bug-6150.stable.err
sql/test/BugTracker-2017/Tests/semijoinunion.Bug-6150.stable.out
sql/test/sys-schema/Tests/check_ForeignKey_referential_integrity.stable.out.int128
Removed Files:
sql/test/BugTracker-2013/Tests/between.Bug-3259.stable.out.int128
sql/test/BugTracker-2013/Tests/between.Bug-3259.stable.out.int128.single
sql/test/BugTracker-2013/Tests/between.Bug-3259.stable.out.single
Modified Files:
clients/Tests/exports.stable.out
gdk/gdk_batop.c
gdk/gdk_hash.c
gdk/gdk_imprints.c
gdk/gdk_join.c
gdk/gdk_orderidx.c
gdk/gdk_project.c
monetdb5/mal/mal_sabaoth.c
monetdb5/mal/mal_sabaoth.h
monetdb5/modules/kernel/algebra.c
monetdb5/modules/kernel/algebra.h
monetdb5/modules/kernel/bat5.c
monetdb5/modules/kernel/bat5.h
monetdb5/modules/mal/Tests/inspect05.stable.out
monetdb5/modules/mal/profiler.c
monetdb5/modules/mal/profiler.h
monetdb5/modules/mal/sabaoth.c
sql/server/rel_optimizer.c
sql/test/BugTracker-2011/Tests/crash_on_alias.Bug-2798.stable.out
sql/test/BugTracker-2013/Tests/between.Bug-3259.stable.out
sql/test/BugTracker-2017/Tests/All
sql/test/BugTracker/Tests/explain.SF-1739353.stable.out
sql/test/BugTracker/Tests/jdbc_no_debug.SF-1739356.stable.out
sql/test/BugTracker/Tests/subquery_orderby.SF-1688915.sql
sql/test/BugTracker/Tests/subquery_orderby.SF-1688915.stable.out
sql/test/leaks/Tests/check0.stable.out
sql/test/leaks/Tests/check1.stable.out
sql/test/leaks/Tests/check2.stable.out
sql/test/leaks/Tests/check3.stable.out
sql/test/leaks/Tests/check4.stable.out
sql/test/leaks/Tests/check5.stable.out
sql/test/leaks/Tests/drop3.stable.out
sql/test/leaks/Tests/select1.stable.out
sql/test/leaks/Tests/select2.stable.out
sql/test/leaks/Tests/temp1.stable.out
sql/test/leaks/Tests/temp2.stable.out
sql/test/leaks/Tests/temp3.stable.out
sql/test/sys-schema/Tests/check_ForeignKey_referential_integrity.stable.out
sql/test/testdb/Tests/testdb-dump.stable.out.Windows
Branch: wlcr
Log Message:
merge with default
diffs (truncated from 3600 to 300 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
@@ -707,7 +707,6 @@ str ALGprojectionpath(Client cntxt, MalB
str ALGprojecttail(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci);
str ALGrangejoin(bat *r1, bat *r2, const bat *lid, const bat *rlid, const bat
*rhid, const bat *slid, const bat *srid, const bit *li, const bit *hi, const
lng *estimate);
str ALGreuse(bat *ret, const bat *bid);
-str ALGsample(bat *result, const bat *bid, const int *param);
str ALGselect1(bat *result, const bat *bid, const void *low, const void *high,
const bit *li, const bit *hi, const bit *anti);
str ALGselect2(bat *result, const bat *bid, const bat *sid, const void *low,
const void *high, const bit *li, const bit *hi, const bit *anti);
str ALGselectNotNil(bat *result, const bat *bid);
@@ -728,14 +727,9 @@ str ALGsort33(bat *result, bat *norder,
str ALGstdev(dbl *res, const bat *bid);
str ALGstdevp(dbl *res, const bat *bid);
str ALGsubslice_lng(bat *ret, const bat *bid, const lng *start, const lng
*end);
-str ALGtdiff(bat *result, const bat *lid, const bat *rid);
str ALGthetajoin(bat *r1, bat *r2, const bat *l, const bat *r, const bat *sl,
const bat *sr, const int *op, const bit *nil_matches, const lng *estimate);
str ALGthetaselect1(bat *result, const bat *bid, const void *val, const char
**op);
str ALGthetaselect2(bat *result, const bat *bid, const bat *sid, const void
*val, const char **op);
-str ALGtinter(bat *result, const bat *lid, const bat *rid);
-str ALGtmark(bat *result, const bat *bid, const oid *base);
-str ALGtmark_default(bat *result, const bat *bid);
-str ALGtmarkp(bat *result, const bat *bid, const int *nr_parts, const int
*part_nr);
str ALGunique1(bat *result, const bat *bid);
str ALGunique2(bat *result, const bat *bid, const bat *sid);
str ALGvariance(dbl *res, const bat *bid);
@@ -812,7 +806,6 @@ str BKCisTransient(bit *res, const bat *
str BKCmergecand(bat *ret, const bat *aid, const bat *bid);
str BKCmirror(bat *ret, const bat *bid);
str BKCnewBAT(bat *res, const int *tt, const BUN *cap, int role);
-str BKCpersists(void *r, const bat *bid, const bit *flg);
str BKCreuseBAT(bat *ret, const bat *bid, const bat *did);
str BKCreuseBATmap(bat *ret, const bat *bid, const bat *did);
str BKCsave(bit *res, const char *const *input);
@@ -826,7 +819,6 @@ str BKCsetPersistent(void *r, const bat
str BKCsetTransient(void *r, const bat *bid);
str BKCsetkey(bat *res, const bat *bid, const bit *param);
str BKCshrinkBAT(bat *ret, const bat *bid, const bat *did);
-str BKCshrinkBATmap(bat *ret, const bat *bid, const bat *did);
str BLOBblob_blob(blob **d, blob **s);
str BLOBblob_fromstr(blob **b, str *d);
void BLOBdel(Heap *h, var_t *index);
@@ -988,9 +980,7 @@ str CMDcalcavg(Client cntxt, MalBlkPtr m
str CMDcallBAT(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci);
str CMDcallFunction(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci);
str CMDcallString(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci);
-str CMDcleanup(void *ret);
str CMDcleanupTraces(void *res);
-str CMDclearTrace(void *res);
str CMDcloseProfilerStream(void *res);
str CMDconvert_bit(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci);
str CMDconvert_bte(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci);
@@ -1649,18 +1639,12 @@ str RUNcostPrediction(Client cntxt, MalB
str RUNisolation(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr p);
str RUNpickResult(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr p);
str RUNvolumeCost(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr p);
-str SABAOTHdeserialise(sabdb **ret, str *sabdb);
str SABAOTHfreeStatus(sabdb **ret);
-str SABAOTHgetDBfarm(str *ret);
-str SABAOTHgetDBname(str *ret);
str SABAOTHgetLocalConnection(str *ret);
str SABAOTHgetMyStatus(sabdb **ret);
-str SABAOTHgetStatus(sabdb **ret, str dbname);
-str SABAOTHgetUplogInfo(sabuplog *ret, sabdb *db);
-str SABAOTHmarchConnection(void *ret, str *host, int *port);
-str SABAOTHmarchScenario(void *ret, str *lang);
-str SABAOTHretreatScenario(void *ret, str *lang);
-str SABAOTHserialise(str *ret, sabdb *db);
+str SABAOTHmarchConnection(str *host, int *port);
+str SABAOTHmarchScenario(str *lang);
+str SABAOTHretreatScenario(str *lang);
str SABepilogue(void *ret);
str SABgetLocalConnectionHost(str *ret);
str SABgetLocalConnectionPort(int *ret);
diff --git a/gdk/gdk_batop.c b/gdk/gdk_batop.c
--- a/gdk/gdk_batop.c
+++ b/gdk/gdk_batop.c
@@ -1065,7 +1065,9 @@ BATkeyed(BAT *b)
int
BATordered(BAT *b)
{
- lng t0 = GDKusec();
+ lng t0 = 0;
+
+ ALGODEBUG t0 = GDKusec();
if (b->ttype == TYPE_void)
return 1;
@@ -1151,7 +1153,9 @@ BATordered(BAT *b)
int
BATordered_rev(BAT *b)
{
- lng t0 = GDKusec();
+ lng t0 = 0;
+
+ ALGODEBUG t0 = GDKusec();
if (b == NULL)
return 0;
diff --git a/gdk/gdk_hash.c b/gdk/gdk_hash.c
--- a/gdk/gdk_hash.c
+++ b/gdk/gdk_hash.c
@@ -193,11 +193,11 @@ int
BATcheckhash(BAT *b)
{
int ret;
- lng t;
+ lng t = 0;
- t = GDKusec();
+ ALGODEBUG t = GDKusec();
MT_lock_set(&GDKhashLock(b->batCacheid));
- t = GDKusec() - t;
+ ALGODEBUG t = GDKusec() - t;
if (b->thash == (Hash *) 1) {
Hash *h;
Heap *hp;
@@ -285,9 +285,11 @@ BAThashsync(void *arg)
struct hashsync *hs = arg;
Heap *hp = hs->hp;
int fd;
- lng t0 = GDKusec();
+ lng t0 = 0;
const char *failed = " failed";
+ ALGODEBUG t0 = GDKusec();
+
if (HEAPsave(hp, hp->filename, NULL) == GDK_SUCCEED &&
(fd = GDKfdlocate(hp->farmid, hp->filename, "rb+", NULL)) >= 0) {
((size_t *) hp->base)[0] |= 1 << 24;
@@ -391,7 +393,7 @@ BAThash(BAT *b, BUN masksize)
p = q;
}
- t0 = GDKusec();
+ ALGODEBUG t0 = GDKusec();
do {
BUN nslots = mask >> 3; /* 1/8 full is too full */
@@ -519,9 +521,11 @@ BAThash(BAT *b, BUN masksize)
ALGODEBUG fprintf(stderr, "#BAThash: NOT persisting
hash %d\n", b->batCacheid);
#endif
b->thash = h;
- t1 = GDKusec();
- ALGODEBUG fprintf(stderr, "#BAThash: hash construction " LLFMT
" usec\n", t1 - t0);
- ALGODEBUG HASHcollisions(b, b->thash);
+ ALGODEBUG {
+ t1 = GDKusec();
+ fprintf(stderr, "#BAThash: hash construction " LLFMT "
usec\n", t1 - t0);
+ HASHcollisions(b, b->thash);
+ }
}
MT_lock_unset(&GDKhashLock(b->batCacheid));
return GDK_SUCCEED;
diff --git a/gdk/gdk_imprints.c b/gdk/gdk_imprints.c
--- a/gdk/gdk_imprints.c
+++ b/gdk/gdk_imprints.c
@@ -279,7 +279,7 @@ BATimprints(BAT *b)
{
BAT *o = NULL, *s1 = NULL, *s2 = NULL, *s3 = NULL, *s4 = NULL;
Imprints *imprints;
- lng t0 = 0, t1 = 0;
+ lng t0 = 0;
/* we only create imprints for types that look like types we know */
switch (ATOMbasetype(b->ttype)) {
@@ -316,7 +316,7 @@ BATimprints(BAT *b)
assert(b->timprints == NULL);
}
MT_lock_set(&GDKimprintsLock(b->batCacheid));
- t0 = GDKusec();
+ ALGODEBUG t0 = GDKusec();
if (b->timprints == NULL) {
BUN cnt;
str nme = BBP_physical(b->batCacheid);
@@ -496,8 +496,7 @@ BATimprints(BAT *b)
b->timprints = imprints;
}
- t1 = GDKusec();
- ALGODEBUG fprintf(stderr, "#BATimprints: imprints construction " LLFMT
" usec\n", t1 - t0);
+ ALGODEBUG fprintf(stderr, "#BATimprints: imprints construction " LLFMT
" usec\n", GDKusec() - t0);
MT_lock_unset(&GDKimprintsLock(b->batCacheid));
/* BBPUnfix tries to get the imprints lock which might lead to a
deadlock
diff --git a/gdk/gdk_join.c b/gdk/gdk_join.c
--- a/gdk/gdk_join.c
+++ b/gdk/gdk_join.c
@@ -3821,7 +3821,8 @@ gdk_return
BATleftjoin(BAT **r1p, BAT **r2p, BAT *l, BAT *r, BAT *sl, BAT *sr, int
nil_matches, BUN estimate)
{
return subleftjoin(r1p, r2p, l, r, sl, sr, nil_matches,
- 0, 0, 0, estimate, "BATleftjoin", GDKusec());
+ 0, 0, 0, estimate, "BATleftjoin",
+ GDKdebug & ALGOMASK ? GDKusec() : 0);
}
/* Performs a left outer join over l and r. Returns two new, aligned,
@@ -3833,7 +3834,8 @@ gdk_return
BATouterjoin(BAT **r1p, BAT **r2p, BAT *l, BAT *r, BAT *sl, BAT *sr, int
nil_matches, BUN estimate)
{
return subleftjoin(r1p, r2p, l, r, sl, sr, nil_matches,
- 1, 0, 0, estimate, "BATouterjoin", GDKusec());
+ 1, 0, 0, estimate, "BATouterjoin",
+ GDKdebug & ALGOMASK ? GDKusec() : 0);
}
/* Perform a semi-join over l and r. Returns two new, aligned,
@@ -3844,7 +3846,8 @@ gdk_return
BATsemijoin(BAT **r1p, BAT **r2p, BAT *l, BAT *r, BAT *sl, BAT *sr, int
nil_matches, BUN estimate)
{
return subleftjoin(r1p, r2p, l, r, sl, sr, nil_matches,
- 0, 1, 0, estimate, "BATsemijoin", GDKusec());
+ 0, 1, 0, estimate, "BATsemijoin",
+ GDKdebug & ALGOMASK ? GDKusec() : 0);
}
/* Return the difference of l and r. The result is a BAT with in the
@@ -3857,7 +3860,8 @@ BATdiff(BAT *l, BAT *r, BAT *sl, BAT *sr
BAT *bn;
if (subleftjoin(&bn, NULL, l, r, sl, sr, nil_matches,
- 0, 0, 1, estimate, "BATdiff", GDKusec()) == GDK_SUCCEED)
+ 0, 0, 1, estimate, "BATdiff",
+ GDKdebug & ALGOMASK ? GDKusec() : 0) == GDK_SUCCEED)
return bn;
return NULL;
}
@@ -3868,7 +3872,7 @@ BATthetajoin(BAT **r1p, BAT **r2p, BAT *
BAT *r1, *r2;
BUN maxsize;
int opcode = 0;
- lng t0;
+ lng t0 = 0;
/* encode operator as a bit mask into opcode */
switch (op) {
@@ -3894,7 +3898,7 @@ BATthetajoin(BAT **r1p, BAT **r2p, BAT *
return GDK_FAIL;
}
- t0 = GDKusec();
+ ALGODEBUG t0 = GDKusec();
*r1p = NULL;
*r2p = NULL;
if (joinparamcheck(l, r, NULL, sl, sr, "BATthetajoin") != GDK_SUCCEED)
@@ -3920,9 +3924,11 @@ BATjoin(BAT **r1p, BAT **r2p, BAT *l, BA
#endif
int swap;
size_t mem_size;
- lng t0 = GDKusec();
+ lng t0 = 0;
const char *reason = "";
+ ALGODEBUG t0 = GDKusec();
+
*r1p = NULL;
*r2p = NULL;
if (joinparamcheck(l, r, NULL, sl, sr, "BATjoin") != GDK_SUCCEED)
@@ -4067,7 +4073,9 @@ BATbandjoin(BAT **r1p, BAT **r2p, BAT *l
{
BAT *r1, *r2;
BUN maxsize;
- lng t0 = GDKusec();
+ lng t0 = 0;
+
+ ALGODEBUG t0 = GDKusec();
*r1p = NULL;
*r2p = NULL;
diff --git a/gdk/gdk_orderidx.c b/gdk/gdk_orderidx.c
--- a/gdk/gdk_orderidx.c
+++ b/gdk/gdk_orderidx.c
@@ -25,7 +25,9 @@ BATidxsync(void *arg)
struct idxsync *hs = arg;
Heap *hp = hs->hp;
int fd;
- lng t0 = GDKusec();
+ lng t0 = 0;
+
+ ALGODEBUG t0 = GDKusec();
if (HEAPsave(hp, hp->filename, NULL) != GDK_SUCCEED ||
(fd = GDKfdlocate(hp->farmid, hp->filename, "rb+", NULL)) < 0) {
@@ -58,10 +60,10 @@ int
BATcheckorderidx(BAT *b)
{
int ret;
- lng t;
+ lng t = 0;
assert(b->batCacheid > 0);
- t = GDKusec();
+ ALGODEBUG t = GDKusec();
MT_lock_set(&GDKhashLock(b->batCacheid));
if (b->torderidx == (Heap *) 1) {
Heap *hp;
diff --git a/gdk/gdk_project.c b/gdk/gdk_project.c
--- a/gdk/gdk_project.c
+++ b/gdk/gdk_project.c
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list