Update of /cvsroot/monetdb/pathfinder/runtime
In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv28473/pathfinder/runtime
Modified Files:
pf_support.mx
Log Message:
(hopefully) fixing my yesterday's checkin of reverse-sortedt merged_union():
make sure we properly treat (cast) GDK_SORTED_REV as (bit).
(Thanks to Henning for testing!)
U pf_support.mx
Index: pf_support.mx
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/runtime/pf_support.mx,v
retrieving revision 1.337
retrieving revision 1.338
diff -u -d -r1.337 -r1.338
--- pf_support.mx 14 Oct 2009 17:46:37 -0000 1.337
+++ pf_support.mx 15 Oct 2009 08:40:02 -0000 1.338
@@ -6233,13 +6233,13 @@
/* check arguments */
for (t=0; t<ntabs && BATcount(b[t][0]) <= 1; t++);
- if (t<ntabs && !(BATtordered(b[t][0])&1) && !(reverse =
(BATtordered(b[t][0]) == GDK_SORTED_REV))) {
+ if (t<ntabs && !(BATtordered(b[t][0])&1) && !(reverse =
(BATtordered(b[t][0]) == (bit) GDK_SORTED_REV))) {
GDKerror("merged_union: tail of first BAT/column of table %d
must be (reverse-)sorted.\n", t+1);
return GDK_FAIL;
}
if (reverse) {
for (; t<ntabs; t++) {
- if (BATcount(b[t][0])>1 && !(BATtordered(b[t][0]) ==
GDK_SORTED_REV)) {
+ if (BATcount(b[t][0])>1 && !(BATtordered(b[t][0]) ==
(bit) GDK_SORTED_REV)) {
GDKerror("merged_union: tail of first
BAT/column of table %d must be reverse-sorted.\n", t+1);
return GDK_FAIL;
}
@@ -6390,7 +6390,7 @@
concat01 = (cnt[0]==0 || cnt[1]==0);
concat10 = FALSE;
if (reverse) {
- if ((BATtordered(src[0]) == GDK_SORTED_REV &&
BATtordered(src[1]) == GDK_SORTED_REV) || (BATtordered(src[0]) ==
GDK_SORTED_REV && cnt[1]==1) || (cnt[0]==1 && BATtordered(src[1]) ==
GDK_SORTED_REV) ) {
+ if ((BATtordered(src[0]) == (bit) GDK_SORTED_REV &&
BATtordered(src[1]) == (bit) GDK_SORTED_REV) || (BATtordered(src[0]) == (bit)
GDK_SORTED_REV && cnt[1]==1) || (cnt[0]==1 && BATtordered(src[1]) == (bit)
GDK_SORTED_REV) ) {
if (!concat01) {
concat01 =
@4_GE(b...@2(srci[0],BUNlast(src[0])-1),b...@3(srci[1],BUNfirst(src[1])),@1);
}
@@ -6494,7 +6494,7 @@
BATsetcount(tgt, (dst[0] - BUNfirst(tgt)));
if (!tgt->batDirty) tgt->batDirty = TRUE;
BATkey(BATmirror(tgt),FALSE);
- tgt->tsorted = (reverse ? GDK_SORTED_REV : GDK_SORTED);
+ tgt->tsorted = (reverse ? (bit) GDK_SORTED_REV : GDK_SORTED);
tgt->tdense = FALSE;
if (void_fix) {
BBPunfix(src[0]->batCacheid);
@@ -6608,7 +6608,7 @@
BATkey(BATmirror(bn[c]),(res_count < 2));
bn[c]->hsorted = GDK_SORTED;
if (c == 0) {
- bn[c]->tsorted = (reverse ? GDK_SORTED_REV :
GDK_SORTED);
+ bn[c]->tsorted = (reverse ? (bit) GDK_SORTED_REV :
GDK_SORTED);
} else
if (res_count < 2) {
bn[c]->tsorted = GDK_SORTED;
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Monetdb-pf-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-pf-checkins