Changeset: 77ce9db70cd5 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=77ce9db70cd5
Added Files:
sql/test/Tests/sysqueue.sql
sql/test/Tests/sysqueue.stable.err
sql/test/Tests/sysqueue.stable.out
Removed Files:
sql/test/BugTracker-2020/Tests/sysqueue.sql
sql/test/BugTracker-2020/Tests/sysqueue.stable.err
sql/test/BugTracker-2020/Tests/sysqueue.stable.out
Modified Files:
clients/Tests/MAL-signatures.stable.out
clients/Tests/MAL-signatures.stable.out.int128
clients/Tests/exports.stable.out
clients/mapilib/mapi.c
gdk/gdk_aggr.c
gdk/gdk_analytic_func.c
gdk/gdk_select.c
monetdb5/modules/kernel/bat5.c
monetdb5/optimizer/opt_prelude.c
monetdb5/optimizer/opt_prelude.h
monetdb5/optimizer/opt_support.c
sql/backends/monet5/UDF/pyapi3/connection3.c
sql/backends/monet5/UDF/pyapi3/emit3.c
sql/backends/monet5/sql.c
sql/backends/monet5/sql.h
sql/backends/monet5/sql.mal
sql/backends/monet5/sql_statement.c
sql/server/rel_optimizer.c
sql/server/rel_psm.c
sql/server/rel_select.c
sql/server/rel_updates.c
sql/storage/store.c
sql/test/BugTracker-2020/Tests/All
sql/test/Tests/All
sql/test/mergetables/Tests/sqlsmith-exists2.sql
sql/test/mergetables/Tests/sqlsmith-exists2.stable.out
sql/test/miscellaneous/Tests/declared_tables.sql
sql/test/miscellaneous/Tests/declared_tables.stable.out
sql/test/miscellaneous/Tests/groupby_error.sql
sql/test/miscellaneous/Tests/groupby_error.stable.out
sql/test/subquery/Tests/subquery5.sql
sql/test/subquery/Tests/subquery5.stable.err
sql/test/subquery/Tests/subquery5.stable.out
Branch: unlock
Log Message:
merged with default
diffs (truncated from 1901 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
@@ -14077,7 +14077,7 @@ stdout of test 'MAL-signatures` in direc
[ "sql", "dec_round", "command sql.dec_round(v:int, r:int):int ",
"int_dec_round_wrap;", "round off the value v to nearests multiple of r"
]
[ "sql", "dec_round", "command sql.dec_round(v:lng, r:lng):lng ",
"lng_dec_round_wrap;", "round off the value v to nearests multiple of r"
]
[ "sql", "dec_round", "command sql.dec_round(v:sht, r:sht):sht ",
"sht_dec_round_wrap;", "round off the value v to nearests multiple of r"
]
-[ "sql", "delete", "unsafe pattern sql.delete(mvc:int, sname:str,
tname:str, b:any):int ", "mvc_delete_wrap;", "Delete a row from a table.
Returns sequence number for order dependece." ]
+[ "sql", "delete", "unsafe pattern sql.delete(mvc:int, sname:str,
tname:str, b:any):int ", "mvc_delete_wrap;", "Delete a row from a table.
Returns sequence number for order dependence." ]
[ "sql", "delta", "command sql.delta(col:bat[:any_3],
uid:bat[:oid], uval:bat[:any_3]):bat[:any_3] ", "DELTAbat2;", "Return
column bat with delta's applied." ]
[ "sql", "delta", "command sql.delta(col:bat[:any_3],
uid:bat[:oid], uval:bat[:any_3], ins:bat[:any_3]):bat[:any_3] ",
"DELTAbat;", "Return column bat with delta's applied." ]
[ "sql", "deltas", "pattern sql.deltas(schema:str) (ids:bat[:int],
cleared:bat[:bit], readonly:bat[:lng], inserted:bat[:lng], updated:bat[:lng],
deleted:bat[:lng], tr_level:bat[:int]) ", "mvc_delta_values;", "Return the
delta values sizes of all columns of the schema's tables, plus the current
transaction level" ]
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
@@ -19534,7 +19534,7 @@ stdout of test 'MAL-signatures` in direc
[ "sql", "dec_round", "command sql.dec_round(v:int, r:int):int ",
"int_dec_round_wrap;", "round off the value v to nearests multiple of r"
]
[ "sql", "dec_round", "command sql.dec_round(v:lng, r:lng):lng ",
"lng_dec_round_wrap;", "round off the value v to nearests multiple of r"
]
[ "sql", "dec_round", "command sql.dec_round(v:sht, r:sht):sht ",
"sht_dec_round_wrap;", "round off the value v to nearests multiple of r"
]
-[ "sql", "delete", "unsafe pattern sql.delete(mvc:int, sname:str,
tname:str, b:any):int ", "mvc_delete_wrap;", "Delete a row from a table.
Returns sequence number for order dependece." ]
+[ "sql", "delete", "unsafe pattern sql.delete(mvc:int, sname:str,
tname:str, b:any):int ", "mvc_delete_wrap;", "Delete a row from a table.
Returns sequence number for order dependence." ]
[ "sql", "delta", "command sql.delta(col:bat[:any_3],
uid:bat[:oid], uval:bat[:any_3]):bat[:any_3] ", "DELTAbat2;", "Return
column bat with delta's applied." ]
[ "sql", "delta", "command sql.delta(col:bat[:any_3],
uid:bat[:oid], uval:bat[:any_3], ins:bat[:any_3]):bat[:any_3] ",
"DELTAbat;", "Return column bat with delta's applied." ]
[ "sql", "deltas", "pattern sql.deltas(schema:str) (ids:bat[:int],
cleared:bat[:bit], readonly:bat[:lng], inserted:bat[:lng], updated:bat[:lng],
deleted:bat[:lng], tr_level:bat[:int]) ", "mvc_delta_values;", "Return the
delta values sizes of all columns of the schema's tables, plus the current
transaction level" ]
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
@@ -2044,6 +2044,7 @@ int bstream_destroy_wrap(Bstream *BS);
str bstream_destroy_wrapwrap(void *ret, Bstream *BS);
int bstream_read_wrap(int *res, Bstream *BS, int *size);
str bstream_read_wrapwrap(int *res, Bstream *BS, int *size);
+str bulk_rotate_xor_hashRef;
str calcRef;
str callMAL(Client cntxt, MalBlkPtr mb, MalStkPtr *glb, ValPtr argv[], char
debug);
str callString(Client c, str s, int listing);
@@ -2215,6 +2216,7 @@ malType getType(MalBlkPtr mb, str nme);
str getTypeIdentifier(malType tpe);
str getTypeName(malType tpe);
lng getUserTime(void);
+str getVariableRef;
lng getVolume(MalStkPtr stk, InstrPtr pci, int rd);
int getprofilerlimit(void);
Module globalModule(str nme);
@@ -2225,6 +2227,7 @@ str groupRef;
str group_concatRef;
str groupbyRef;
str groupdoneRef;
+str growRef;
int hasCommonResults(InstrPtr p, InstrPtr q);
int hasSameArguments(MalBlkPtr mb, InstrPtr p, InstrPtr q);
int hasSameSignature(MalBlkPtr mb, InstrPtr p, InstrPtr q);
@@ -2244,7 +2247,6 @@ void initParser(void);
void initProfiler(void);
str initQlog(void);
int inlineMALblock(MalBlkPtr mb, int pc, MalBlkPtr mc);
-str inplaceRef;
void insertSymbol(Module scope, Symbol prg);
str instruction2str(MalBlkPtr mb, MalStkPtr stl, InstrPtr p, int hidden);
str intRef;
diff --git a/clients/mapilib/mapi.c b/clients/mapilib/mapi.c
--- a/clients/mapilib/mapi.c
+++ b/clients/mapilib/mapi.c
@@ -1000,13 +1000,13 @@ static void mapi_store_bind(struct MapiR
static ATOMIC_FLAG mapi_initialized = ATOMIC_FLAG_INIT;
-#define check_stream(mid,s,msg,f,e) \
+#define check_stream(mid, s, msg, e) \
do { \
if ((s) == NULL || mnstr_errnr(s)) { \
- mapi_log_record(mid,msg); \
- mapi_log_record(mid,f); \
+ mapi_log_record(mid, msg); \
+ mapi_log_record(mid, __func__); \
close_connection(mid); \
- mapi_setError((mid), (msg), (f), MTIMEOUT); \
+ mapi_setError((mid), (msg), __func__, MTIMEOUT); \
return (e); \
} \
} while (0)
@@ -1420,7 +1420,7 @@ mapi_log(Mapi mid, const char *nme)
if (mid->tracelog)
close_stream(mid->tracelog);
mid->tracelog = NULL;
- return mapi_setError(mid, "Could not create log file",
"mapi_log", MERROR);
+ return mapi_setError(mid, "Could not create log file",
__func__, MERROR);
}
return MOK;
}
@@ -1529,7 +1529,7 @@ close_result(MapiHdl hdl)
if (mnstr_printf(mid->to, "%s", msg) < 0 ||
mnstr_flush(mid->to)) {
close_connection(mid);
- mapi_setError(mid,
mnstr_error(mid->to), "mapi_close_handle", MTIMEOUT);
+ mapi_setError(mid,
mnstr_error(mid->to), __func__, MTIMEOUT);
break;
}
read_into_cache(hdl, 0);
@@ -1547,7 +1547,7 @@ close_result(MapiHdl hdl)
if (mnstr_printf(mid->to, "%s", msg) < 0 ||
mnstr_flush(mid->to)) {
close_connection(mid);
- mapi_setError(mid,
mnstr_error(mid->to), "mapi_close_handle", MTIMEOUT);
+ mapi_setError(mid,
mnstr_error(mid->to), __func__, MTIMEOUT);
} else
read_into_cache(hdl, 0);
}
@@ -1725,7 +1725,7 @@ mapi_new_handle(Mapi mid)
hdl = malloc(sizeof(*hdl));
if (hdl == NULL) {
- mapi_setError(mid, "Memory allocation failure",
"mapi_new_handle", MERROR);
+ mapi_setError(mid, "Memory allocation failure", __func__,
MERROR);
return NULL;
}
*hdl = (struct MapiStatement) {
@@ -1759,7 +1759,7 @@ finish_handle(MapiHdl hdl)
hdl->needmore = false;
mid->active = hdl;
mnstr_flush(mid->to);
- check_stream(mid, mid->to, "write error on stream",
"finish_handle", mid->error);
+ check_stream(mid, mid->to, "write error on stream",
mid->error);
read_into_cache(hdl, 0);
}
for (i = 0; i < hdl->npending_close; i++) {
@@ -1771,7 +1771,7 @@ finish_handle(MapiHdl hdl)
if (mnstr_printf(mid->to, "%s", msg) < 0 ||
mnstr_flush(mid->to)) {
close_connection(mid);
- mapi_setError(mid, mnstr_error(mid->to),
"finish_handle", MTIMEOUT);
+ mapi_setError(mid, mnstr_error(mid->to),
__func__, MTIMEOUT);
break;
}
read_into_cache(hdl, 0);
@@ -1789,7 +1789,7 @@ finish_handle(MapiHdl hdl)
hdl->needmore = false;
mid->active = hdl;
mnstr_flush(mid->to);
- check_stream(mid, mid->to, "write error on stream",
"finish_handle", mid->error);
+ check_stream(mid, mid->to, "write error on stream",
mid->error);
read_into_cache(hdl, 0);
}
}
@@ -1970,19 +1970,19 @@ mapi_mapiuri(const char *url, const char
return NULL;
if (url == NULL) {
- mapi_setError(mid, "url is null", "mapi_mapiuri", MERROR);
+ mapi_setError(mid, "url is null", __func__, MERROR);
return mid;
}
if (user == NULL) {
- mapi_setError(mid, "user is null", "mapi_mapiuri", MERROR);
+ mapi_setError(mid, "user is null", __func__, MERROR);
return mid;
}
if (pass == NULL) {
- mapi_setError(mid, "pass is null", "mapi_mapiuri", MERROR);
+ mapi_setError(mid, "pass is null", __func__, MERROR);
return mid;
}
if (lang == NULL) {
- mapi_setError(mid, "lang is null", "mapi_mapiuri", MERROR);
+ mapi_setError(mid, "lang is null", __func__, MERROR);
return mid;
}
@@ -2002,7 +2002,7 @@ mapi_mapiuri(const char *url, const char
mapi_setError(mid,
"url has unsupported scheme, "
"expecting mapi:monetdb://...",
- "mapi_mapiuri", MERROR);
+ __func__, MERROR);
return mid;
}
if ((uri = strdup(url + sizeof("mapi:monetdb://") - 1)) == NULL) {
@@ -2027,7 +2027,7 @@ mapi_mapiuri(const char *url, const char
if (*p == '[') {
if ((p = strchr(p, ']')) == NULL) {
free(uri);
- mapi_setError(mid, "URI contains an invalid
IPv6 address", "mapi_mapiuri", MERROR);
+ mapi_setError(mid, "URI contains an invalid
IPv6 address", __func__, MERROR);
return mid;
}
}
@@ -2036,7 +2036,7 @@ mapi_mapiuri(const char *url, const char
mapi_setError(mid,
"URI must contain a port number after "
"the hostname",
- "mapi_mapiuri", MERROR);
+ __func__, MERROR);
return mid;
}
*p++ = 0;
@@ -2052,7 +2052,7 @@ mapi_mapiuri(const char *url, const char
free(uri);
mapi_setError(mid,
"URI contains invalid port",
- "mapi_mapiuri", MERROR);
+ __func__, MERROR);
return mid;
}
query = dbname;
@@ -2356,7 +2356,7 @@ mapi_reconnect(Mapi mid)
struct sockaddr *serv = (struct sockaddr *) &userver;
if (strlen(mid->hostname) >= sizeof(userver.sun_path)) {
- return mapi_setError(mid, "path name too long",
"mapi_reconnect", MERROR);
+ return mapi_setError(mid, "path name too long",
__func__, MERROR);
}
if ((s = socket(PF_UNIX, SOCK_STREAM
@@ -2372,7 +2372,7 @@ mapi_reconnect(Mapi mid)
strerror(errno)
#endif
);
- return mapi_setError(mid, errbuf, "mapi_reconnect",
MERROR);
+ return mapi_setError(mid, errbuf, __func__, MERROR);
}
#if !defined(SOCK_CLOEXEC) && defined(HAVE_FCNTL)
(void) fcntl(s, F_SETFD, FD_CLOEXEC);
@@ -2392,7 +2392,7 @@ mapi_reconnect(Mapi mid)
#endif
);
closesocket(s);
- return mapi_setError(mid, errbuf, "mapi_reconnect",
MERROR);
+ return mapi_setError(mid, errbuf, __func__, MERROR);
}
/* send first byte, nothing special to happen */
@@ -2416,7 +2416,7 @@ mapi_reconnect(Mapi mid)
#endif
);
closesocket(s);
- return mapi_setError(mid, errbuf, "mapi_reconnect",
MERROR);
+ return mapi_setError(mid, errbuf, __func__, MERROR);
}
} else
#endif
@@ -2438,7 +2438,7 @@ mapi_reconnect(Mapi mid)
ret = getaddrinfo(mid->hostname, port, &hints, &res);
if (ret) {
snprintf(errbuf, sizeof(errbuf), "getaddrinfo failed:
%s", gai_strerror(ret));
- return mapi_setError(mid, errbuf, "mapi_reconnect",
MERROR);
+ return mapi_setError(mid, errbuf, __func__, MERROR);
}
errbuf[0] = 0;
for (rp = res; rp; rp = rp->ai_next) {
@@ -2472,7 +2472,7 @@ mapi_reconnect(Mapi mid)
snprintf(errbuf, sizeof(errbuf),
"getaddrinfo succeeded but did not
return a result");
}
- return mapi_setError(mid, errbuf, "mapi_reconnect",
MERROR);
+ return mapi_setError(mid, errbuf, __func__, MERROR);
}
#else
struct sockaddr_in server;
@@ -2490,7 +2490,7 @@ mapi_reconnect(Mapi mid)
errno ? strerror(errno) : hstrerror(h_errno)
#endif
);
- return mapi_setError(mid, errbuf, "mapi_reconnect",
MERROR);
+ return mapi_setError(mid, errbuf, __func__, MERROR);
}
server = (struct sockaddr_in) {
.sin_family = hp->h_addrtype,
@@ -2511,7 +2511,7 @@ mapi_reconnect(Mapi mid)
strerror(errno)
#endif
);
- return mapi_setError(mid, errbuf, "mapi_reconnect",
MERROR);
+ return mapi_setError(mid, errbuf, __func__, MERROR);
}
#if !defined(SOCK_CLOEXEC) && defined(HAVE_FCNTL)
(void) fcntl(s, F_SETFD, FD_CLOEXEC);
@@ -2526,7 +2526,7 @@ mapi_reconnect(Mapi mid)
strerror(errno)
#endif
);
- return mapi_setError(mid, errbuf, "mapi_reconnect",
MERROR);
+ return mapi_setError(mid, errbuf, __func__, MERROR);
}
#endif
/* compare our own address with that of our peer and
@@ -2545,7 +2545,7 @@ mapi_reconnect(Mapi mid)
myaddr.i.sin_port == praddr.i.sin_port) {
closesocket(s);
return mapi_setError(mid, "connected to self",
- "mapi_reconnect", MERROR);
+ __func__, MERROR);
}
}
@@ -2553,17 +2553,17 @@ mapi_reconnect(Mapi mid)
mapi_log_record(mid, "Mapi client write");
mid->from = socket_rstream(s, "Mapi client read");
mapi_log_record(mid, "Mapi client read");
- check_stream(mid, mid->to, "Cannot open socket for writing",
"mapi_reconnect", mid->error);
- check_stream(mid, mid->from, "Cannot open socket for reading",
"mapi_reconnect", mid->error);
+ check_stream(mid, mid->to, "Cannot open socket for writing",
mid->error);
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list