Changeset: 86c5063a7626 for MonetDB URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=86c5063a7626 Added Files: sql/test/BugTracker-2011/Tests/crash_on_alias.Bug-2798.stable.out.int128 Modified Files: CMakeLists.txt MonetDB.spec common/utils/matomic.h debian/rules gdk/gdk_posix.c gdk/gdk_system.c gdk/gdk_system.h monetdb5/mal/mal.h monetdb5/mal/mal_client.c monetdb5/mal/mal_client.h monetdb5/mal/mal_debugger.c monetdb5/mal/mal_instruction.h monetdb5/mal/mal_namespace.h monetdb5/mal/mal_parser.c monetdb5/mal/mal_resolve.c monetdb5/mal/mal_scenario.c monetdb5/mal/mal_scenario.h monetdb5/mal/mal_stack.h monetdb5/mal/mal_type.h monetdb5/optimizer/opt_wlc.c monetdb_config.h.in sql/test/BugTracker-2009/Tests/count_bug.SF-2604583.sql sql/test/BugTracker-2009/Tests/count_bug.SF-2604583.stable.out sql/test/BugTracker-2011/Tests/crash_on_alias.Bug-2798.sql sql/test/BugTracker-2011/Tests/crash_on_alias.Bug-2798.stable.out sql/test/BugTracker-2015/Tests/crash_timestamp_convert.Bug-3816.stable.err.Windows sql/test/SQLite_regress/sqllogictest/Tests/select1.test.stable.out sql/test/SQLite_regress/sqllogictest/Tests/select2.test.stable.out sql/test/SQLite_regress/sqllogictest/Tests/select3.test.timeout Branch: cmake-monetdblite Log Message:
Merge with cmake-fun. diffs (truncated from 13321 to 300 lines): diff --git a/CMakeLists.txt b/CMakeLists.txt --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -384,8 +384,6 @@ else() set(ICONV_LIBRARIES "" CACHE INTERNAL "iconv libraries to link") endif() -check_include_file("pthread.h" HAVE_PTHREAD_H) # Distinguish between posix thread and win32 thread libraries - # Password hash algorithm set(PASSWORD_BACKEND "SHA512" CACHE STRING "Password hash algorithm, one of MD5, SHA1, RIPEMD160, SHA224, SHA256, SHA384, SHA512, defaults to SHA512") if(${PASSWORD_BACKEND} MATCHES "^MD5|SHA1|RIPEMD160|SHA224|SHA256|SHA384|SHA512$") diff --git a/MonetDB.spec b/MonetDB.spec --- a/MonetDB.spec +++ b/MonetDB.spec @@ -955,7 +955,6 @@ fi export CFLAGS %{configure} \ --enable-assert=no \ - --enable-console=yes \ --enable-debug=no \ --enable-developer=no \ --enable-embedded=no \ diff --git a/common/utils/matomic.h b/common/utils/matomic.h --- a/common/utils/matomic.h +++ b/common/utils/matomic.h @@ -277,8 +277,6 @@ typedef volatile char ATOMIC_FLAG; #else -#include <pthread.h> //required for pthread_mutex_t - /* emulate using mutexes */ #include <pthread.h> /* required for pthread_mutex_t */ diff --git a/debian/rules b/debian/rules --- a/debian/rules +++ b/debian/rules @@ -14,7 +14,6 @@ DH_VERBOSE=1 override_dh_auto_configure: dh_auto_configure -- \ --enable-assert=no \ - --enable-console=yes \ --enable-debug=no \ --enable-developer=no \ --enable-embedded=no \ diff --git a/gdk/gdk_posix.c b/gdk/gdk_posix.c --- a/gdk/gdk_posix.c +++ b/gdk/gdk_posix.c @@ -19,7 +19,6 @@ #include "gdk.h" /* includes gdk_posix.h */ #include "gdk_private.h" #include "mutils.h" -#include <sys/types.h> #include <fcntl.h> #ifdef __MACH__ # include <mach/task.h> @@ -221,13 +220,11 @@ * this may be around 2000 BATs easily. */ -#ifdef HAVE_PTHREAD_H +#ifndef NATIVE_WIN32 + #include <sched.h> #include <pthread.h> #include <semaphore.h> -#endif - -#ifndef NATIVE_WIN32 void MT_init_posix(void) diff --git a/gdk/gdk_system.c b/gdk/gdk_system.c --- a/gdk/gdk_system.c +++ b/gdk/gdk_system.c @@ -160,7 +160,7 @@ GDKlockstatistics(int what) #endif /* LOCK_STATS */ -#if !defined(HAVE_PTHREAD_H) && defined(WIN32) +#ifdef WIN32 static struct winthread { struct winthread *next; HANDLE hdl; @@ -466,7 +466,7 @@ MT_kill_thread(MT_Id t) return -1; } -#else /* !defined(HAVE_PTHREAD_H) && defined(_MSC_VER) */ +#else static struct posthread { struct posthread *next; diff --git a/gdk/gdk_system.h b/gdk/gdk_system.h --- a/gdk/gdk_system.h +++ b/gdk/gdk_system.h @@ -80,22 +80,16 @@ #define TEMMASK (1<<10) #define TEMDEBUG if (GDKdebug & TEMMASK) -/* - * @- pthreads Includes and Definitions - */ -#ifdef HAVE_PTHREAD_H -#include <sched.h> -#include <pthread.h> -#include <semaphore.h> -#endif - #ifdef __MACH__ /* dispatch_semaphore_create function */ #include <dispatch/dispatch.h> #endif #ifndef NATIVE_WIN32 -# include <sys/param.h> /* prerequisite of sys/sysctl on OpenBSD */ -# include <sys/sysctl.h> +#include <sched.h> +#include <pthread.h> +#include <semaphore.h> +#include <sys/param.h> /* prerequisite of sys/sysctl on OpenBSD */ +#include <sys/sysctl.h> #endif /* debug and errno integers */ @@ -266,7 +260,7 @@ gdk_export int MT_join_thread(MT_Id t); #ifdef USE_PTHREAD_LOCKS -#if !defined(HAVE_PTHREAD_H) && defined(WIN32) +#ifdef WIN32 typedef struct MT_Lock { HANDLE lock; char name[16]; @@ -557,7 +551,7 @@ typedef struct MT_RWLock { /* * @- MT Semaphore API */ -#if !defined(HAVE_PTHREAD_H) && defined(WIN32) +#ifdef WIN32 typedef struct { HANDLE sema; diff --git a/monetdb5/mal/mal.h b/monetdb5/mal/mal.h --- a/monetdb5/mal/mal.h +++ b/monetdb5/mal/mal.h @@ -32,7 +32,6 @@ # include <sys/times.h> #endif -#include <setjmp.h> /* * MonetDB Calling Options * The number of invocation arguments is kept to a minimum. @@ -108,8 +107,6 @@ mal_export MT_Lock mal_oltpLock ; #define VARARGS 1 /* deal with variable arguments */ #define VARRETS 2 -#define SERVERSHUTDOWNDELAY 5 /* seconds */ - typedef int malType; typedef str (*MALfcn) (); @@ -204,7 +201,6 @@ typedef struct MALBLK { #define STACKINCR 128 #define MAXGLOBALS (4 * STACKINCR) -#define MAXSHARES 8 typedef int (*DFhook) (void *, void *, void *, void *); @@ -215,8 +211,6 @@ typedef struct MALSTK { int stkdepth; /* to protect against runtime stack overflow */ int calldepth; /* to protect against runtime stack overflow */ short keepAlive; /* do not garbage collect when set */ - short garbageCollect; /* stack needs garbage collection */ - lng tmpspace; /* amount of temporary space produced */ /* * Parallel processing is mostly driven by dataflow, but within this context * there may be different schemes to take instructions into execution. diff --git a/monetdb5/mal/mal_client.c b/monetdb5/mal/mal_client.c --- a/monetdb5/mal/mal_client.c +++ b/monetdb5/mal/mal_client.c @@ -227,7 +227,6 @@ MCinitClientRecord(Client c, oid user, b c->listing = 0; c->fdout = fout ? fout : GDKstdout; - c->mdb = 0; c->curprg = c->backup = 0; c->glb = 0; @@ -262,7 +261,6 @@ MCinitClientRecord(Client c, oid user, b c->promptlength = strlen(prompt); c->actions = 0; - c->exception_buf_initialized = 0; c->error_row = c->error_fld = c->error_msg = c->error_input = NULL; c->wlc_kind = 0; c->wlc = NULL; diff --git a/monetdb5/mal/mal_client.h b/monetdb5/mal/mal_client.h --- a/monetdb5/mal/mal_client.h +++ b/monetdb5/mal/mal_client.h @@ -23,8 +23,6 @@ enum clientmode { BLOCKCLIENT }; -#define PROCESSTIMEOUT 2 /* seconds */ - /* * The prompt structure is designed to simplify recognition of the * language framework for interaction. For access through an API we @@ -121,7 +119,6 @@ typedef struct CLIENT { * debugger features. */ int debug; - void *mdb; /* context upon suspend */ enum clientmode mode; /* FREECLIENT..BLOCKED */ /* * Client records are organized into a two-level dependency tree, @@ -151,9 +148,6 @@ typedef struct CLIENT { */ int actions; - jmp_buf exception_buf; - int exception_buf_initialized; - /* * Here are pointers to scenario backends contexts. For the time * being just SQL. We need a pointer for each of them, since they diff --git a/monetdb5/mal/mal_debugger.c b/monetdb5/mal/mal_debugger.c --- a/monetdb5/mal/mal_debugger.c +++ b/monetdb5/mal/mal_debugger.c @@ -1211,7 +1211,6 @@ mdbStep(Client cntxt, MalBlkPtr mb, MalS state.stk = stk; state.p = getInstrPtr(mb, pc); state.pc = pc; - cntxt->mdb = &state; mnstr_printf(cntxt->fdout, "#Process %d put to sleep\n", (int) (cntxt - mal_clients)); cntxt->itrace = 'W'; mdbTrap(cntxt, mb, stk, state.p); diff --git a/monetdb5/mal/mal_instruction.h b/monetdb5/mal/mal_instruction.h --- a/monetdb5/mal/mal_instruction.h +++ b/monetdb5/mal/mal_instruction.h @@ -126,7 +126,6 @@ #define getArgGDKType(M,P,I) getVarGDKType((M),(P)->argv[I]) #define getGDKType(T) ( T <= TYPE_str ? T : (T == TYPE_any ? TYPE_void : findGDKtype(T))) - mal_export void addMalException(MalBlkPtr mb, str msg); mal_export void mal_instruction_reset(void); mal_export InstrPtr newInstruction(MalBlkPtr mb, str modnme, str fcnnme); diff --git a/monetdb5/mal/mal_namespace.h b/monetdb5/mal/mal_namespace.h --- a/monetdb5/mal/mal_namespace.h +++ b/monetdb5/mal/mal_namespace.h @@ -16,6 +16,4 @@ mal_export str getName(const char *nme); mal_export str getNameLen(const char *nme, size_t len); mal_export void delName(const char *nme, size_t len); -#define MAXIDENTLEN 1024 - #endif /* _MAL_NAMESPACE_H */ diff --git a/monetdb5/mal/mal_parser.c b/monetdb5/mal/mal_parser.c --- a/monetdb5/mal/mal_parser.c +++ b/monetdb5/mal/mal_parser.c @@ -650,7 +650,7 @@ handleInts: * It would make more sense for tpe parameter to be an int, but simpleTypeId returns a size_t */ static int -typeAlias(Client cntxt, size_t tpe) +typeAlias(Client cntxt, int tpe) { int t; @@ -700,7 +700,7 @@ parseTypeId(Client cntxt, int defaultTyp { int i = TYPE_any, kt = 0; char *s = CURRENT(cntxt); - size_t tt; + int tt; if (s[0] == ':' && s[1] == 'b' && s[2] == 'a' && s[3] == 't' && s[4] == '[') { /* parse :bat[:oid,:type] */ diff --git a/monetdb5/mal/mal_resolve.c b/monetdb5/mal/mal_resolve.c --- a/monetdb5/mal/mal_resolve.c +++ b/monetdb5/mal/mal_resolve.c @@ -27,7 +27,6 @@ static int updateTypeMap(int formal, int static int typeKind(MalBlkPtr mb, InstrPtr p, int i); /* #define DEBUG_MAL_RESOLVE*/ -#define MAXMALARG 256 /* * We found the proper function. Copy some properties. In particular, diff --git a/monetdb5/mal/mal_scenario.c b/monetdb5/mal/mal_scenario.c --- a/monetdb5/mal/mal_scenario.c +++ b/monetdb5/mal/mal_scenario.c @@ -107,35 +107,35 @@ static struct SCENARIO scenarioRec[MAXSC 0, 0, /* implicit */ "MALinitClient", (MALfcn) &MALinitClient, "MALexitClient", (MALfcn) &MALexitClient, _______________________________________________ checkin-list mailing list checkin-list@monetdb.org https://www.monetdb.org/mailman/listinfo/checkin-list