Changeset: 2852c00d6e59 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=2852c00d6e59 Removed Files: monetdb5/mal/mal_sabaoth.c monetdb5/mal/mal_sabaoth.h monetdb5/modules/kernel/logger.c monetdb5/modules/kernel/logger.mal monetdb5/modules/mal/sabaoth.c monetdb5/modules/mal/sabaoth.h monetdb5/modules/mal/sabaoth.mal sql/storage/bat/nop_logger.c sql/storage/bat/nop_logger.h Modified Files: clients/Tests/MAL-signatures.stable.out clients/Tests/MAL-signatures.stable.out.int128 clients/Tests/exports.stable.out clients/mapiclient/dotmonetdb.c clients/mapiclient/tachograph.c clients/mapiclient/tomograph.c common/utils/msabaoth.c common/utils/msabaoth.h configure.ag gdk/gdk_bbp.c gdk/gdk_logger.c gdk/gdk_logger.h gdk/gdk_tm.c monetdb5/mal/Makefile.ag monetdb5/mal/Tests/All monetdb5/mal/mal.c monetdb5/mal/mal.h monetdb5/mal/mal_authorize.c monetdb5/mal/mal_authorize.h monetdb5/mal/mal_client.h monetdb5/mal/mal_debugger.c monetdb5/mal/mal_debugger.h monetdb5/mal/mal_factory.c monetdb5/mal/mal_instruction.c monetdb5/mal/mal_interpreter.c monetdb5/mal/mal_linker.h monetdb5/mal/mal_listing.h monetdb5/mal/mal_namespace.h monetdb5/mal/mal_profiler.c monetdb5/mal/mal_profiler.h monetdb5/mal/mal_resolve.c monetdb5/mal/mal_resolve.h monetdb5/mal/mal_session.c monetdb5/modules/kernel/Makefile.ag monetdb5/modules/mal/Makefile.ag monetdb5/modules/mal/clients.c monetdb5/modules/mal/mal_init.mal monetdb5/modules/mal/mal_mapi.c monetdb5/modules/mal/mdb.c sql/backends/monet5/sql_assert.c sql/backends/monet5/sql_gencode.c sql/backends/monet5/sql_scenario.c sql/storage/bat/Makefile.ag sql/storage/sql_storage.h sql/storage/store.c sql/test/BugTracker-2013/Tests/All sql/test/BugTracker-2017/Tests/All sql/test/BugTracker-2018/Tests/All sql/test/BugTracker-2019/Tests/All sql/test/Triggers/Tests/All sql/test/emptydb-upgrade-chain-hge/Tests/All sql/test/emptydb-upgrade-chain/Tests/All sql/test/emptydb-upgrade/Tests/All sql/test/mergetables/Tests/All sql/test/wlcr/Tests/All testing/Mtest.py.in tools/mserver/mserver5.c Branch: context Log Message:
merged with default diffs (truncated from 3972 to 300 lines): diff --git a/clients/Tests/MAL-signatures.stable.out b/clients/Tests/MAL-signatures.stable.out --- a/clients/Tests/MAL-signatures.stable.out +++ b/clients/Tests/MAL-signatures.stable.out @@ -11621,14 +11621,6 @@ stdout of test 'MAL-signatures` in direc [ "remote", "register", "pattern remote.register(conn:str, mod:str, fcn:str):void ", "RMTregister;", "register <mod>.<fcn> at the remote site" ] [ "remote", "register_supervisor", "command remote.register_supervisor(sup_uuid:str, query_uuid:str):int ", "RMTregisterSupervisor;", "Register the supervisor uuid at a remote site" ] [ "remote", "resolve", "command remote.resolve(pattern:str):bat[:str] ", "RMTresolve;", "resolve a pattern against Merovingian and return the URIs" ] -[ "sabaoth", "epilogue", "command sabaoth.epilogue():void ", "SABepilogue;", "Release the resources held by the sabaoth module" ] -[ "sabaoth", "getLocalConnectionHost", "command sabaoth.getLocalConnectionHost():str ", "SABgetLocalConnectionHost;", "Returns the hostname this server can be connected to, or nil if none" ] -[ "sabaoth", "getLocalConnectionPort", "command sabaoth.getLocalConnectionPort():int ", "SABgetLocalConnectionPort;", "Returns the port this server can be connected to, or 0 if none" ] -[ "sabaoth", "getLocalConnectionURI", "command sabaoth.getLocalConnectionURI():str ", "SABgetLocalConnectionURI;", "Returns the URI this server can be connected to, or nil if none" ] -[ "sabaoth", "marchConnection", "command sabaoth.marchConnection(host:str, port:int):void ", "SABmarchConnection;", "Publishes the given host/port as available for connecting to this server" ] -[ "sabaoth", "marchScenario", "command sabaoth.marchScenario(lang:str):void ", "SABmarchScenario;", "Publishes the given language as available for this server" ] -[ "sabaoth", "prelude", "command sabaoth.prelude():void ", "SABprelude;", "Initialise the sabaoth module" ] -[ "sabaoth", "retreatScenario", "command sabaoth.retreatScenario(lang:str):void ", "SABretreatScenario;", "Unpublishes the given language as available for this server" ] [ "sample", "subuniform", "pattern sample.subuniform(b:bat[:any], p:dbl):bat[:oid] ", "SAMPLEuniform;", "Returns the oids of a uniform sample of size = (p x count(b)), where 0 <= p <= 1.0" ] [ "sample", "subuniform", "pattern sample.subuniform(b:bat[:any], p:dbl, sample_seed:int):bat[:oid] ", "SAMPLEuniform;", "Returns the oids of a uniform sample of size = (p x count(b)), where 0 <= p <= 1.0 and where the prg is seeded with sample_seed" ] [ "sample", "subuniform", "pattern sample.subuniform(b:bat[:any], sample_size:lng):bat[:oid] ", "SAMPLEuniform;", "Returns the oids of a uniform sample of size s" ] diff --git a/clients/Tests/MAL-signatures.stable.out.int128 b/clients/Tests/MAL-signatures.stable.out.int128 --- a/clients/Tests/MAL-signatures.stable.out.int128 +++ b/clients/Tests/MAL-signatures.stable.out.int128 @@ -16033,14 +16033,6 @@ stdout of test 'MAL-signatures` in direc [ "remote", "register", "pattern remote.register(conn:str, mod:str, fcn:str):void ", "RMTregister;", "register <mod>.<fcn> at the remote site" ] [ "remote", "register_supervisor", "command remote.register_supervisor(sup_uuid:str, query_uuid:str):int ", "RMTregisterSupervisor;", "Register the supervisor uuid at a remote site" ] [ "remote", "resolve", "command remote.resolve(pattern:str):bat[:str] ", "RMTresolve;", "resolve a pattern against Merovingian and return the URIs" ] -[ "sabaoth", "epilogue", "command sabaoth.epilogue():void ", "SABepilogue;", "Release the resources held by the sabaoth module" ] -[ "sabaoth", "getLocalConnectionHost", "command sabaoth.getLocalConnectionHost():str ", "SABgetLocalConnectionHost;", "Returns the hostname this server can be connected to, or nil if none" ] -[ "sabaoth", "getLocalConnectionPort", "command sabaoth.getLocalConnectionPort():int ", "SABgetLocalConnectionPort;", "Returns the port this server can be connected to, or 0 if none" ] -[ "sabaoth", "getLocalConnectionURI", "command sabaoth.getLocalConnectionURI():str ", "SABgetLocalConnectionURI;", "Returns the URI this server can be connected to, or nil if none" ] -[ "sabaoth", "marchConnection", "command sabaoth.marchConnection(host:str, port:int):void ", "SABmarchConnection;", "Publishes the given host/port as available for connecting to this server" ] -[ "sabaoth", "marchScenario", "command sabaoth.marchScenario(lang:str):void ", "SABmarchScenario;", "Publishes the given language as available for this server" ] -[ "sabaoth", "prelude", "command sabaoth.prelude():void ", "SABprelude;", "Initialise the sabaoth module" ] -[ "sabaoth", "retreatScenario", "command sabaoth.retreatScenario(lang:str):void ", "SABretreatScenario;", "Unpublishes the given language as available for this server" ] [ "sample", "subuniform", "pattern sample.subuniform(b:bat[:any], p:dbl):bat[:oid] ", "SAMPLEuniform;", "Returns the oids of a uniform sample of size = (p x count(b)), where 0 <= p <= 1.0" ] [ "sample", "subuniform", "pattern sample.subuniform(b:bat[:any], p:dbl, sample_seed:int):bat[:oid] ", "SAMPLEuniform;", "Returns the oids of a uniform sample of size = (p x count(b)), where 0 <= p <= 1.0 and where the prg is seeded with sample_seed" ] [ "sample", "subuniform", "pattern sample.subuniform(b:bat[:any], sample_size:lng):bat[:oid] ", "SAMPLEuniform;", "Returns the oids of a uniform sample of size s" ] 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 @@ -443,8 +443,6 @@ gdk_return logger_del_bat(logger *lg, lo void logger_destroy(logger *lg); gdk_return logger_exit(logger *lg); log_bid logger_find_bat(logger *lg, const char *name, char tpe, oid id); -lng logger_read_last_transaction_id(logger *lg, char *dir, char *logger_file, role_t role); -gdk_return logger_reload(logger *lg); gdk_return logger_restart(logger *lg); int logger_sequence(logger *lg, int seq, lng *id); gdk_return logger_upgrade_bat(logger *lg, const char *name, char tpe, oid id) __attribute__((__warn_unused_result__)); @@ -1424,7 +1422,6 @@ str MBMuniform(bat *ret, oid *base, lng int MCactiveClients(void); str MCawakeClient(int id); void MCcloseClient(Client c); -int MCdefault; Client MCforkClient(Client father); Client MCgetClient(int id); bool MCinit(void); @@ -1437,7 +1434,6 @@ str MCsuspendClient(int id); int MCvalid(Client c); str MDBStkDepth(Client cntxt, MalBlkPtr mb, MalStkPtr s, InstrPtr p); str MDBStkTrace(Client cntxt, MalBlkPtr m, MalStkPtr s, InstrPtr p); -int MDBdelay; str MDBdummy(int *ret); str MDBdump(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); str MDBgetDebug(int *ret); @@ -1732,20 +1728,6 @@ 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 SABAOTHfreeStatus(sabdb **ret); -str SABAOTHgetLocalConnection(str *ret); -str SABAOTHgetMyStatus(sabdb **ret); -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); -str SABgetLocalConnectionURI(str *ret); -str SABmarchConnection(void *ret, str *host, int *port); -str SABmarchScenario(void *ret, str *lang); -str SABprelude(void *ret); -str SABretreatScenario(void *ret, str *lang); str SAMPLEuniform(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); str SERVERbindBAT(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); str SERVERclient(void *res, const Stream *In, const Stream *Out); @@ -2171,7 +2153,6 @@ str escape_str(str *retval, str s); str evalFile(str fname, int listing); str evalRef; str execRef; -void expandMacro(MalBlkPtr mb, InstrPtr p, MalBlkPtr mc); str expandRef; str exportOperationRef; str export_tableRef; @@ -2185,7 +2166,6 @@ Symbol findSymbol(Module usermodule, str Symbol findSymbolInModule(Module v, str fcn); int findVariable(MalBlkPtr mb, const char *name); int findVariableLength(MalBlkPtr mb, str name, int len); -void finishNamespace(void); str finishRef; void finishSessionProfiler(Client cntxt); str first_valueRef; @@ -2286,7 +2266,6 @@ int inlineMALblock(MalBlkPtr mb, int pc, str inplaceRef; void insertSymbol(Module scope, Symbol prg); str instruction2str(MalBlkPtr mb, MalStkPtr stl, InstrPtr p, int hidden); -str instructionCall(MalBlkPtr mb, InstrPtr p, str s, str base, size_t len); str intRef; str intersectRef; str intersectcandRef; @@ -2341,8 +2320,6 @@ str listRef; str loadLibrary(str modulename, int flag); char *locate_file(const char *basename, const char *ext, bit recurse); str lockRef; -str logger_create_wrap(logger *L, int *debug, str *fn, str *dirname, int *version); -str logger_destroy_wrap(void *ret, logger *L); str lookupRef; str mal2str(MalBlkPtr mb, int first, int last); int malAtomSize(int size, const char *name); @@ -2354,7 +2331,6 @@ char *malLibraryHowToEnable(str name); int malProfileMode; str malRef; void mal_atom_reset(void); -MT_Lock mal_beatLock; void mal_client_reset(void) __attribute__((__visibility__("hidden"))); ClientRec *mal_clients; MT_Lock mal_contextLock; @@ -2383,13 +2359,8 @@ str maxRef; str max_no_nilRef; int mayhaveSideEffects(Client cntxt, MalBlkPtr mb, InstrPtr p, int strict); void mdbDump(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); -str mdbGrab(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); str mdbRef; -int mdbSession(void); void mdbSetBreakRequest(Client cntxt, MalBlkPtr mb, str request, char cmd); -int mdbSetTrap(Client cntxt, str modnme, str fcnnme, int flag); -str mdbTrap(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); -str mdbTrapClient(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci); int memoryclaims; lng memorypool; str mergecandRef; @@ -2424,7 +2395,7 @@ void moveInstruction(MalBlkPtr mb, int p void msab_dbfarminit(const char *dbfarm); void msab_dbpathinit(const char *dbpath); char *msab_deserialise(sabdb **ret, char *sabdb); -char *msab_freeStatus(sabdb **ret); +void msab_freeStatus(sabdb **ret); char *msab_getDBfarm(char **ret); char *msab_getDBname(char **ret); char *msab_getMyStatus(sabdb **ret); @@ -2514,7 +2485,6 @@ str projectRef; str projectdeltaRef; str projectionRef; str projectionpathRef; -void promptInstruction(stream *fd, MalBlkPtr mb, MalStkPtr stk, InstrPtr p, int flg); InstrPtr pushArgument(MalBlkPtr mb, InstrPtr p, int varid); InstrPtr pushArgumentId(MalBlkPtr mb, InstrPtr p, const char *name); InstrPtr pushBit(MalBlkPtr mb, InstrPtr q, bit val); @@ -2612,7 +2582,6 @@ str setVariableRef; void setVariableScope(MalBlkPtr mb); str setWriteModeRef; void setprofilerlimit(int limit); -str setprofilerpoolsize(int size); str shortStmtRendering(MalBlkPtr mb, MalStkPtr stl, InstrPtr p); void showAllScenarios(stream *f); void showCurrentScenario(void); diff --git a/clients/mapiclient/dotmonetdb.c b/clients/mapiclient/dotmonetdb.c --- a/clients/mapiclient/dotmonetdb.c +++ b/clients/mapiclient/dotmonetdb.c @@ -39,9 +39,9 @@ parse_dotmonetdb(char **user, char **pas /* empty environment variable: skip the file */ cfile = NULL; } else if ((config = fopen(cfile, "r")) == NULL) { - cfile = NULL; fprintf(stderr, "failed to open file '%s': %s\n", cfile, strerror(errno)); + cfile = NULL; } else { cfile = strdup(cfile); } diff --git a/clients/mapiclient/tachograph.c b/clients/mapiclient/tachograph.c --- a/clients/mapiclient/tachograph.c +++ b/clients/mapiclient/tachograph.c @@ -261,7 +261,7 @@ update(EventRecord *ev) if (starttime == 0) { if (ev->fcn == 0 ) { if (debug) - fprintf(stderr, "Skip %s input %s\n",(ev->state>=0?statenames[ev->state]:"unknown"),ev->fcn); + fprintf(stderr, "Skip %s input\n",(ev->state>=0?statenames[ev->state]:"unknown")); return; } if (debug) diff --git a/clients/mapiclient/tomograph.c b/clients/mapiclient/tomograph.c --- a/clients/mapiclient/tomograph.c +++ b/clients/mapiclient/tomograph.c @@ -1439,7 +1439,7 @@ update(char *line, EventRecord *ev) if (starttime == 0) { if (ev->fcn == 0 ) { if (debug) - fprintf(stderr, "Skip %s input %s\n",(ev->state>=0?statenames[ev->state]:"unknown"),ev->fcn); + fprintf(stderr, "Skip %s input\n",(ev->state>=0?statenames[ev->state]:"unknown")); return; } if (debug) diff --git a/common/utils/msabaoth.c b/common/utils/msabaoth.c --- a/common/utils/msabaoth.c +++ b/common/utils/msabaoth.c @@ -778,7 +778,7 @@ msab_getStatus(sabdb** ret, char *dbname /** * Frees up the sabdb structure returned by getStatus. */ -char * +void msab_freeStatus(sabdb** ret) { sabdb *p, *q; @@ -812,8 +812,6 @@ msab_freeStatus(sabdb** ret) free(p); p = q; } - - return(NULL); } /** diff --git a/common/utils/msabaoth.h b/common/utils/msabaoth.h --- a/common/utils/msabaoth.h +++ b/common/utils/msabaoth.h @@ -75,7 +75,7 @@ msab_export char *msab_registerStarted(v msab_export char *msab_registerStop(void); msab_export char *msab_getMyStatus(sabdb** ret); msab_export char *msab_getStatus(sabdb** ret, char *dbname); -msab_export char *msab_freeStatus(sabdb** ret); +msab_export void msab_freeStatus(sabdb** ret); msab_export char *msab_getUplogInfo(sabuplog *ret, const sabdb *db); msab_export char *msab_serialise(char **ret, const sabdb *db); msab_export char *msab_deserialise(sabdb **ret, char *sabdb); diff --git a/configure.ag b/configure.ag --- a/configure.ag +++ b/configure.ag @@ -2529,7 +2529,7 @@ AC_COMPILE_IFELSE([AC_LANG_SOURCE([[ # checks for library functions AS_CASE([$host], - [*-darwin1[[01234567]]*], [ + [*-darwin1[[012345678]]*], [ # OSX 10.6 (Snow Leopard) and up somehow makes # configure believe that fdatasync exists, in # reality however, it does not on this platform. diff --git a/gdk/gdk_bbp.c b/gdk/gdk_bbp.c --- a/gdk/gdk_bbp.c +++ b/gdk/gdk_bbp.c @@ -1043,6 +1043,13 @@ BBPaddfarm(const char *dirname, int role struct stat st; int i; + if (dirname == NULL) { + assert(BBPfarms[0].dirname == NULL); + assert(rolemask & 1); + assert(BBPfarms[0].roles == 0); + BBPfarms[0].roles = rolemask; + return GDK_SUCCEED; + } if (strchr(dirname, '\n') != NULL) { GDKerror("BBPaddfarm: no newline allowed in directory name\n"); return GDK_FAIL; @@ -1118,12 +1125,7 @@ BBPinit(void) unsigned bbpversion = 0; int i; - if (GDKinmemory()) { - if (BBPaddfarm(".", 1 << PERSISTENT) != GDK_SUCCEED || - BBPaddfarm(".", 1 << TRANSIENT) != GDK_SUCCEED) { - return GDK_FAIL; - } - } else { + if (!GDKinmemory()) { str bbpdirstr, backupbbpdirstr; if (!(bbpdirstr = GDKfilepath(0, BATDIR, "BBP", "dir"))) { @@ -1195,7 +1197,9 @@ BBPinit(void) memset(BBP, 0, sizeof(BBP)); ATOMIC_SET(&BBPsize, 1); - if (!GDKinmemory()) { + if (GDKinmemory()) { + bbpversion = GDKLIBRARY; + } else { bbpversion = BBPheader(fp); if (bbpversion == 0) return GDK_FAIL; @@ -2350,7 +2354,7 @@ decref(bat i, bool logical, bool release * if they have been made cold or are not dirty */ if (BBP_refs(i) > 0 || (BBP_lrefs(i) > 0 && - (b == NULL || BATdirty(b) || !(BBP_status(i) & BBPPERSISTENT)))) { + (b == NULL || BATdirty(b) || !(BBP_status(i) & BBPPERSISTENT) || GDKinmemory()))) { /* bat cannot be swapped out */ } else if (b ? b->batSharecnt == 0 : (BBP_status(i) & BBPTMP)) { /* bat will be unloaded now. set the UNLOADING bit diff --git a/gdk/gdk_logger.c b/gdk/gdk_logger.c _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list