Changeset: bb244ff64710 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=bb244ff64710
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
clients/mapiclient/ReadlineTools.c
clients/mapiclient/dotmonetdb.c
common/options/monet_options.c
common/stream/stream.c
gdk/gdk.h
gdk/gdk_atoms.c
gdk/gdk_bat.c
gdk/gdk_bbp.c
gdk/gdk_bbp.h
gdk/gdk_hash.c
gdk/gdk_imprints.c
gdk/gdk_logger.c
gdk/gdk_orderidx.c
gdk/gdk_private.h
gdk/gdk_storage.c
gdk/gdk_system.c
gdk/gdk_system.h
gdk/gdk_utils.c
monetdb5/ChangeLog.Apr2019
monetdb5/extras/rapi/rapi.c
monetdb5/mal/mal_client.c
monetdb5/mal/mal_client.h
monetdb5/mal/mal_dataflow.c
monetdb5/mal/mal_exception.c
monetdb5/mal/mal_linker.c
monetdb5/mal/mal_profiler.c
monetdb5/modules/atoms/blob.c
monetdb5/modules/kernel/Tests/status.malC
monetdb5/modules/kernel/status.c
monetdb5/modules/kernel/status.mal
monetdb5/modules/mal/bbp.c
monetdb5/modules/mal/mal_mapi.c
monetdb5/modules/mal/querylog.c
monetdb5/modules/mal/remote.mal
monetdb5/modules/mal/tokenizer.c
monetdb5/modules/mal/wlc.c
monetdb5/optimizer/opt_querylog.c
monetdb5/optimizer/optimizer.mal
monetdb5/tools/Tests/mserver5--help.stable.err
monetdb5/tools/Tests/mserver5--help.stable.err.Windows
sql/backends/monet5/UDF/pyapi/pyapi.c
sql/backends/monet5/vaults/bam/bam_loader.c
sql/backends/monet5/wlr.c
sql/server/sql_mvc.c
sql/test/BugTracker-2016/Tests/convert-function-test.Bug-3460.stable.out
sql/test/BugTracker-2016/Tests/convert-function-test.Bug-3460.stable.out.int128
sql/test/Skyserver/Skyserver_import.sql
sql/test/orderidx/Tests/imprints_all_types.stable.out
sql/test/orderidx/Tests/oidx_all_types.stable.out
tools/mserver/mserver5.1.in
tools/mserver/mserver5.c
tools/mserver/shutdowntest.c
Branch: in-value-list
Log Message:
Merge with default.
diffs (truncated from 4004 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
@@ -11890,9 +11890,9 @@ Ready.
[ "sqlcatalog", "revoke_function", "pattern
sqlcatalog.revoke_function(sname:str, fcnid:int, grantee:str, privs:int,
grant:int, grantor:int):void ", "SQLrevoke_function;", "Catalog
operation revoke_function" ]
[ "sqlcatalog", "revoke_roles", "pattern
sqlcatalog.revoke_roles(sname:str, auth:str, grantor:int, admin:int):void ",
"SQLrevoke_roles;", "Catalog operation revoke_roles" ]
[ "status", "batStatistics", "command status.batStatistics()
(X_0:bat[:str], X_1:bat[:str]) ", "SYSgdkEnv;", "Show distribution of
bats by kind" ]
-[ "status", "cpuStatistics", "command status.cpuStatistics()
(X_0:bat[:str], X_1:bat[:int]) ", "SYScpuStatistics;", "Global cpu
usage information" ]
+[ "status", "cpuStatistics", "command status.cpuStatistics()
(X_0:bat[:str], X_1:bat[:lng]) ", "SYScpuStatistics;", "Global cpu
usage information" ]
[ "status", "getThreads", "command status.getThreads() (X_0:bat[:int],
X_1:bat[:str]) ", "SYSgdkThread;", "Produce overview of active threads"
]
-[ "status", "ioStatistics", "command status.ioStatistics() (X_0:bat[:str],
X_1:bat[:int]) ", "SYSioStatistics;", "Global IO activity
information" ]
+[ "status", "ioStatistics", "command status.ioStatistics() (X_0:bat[:str],
X_1:bat[:lng]) ", "SYSioStatistics;", "Global IO activity
information" ]
[ "status", "memStatistics", "command status.memStatistics()
(X_0:bat[:str], X_1:bat[:lng]) ", "SYSmemStatistics;", "Global memory
usage information" ]
[ "status", "memUsage", "command status.memUsage(minsize:lng)
(X_0:bat[:str], X_1:bat[:lng]) ", "SYSmem_usage;", "Get a split-up of
how much memory blocks are in use" ]
[ "status", "mem_cursize", "command status.mem_cursize():lng ",
"SYSgetmem_cursize;", "The amount of physical swapspace in KB that is
currently in use" ]
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
@@ -16317,9 +16317,9 @@ Ready.
[ "sqlcatalog", "revoke_function", "pattern
sqlcatalog.revoke_function(sname:str, fcnid:int, grantee:str, privs:int,
grant:int, grantor:int):void ", "SQLrevoke_function;", "Catalog
operation revoke_function" ]
[ "sqlcatalog", "revoke_roles", "pattern
sqlcatalog.revoke_roles(sname:str, auth:str, grantor:int, admin:int):void ",
"SQLrevoke_roles;", "Catalog operation revoke_roles" ]
[ "status", "batStatistics", "command status.batStatistics()
(X_0:bat[:str], X_1:bat[:str]) ", "SYSgdkEnv;", "Show distribution of
bats by kind" ]
-[ "status", "cpuStatistics", "command status.cpuStatistics()
(X_0:bat[:str], X_1:bat[:int]) ", "SYScpuStatistics;", "Global cpu
usage information" ]
+[ "status", "cpuStatistics", "command status.cpuStatistics()
(X_0:bat[:str], X_1:bat[:lng]) ", "SYScpuStatistics;", "Global cpu
usage information" ]
[ "status", "getThreads", "command status.getThreads() (X_0:bat[:int],
X_1:bat[:str]) ", "SYSgdkThread;", "Produce overview of active threads"
]
-[ "status", "ioStatistics", "command status.ioStatistics() (X_0:bat[:str],
X_1:bat[:int]) ", "SYSioStatistics;", "Global IO activity
information" ]
+[ "status", "ioStatistics", "command status.ioStatistics() (X_0:bat[:str],
X_1:bat[:lng]) ", "SYSioStatistics;", "Global IO activity
information" ]
[ "status", "memStatistics", "command status.memStatistics()
(X_0:bat[:str], X_1:bat[:lng]) ", "SYSmemStatistics;", "Global memory
usage information" ]
[ "status", "memUsage", "command status.memUsage(minsize:lng)
(X_0:bat[:str], X_1:bat[:lng]) ", "SYSmem_usage;", "Get a split-up of
how much memory blocks are in use" ]
[ "status", "mem_cursize", "command status.mem_cursize():lng ",
"SYSgetmem_cursize;", "The amount of physical swapspace in KB that is
currently in use" ]
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
@@ -186,12 +186,10 @@ gdk_return BBPaddfarm(const char *dirnam
void BBPclear(bat bid);
BAT *BBPdescriptor(bat b);
int BBPfix(bat b);
-int BBPin;
bat BBPindex(const char *nme);
void BBPkeepref(bat i);
bat BBPlimit;
void BBPlock(void);
-int BBPout;
BAT *BBPquickdesc(bat b, bool delaccess);
int BBPreclaim(BAT *b);
int BBPrelease(bat b);
@@ -277,8 +275,10 @@ void GDKregister(MT_Id pid);
gdk_return GDKreleasemmap(void *ptr, size_t size, size_t id);
gdk_return GDKreleasesem(int sem_id);
void GDKreset(int status);
+void GDKsetdebug(int debug);
gdk_return GDKsetenv(const char *name, const char *value);
void GDKsetmallocsuccesscount(lng count);
+void GDKsetverbose(int verbosity);
ssize_t GDKstrFromStr(unsigned char *restrict dst, const unsigned char
*restrict src, ssize_t len);
str GDKstrdup(const char *s) __attribute__((__warn_unused_result__));
str GDKstrndup(const char *s, size_t n)
__attribute__((__warn_unused_result__));
@@ -286,6 +286,7 @@ void GDKsyserror(_In_z_ _Printf_format_s
size_t GDKuniqueid(size_t offset);
gdk_return GDKupgradevarheap(BAT *b, var_t v, bool copyall, bool mayshare)
__attribute__((__warn_unused_result__));
lng GDKusec(void);
+int GDKverbose;
const char *GDKversion(void);
size_t GDKvm_cursize(void);
void *GDKzalloc(size_t size) __attribute__((__malloc__))
__attribute__((__alloc_size__(1))) __attribute__((__warn_unused_result__));
@@ -301,7 +302,7 @@ size_t HEAPvmsize(Heap *h);
void IMPSdestroy(BAT *b);
lng IMPSimprintsize(BAT *b);
int MT_check_nr_cores(void);
-int MT_create_thread(MT_Id *t, void (*function)(void *), void *arg, enum
MT_thr_detach d);
+int MT_create_thread(MT_Id *t, void (*function)(void *), void *arg, enum
MT_thr_detach d, const char *threadname);
void MT_exiting_thread(void);
MT_Id MT_getpid(void);
size_t MT_getrss(void);
@@ -312,6 +313,9 @@ void *MT_mmap(const char *path, int mode
int MT_munmap(void *p, size_t len);
bool MT_path_absolute(const char *path);
void MT_sleep_ms(unsigned int ms);
+bool MT_thread_init(void);
+const char *MT_thread_name(void);
+void MT_thread_setname(const char *name);
void OIDXdestroy(BAT *b);
ssize_t OIDfromStr(const char *src, size_t *len, oid **dst, bool external);
ssize_t OIDtoStr(str *dst, size_t *len, const oid *src, bool external);
diff --git a/clients/mapiclient/ReadlineTools.c
b/clients/mapiclient/ReadlineTools.c
--- a/clients/mapiclient/ReadlineTools.c
+++ b/clients/mapiclient/ReadlineTools.c
@@ -321,18 +321,25 @@ init_readline(Mapi mid, char *lang, int
}
if (save_history) {
+ int len;
#ifndef NATIVE_WIN32
if (getenv("HOME") != NULL) {
- snprintf(_history_file, FILENAME_MAX,
+ len = snprintf(_history_file, FILENAME_MAX,
"%s/.mapiclient_history_%s",
getenv("HOME"), language);
- _save_history = 1;
+ if (len == -1 || len >= FILENAME_MAX)
+ fprintf(stderr, "Warning: history filename path
is too large\n");
+ else
+ _save_history = 1;
}
#else
- snprintf(_history_file, FILENAME_MAX,
+ len = snprintf(_history_file, FILENAME_MAX,
"%s%c_mapiclient_history_%s",
mo_find_option(NULL, 0, "prefix"), DIR_SEP, language);
- _save_history = 1;
+ if (len == -1 || len >= FILENAME_MAX)
+ fprintf(stderr, "Warning: history filename path is too
large\n");
+ else
+ _save_history = 1;
#endif
if (_save_history) {
FILE *f;
diff --git a/clients/mapiclient/dotmonetdb.c b/clients/mapiclient/dotmonetdb.c
--- a/clients/mapiclient/dotmonetdb.c
+++ b/clients/mapiclient/dotmonetdb.c
@@ -15,18 +15,22 @@ parse_dotmonetdb(char **user, char **pas
{
char *cfile;
FILE *config = NULL;
- char buf[1024];
+ char buf[FILENAME_MAX];
if ((cfile = getenv("DOTMONETDBFILE")) == NULL) {
/* no environment variable: use a default */
if ((config = fopen(".monetdb", "r")) == NULL) {
if ((cfile = getenv("HOME")) != NULL) {
- snprintf(buf, sizeof(buf), "%s%c.monetdb",
cfile, DIR_SEP);
- config = fopen(buf, "r");
- if (config)
- cfile = strdup(buf);
- else
+ int len = snprintf(buf, sizeof(buf),
"%s%c.monetdb", cfile, DIR_SEP);
+ if (len == -1 || len >= FILENAME_MAX) {
cfile = NULL;
+ } else {
+ config = fopen(buf, "r");
+ if (config)
+ cfile = strdup(buf);
+ else
+ cfile = NULL;
+ }
}
} else {
cfile = strdup(".monetdb");
diff --git a/common/options/monet_options.c b/common/options/monet_options.c
--- a/common/options/monet_options.c
+++ b/common/options/monet_options.c
@@ -219,7 +219,7 @@ mo_builtin_settings(opt **Set)
if (Set == NULL)
return 0;
-#define N_OPTIONS 9 /*MUST MATCH # OPTIONS BELOW */
+#define N_OPTIONS 8 /*MUST MATCH # OPTIONS BELOW */
set = malloc(sizeof(opt) * N_OPTIONS);
if (set == NULL)
return 0;
@@ -230,10 +230,6 @@ mo_builtin_settings(opt **Set)
"dbfarm" DIR_SEP_STR "demo");
i++;
set[i].kind = opt_builtin;
- set[i].name = strdup("gdk_debug");
- set[i].value = strdup("0");
- i++;
- set[i].kind = opt_builtin;
set[i].name = strdup("monet_prompt");
set[i].value = strdup(">");
i++;
diff --git a/common/stream/stream.c b/common/stream/stream.c
--- a/common/stream/stream.c
+++ b/common/stream/stream.c
@@ -968,9 +968,7 @@ stream_gzread(stream *restrict s, void *
return 0;
size = gzfread(buf, elmsize, cnt, fp);
-#ifdef WIN32
- /* on Windows when in text mode, convert \r\n line
- * endings to \n */
+ /* when in text mode, convert \r\n line endings to \n */
if (!s->binary) {
char *p1, *p2, *pe;
@@ -987,7 +985,6 @@ stream_gzread(stream *restrict s, void *
p1++;
}
}
-#endif
return size == 0 ? -1 : (ssize_t) size;
}
@@ -1190,9 +1187,7 @@ stream_bzread(stream *restrict s, void *
s->errnr = MNSTR_READ_ERROR;
return -1;
}
-#ifdef WIN32
- /* on Windows when in text mode, convert \r\n line endings to
- * \n */
+ /* when in text mode, convert \r\n line endings to \n */
if (!s->binary) {
char *p1, *p2, *pe;
@@ -1209,7 +1204,6 @@ stream_bzread(stream *restrict s, void *
p1++;
}
}
-#endif
return (ssize_t) (size / elmsize);
}
@@ -1432,9 +1426,8 @@ stream_xzread(stream *restrict s, void *
}
}
if (ressize) {
-#ifdef WIN32
- /* on Windows when in text mode, convert \r\n line
- * endings to \n */
+ /* when in text mode, convert \r\n line endings to
+ * \n */
if (!s->binary) {
char *p1, *p2, *pe;
@@ -1451,7 +1444,6 @@ stream_xzread(stream *restrict s, void *
p1++;
}
}
-#endif
return (ssize_t) (ressize / elmsize);
}
return 0;
@@ -1719,8 +1711,7 @@ stream_lz4read(stream *restrict s, void
total_read += remaining_to_decompress;
}
-#ifdef WIN32
- /* on Windows when in text mode, convert \r\n line endings to \n */
+ /* when in text mode, convert \r\n line endings to \n */
if (!s->binary) {
char *p1, *p2, *pe;
@@ -1737,7 +1728,6 @@ stream_lz4read(stream *restrict s, void
p1++;
}
}
-#endif
return (ssize_t) (total_read / elmsize);
}
diff --git a/gdk/gdk.h b/gdk/gdk.h
--- a/gdk/gdk.h
+++ b/gdk/gdk.h
@@ -774,7 +774,8 @@ typedef struct {
#define GDKLIBRARY_TALIGN 061036U /* talign field in BBP.dir */
#define GDKLIBRARY_NIL_NAN 061037U /* flt/dbl NIL not represented by NaN */
-#define GDKLIBRARY 061040U
+#define GDKLIBRARY_BLOB_SORT 061040U /* blob compare changed */
+#define GDKLIBRARY 061041U
typedef struct BAT {
/* static bat properties */
diff --git a/gdk/gdk_atoms.c b/gdk/gdk_atoms.c
--- a/gdk/gdk_atoms.c
+++ b/gdk/gdk_atoms.c
@@ -1400,6 +1400,7 @@ ATOMunknown_find(const char *nme)
str
ATOMunknown_name(int i)
{
+ assert(i < 0);
assert(unknown[-i]);
return unknown[-i];
}
diff --git a/gdk/gdk_bat.c b/gdk/gdk_bat.c
--- a/gdk/gdk_bat.c
+++ b/gdk/gdk_bat.c
@@ -929,7 +929,12 @@ setcolprops(BAT *b, const void *x)
if (b->ttype == TYPE_oid) {
b->tseqbase = * (const oid *) x;
}
+ if (!isnil && ATOMlinear(b->ttype)) {
+ BATsetprop(b, GDK_MAX_VALUE, b->ttype, x);
+ BATsetprop(b, GDK_MIN_VALUE, b->ttype, x);
+ }
}
+ return;
} else if (b->ttype == TYPE_void) {
/* not the first value in a VOID column: we keep the
* seqbase, and x is not used, so only some properties
@@ -950,7 +955,10 @@ setcolprops(BAT *b, const void *x)
b->tnil = true;
b->tnonil = false;
}
- } else {
+ return;
+ } else if (ATOMlinear(b->ttype)) {
+ PROPrec *prop;
+
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list