Update of /cvsroot/monetdb/pathfinder/runtime
In directory sc8-pr-cvs16:/tmp/cvs-serv19650/runtime
Modified Files:
pathfinder.mx pf_support.mx
Log Message:
fix as found and suggested by Peter:
turned MIL PROC ws_bat into a C function (MIL command)
that explicitly return a view on the requested ws BAT;
this seems to fix some isolation / concurrent access problems
that occured with multiple concurrent update queries, e.g.,
in the TPoX benchmark
Index: pathfinder.mx
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/runtime/pathfinder.mx,v
retrieving revision 1.348
retrieving revision 1.349
diff -u -d -r1.348 -r1.349
--- pathfinder.mx 20 Apr 2007 22:49:55 -0000 1.348
+++ pathfinder.mx 22 Apr 2007 11:15:05 -0000 1.349
@@ -1384,12 +1384,6 @@
return lng(bbpname(ws));
}
-# retrieve BAT ws that belongs to wsid; note that you must be sure that it is
still alive
-PROC ws_bat(lng wsid) : BAT[void,bat]
-{
- return bat(and(wsid, 1073741823LL));
-}
-
PROC _ws_free(lng wsid) : BAT[void,any]
{
# remove the dependencies of this query (modifies ws_overlaps_ws)
Index: pf_support.mx
===================================================================
RCS file: /cvsroot/monetdb/pathfinder/runtime/pf_support.mx,v
retrieving revision 1.215
retrieving revision 1.216
diff -u -d -r1.215 -r1.216
--- pf_support.mx 21 Apr 2007 09:17:46 -0000 1.215
+++ pf_support.mx 22 Apr 2007 11:15:06 -0000 1.216
@@ -395,6 +395,12 @@
"return false if there is an active document mgt query.
NOTE: you *must* have the short lock when executing this!!"
[EMAIL PROTECTED] retrieve BAT ws that belongs to wsid; note that you must be
sure that it is still alive
[EMAIL PROTECTED]
+.COMMAND ws_bat(lng wsid) : BAT[void,bat] = CMDws_bat;
+ "retrieve BAT ws that belongs to wsid; note that you must be sure that it is
still alive"
+
+
.PRELUDE = pf_support_prelude;
.EPILOGUE = pf_support_epilogue;
@@ -6844,6 +6850,19 @@
return GDK_SUCCEED;
}
+/* retrieve BAT ws that belongs to wsid; note that you must be sure that it is
still alive */
+int CMDws_bat(BAT **ret, lng* wsid)
+{
+ bat bid = *wsid & 1073741823LL;
+ BAT *v = NULL;
+ if (BBPfix(bid)) {
+ BAT *b = BBPdescriptor(bid);
+ if (b) *ret = v = VIEWcreate(b);
+ BBPunfix(bid);
+ }
+ return v?GDK_SUCCEED:GDK_FAIL;
+}
+
#include "serialize.h"
int
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Monetdb-pf-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-pf-checkins