Update of /cvsroot/monetdb/pathfinder/runtime
In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv9298/runtime
Modified Files:
Tag: Nov2009
pathfinder.mx shredder.mx xrpc_client.mx
Log Message:
my batch of promised bugfixes for Nov2009
- disable prepared query mechanism for function-only queries (avoid mps!)
- make heuristic to use indices even more strict (not inside the where clause
of a for-loop with >1 variables, as it may be a join).
- fix property bug in shredder (in case of tables with a single tuple, being
appended to my a incremental multi-doc shred).
- fix simple bug (crash in printf format) in xrpc_client
Index: xrpc_client.mx
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/runtime/xrpc_client.mx,v
retrieving revision 1.56
retrieving revision 1.56.2.1
diff -u -d -r1.56 -r1.56.2.1
--- xrpc_client.mx 22 Sep 2009 10:37:58 -0000 1.56
+++ xrpc_client.mx 12 Nov 2009 01:45:18 -0000 1.56.2.1
@@ -939,8 +939,8 @@
updCall?"true":"false");
} else {
ret = stream_printf(bs, XRPC_REQ_BODY, rpc_module, rpc_uri,
- rpc_method, arity, iterc, xrpc_hostport,
- seqnr, updCall?"true":"false");
+ rpc_method, arity, iterc, updCall?"true":"false",
+ xrpc_hostport, seqnr);
}
if (ret < 0)
return clean_up(bs, argcnt, iterc);
Index: pathfinder.mx
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/runtime/pathfinder.mx,v
retrieving revision 1.462.4.7
retrieving revision 1.462.4.8
diff -u -d -r1.462.4.7 -r1.462.4.8
--- pathfinder.mx 10 Nov 2009 18:15:32 -0000 1.462.4.7
+++ pathfinder.mx 12 Nov 2009 01:45:16 -0000 1.462.4.8
@@ -5917,6 +5917,7 @@
return p+1;
}
+#ifdef XQUERY_PREPARE
/*
* parse an XML datamodel numeric, and determine its minimal type (xs:integer,
xs:decimal or xs:double)
*/
@@ -5949,16 +5950,19 @@
* from a cached MIL tree. Otherwise use pathfinder to compile. Returns error
string (NULL if ok).
*/
static char xquery_too_complex[80] = "xquery_prepare: xquery is too complex
for cached execution.\n";
+#endif
#define xquery_nondescriptive_error ((char*) -1)
+
static char*
xquery_prepare(xquery_client *ctx,
lng usec,
char* query)
{
+ char *err = NULL;
+#ifdef XQUERY_PREPARE
int nsbuf = 0, loaded_modules = 0, len;
char *ns = (char*)&nsbuf, *nsend = ns, *locend, *loc = NULL, *q, *p =
query;
char val[1024], url1[1024], url2[1024];
- char *err = NULL;
if (ctx->mode&XQ_DEBUG) {
/* for debugging purposes, we simulate a full MIL on the log; even if
parts are cached */
@@ -6141,7 +6145,11 @@
*/
if (err == xquery_function_error) /* MIL execution failed, do not generate
error in PF compiler */
return xquery_nondescriptive_error;
- if (err) {
+ if (err)
+#else
+ (void) usec;
+#endif
+ {
char *sec1 = NULL;
char *sec2 = NULL;
char *sec3 = NULL;
Index: shredder.mx
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/runtime/shredder.mx,v
retrieving revision 1.159.6.1
retrieving revision 1.159.6.2
diff -u -d -r1.159.6.1 -r1.159.6.2
--- shredder.mx 7 Oct 2009 15:46:50 -0000 1.159.6.1
+++ shredder.mx 12 Nov 2009 01:45:18 -0000 1.159.6.2
@@ -282,25 +282,25 @@
/* values of the static properties of a result BAT */
static shredBATdef shredbatdef[SHRED_BATS] = {
- { MAP_PID, "_map_pid", TYPE_void, TYPE_void, 1.0/65336, 0},
+ { MAP_PID, "_map_pid", TYPE_void, TYPE_void, 1.0/65336, 2},
{ PRE_SIZE, "_rid_size", TYPE_void, TYPE_int, 1.0, 0},
{ PRE_SIZE, "_rid_level", TYPE_void, TYPE_chr, 1.0, 0},
{ PRE_SIZE, "_rid_prop", TYPE_void, TYPE_oid, 1.0, 0},
{ PRE_SIZE, "_rid_kind", TYPE_void, TYPE_chr, 1.0, 0},
- { PRE_SIZE, "_rid_nid", TYPE_void, TYPE_void, 1.0, 0},
- { NID_RID, "_nid_rid", TYPE_void, TYPE_void, 1.0, 0},
- { FRAG_ROOT, "_frag_root", TYPE_oid, TYPE_oid, 0.0, 0},
- { QN_HISTOGRAM, "_qn_histogram", TYPE_void, TYPE_lng, 0.0, 1},
+ { PRE_SIZE, "_rid_nid", TYPE_void, TYPE_void, 1.0, 2},
+ { NID_RID, "_nid_rid", TYPE_void, TYPE_void, 1.0, 2},
+ { FRAG_ROOT, "_frag_root", TYPE_oid, TYPE_oid, 0.0, 2},
+ { QN_HISTOGRAM, "_qn_histogram", TYPE_void, TYPE_lng, 0.0, 0},
{ QN_HISTOGRAM, "_qn_prefix_uri_loc",TYPE_void, TYPE_str, 0.0, 1},
{ QN_HISTOGRAM, "_qn_uri_loc", TYPE_void, TYPE_str, 0.0, 0},
{ QN_HISTOGRAM, "_qn_prefix", TYPE_void, TYPE_str, 0.0, 0},
{ QN_HISTOGRAM, "_qn_uri", TYPE_void, TYPE_str, 0.0, 0},
{ QN_HISTOGRAM, "_qn_loc", TYPE_void, TYPE_str, 0.0, 0},
{ PROP_TEXT, "_prop_text", TYPE_void, TYPE_str, 0.3, 0},
- { PROP_COM, "_prop_com", TYPE_void, TYPE_str, 0.0, 1},
+ { PROP_COM, "_prop_com", TYPE_void, TYPE_str, 0.0, 0},
{ PROP_INS, "_prop_ins", TYPE_void, TYPE_str, 0.0, 0},
{ PROP_TGT, "_prop_tgt", TYPE_void, TYPE_str, 0.0, 0},
- { PROP_VAL, "_prop_val", TYPE_void, TYPE_str, 0.1, 1},
+ { PROP_VAL, "_prop_val", TYPE_void, TYPE_str, 0.1, 0},
{ ATTR_OWN, "_attr_own", TYPE_void, TYPE_oid, 0.3, 0},
{ ATTR_OWN, "_attr_qn", TYPE_void, TYPE_oid, 0.3, 0},
{ ATTR_OWN, "_attr_prop", TYPE_void, TYPE_oid, 0.3, 0}
@@ -1707,7 +1707,7 @@
shredCtx->dstBAT[sb->def->table].bat->batCacheid);
return shredder_free(shredCtx, 0);
}
- if (!sb->def->compress) {
+ if (sb->def->compress != 1) {
HASHremove(sb->bat); /* we don't maintain accelerators other
than those explicity needed for compress */
}
sb->size = BUNlast(sb->bat);
@@ -1869,7 +1869,7 @@
stream_printf(GDKout, "# [%9s, ", sb->def->name);
stream_printf(GDKout, "cnt=%d", cnt);
- if (sb->def->compress) {
+ if (sb->def->compress == 1) {
stream_printf(GDKout, ", dupl=%d(=%.f%%) ",
sb->dupl,((sb->dupl+cnt)?100.0*(float)(cnt)/(float)(sb->dupl+cnt):100.0));
}
if (i == PRE_SIZE)
@@ -1932,20 +1932,13 @@
* in the size & kind BATs, we omit an expensive check to find out
* whether it might still hold...)
*/
- if (shredCtx->dstBAT[PRE_SIZE].bat->tkey == TRUE) {
- shredCtx->dstBAT[PRE_SIZE].bat->tsorted = 0;
- shredCtx->dstBAT[PRE_SIZE].bat->tdense = 0;
- shredCtx->dstBAT[PRE_SIZE].bat->T->nonil = 0;
- BATkey(BATmirror(shredCtx->dstBAT[PRE_SIZE].bat), FALSE);
- }
- if (shredCtx->dstBAT[PRE_KIND].bat->tkey == TRUE) {
- shredCtx->dstBAT[PRE_KIND].bat->tsorted = 0;
- shredCtx->dstBAT[PRE_KIND].bat->tdense = 0;
- shredCtx->dstBAT[PRE_KIND].bat->T->nonil = 0;
- BATkey(BATmirror(shredCtx->dstBAT[PRE_KIND].bat), FALSE);
- }
- if (shredCtx->dstBAT[ATTR_PROP].bat->tkey == TRUE) {
- BATkey(BATmirror(shredCtx->dstBAT[ATTR_PROP].bat), FALSE);
+ for(i=0; i<SHRED_BATS; i++) {
+ if (shredbatdef[i].compress == 0 && shredCtx->dstBAT[i].bat->tkey
== TRUE) {
+ shredCtx->dstBAT[i].bat->tsorted = 0;
+ shredCtx->dstBAT[i].bat->tdense = 0;
+ shredCtx->dstBAT[i].bat->T->nonil = 0;
+ BATkey(BATmirror(shredCtx->dstBAT[i].bat), FALSE);
+ }
}
}
assert((shredCtx->updatable && shredCtx->nnode_nid <= newsize) ||
(!shredCtx->updatable && shredCtx->nnode_nid == newsize));
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now. http://p.sf.net/sfu/bobj-july
_______________________________________________
Monetdb-pf-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-pf-checkins