Changeset: f26bdf41e3d7 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=f26bdf41e3d7
Modified Files:
        clients/Tests/MAL-signatures.stable.out
        clients/Tests/MAL-signatures.stable.out.int128
        monetdb5/modules/kernel/alarm.c
        monetdb5/modules/kernel/alarm.mal
        sql/backends/monet5/sql_upgrades.c
        sql/scripts/25_debug.sql
        sql/test/emptydb/Tests/check.stable.out
        sql/test/emptydb/Tests/check.stable.out.32bit
        sql/test/emptydb/Tests/check.stable.out.int128
        sql/test/sys-schema/Tests/systemfunctions.stable.out
        sql/test/sys-schema/Tests/systemfunctions.stable.out.int128
Branch: linear-hashing
Log Message:

Added sleep function/procedure for tinyint and smallint types


diffs (truncated from 403 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
@@ -532,9 +532,9 @@ stdout of test 'MAL-signatures` in direc
 [ "aggr",      "variancep",    "command aggr.variancep(b:bat[:any_2]):dbl ",   
"ALGvariancep;",        "Gives the variance of all tail values" ]
 [ "alarm",     "ctime",        "unsafe command alarm.ctime():str ",    
"ALARMctime;",  "Return the current time as a C-time string."   ]
 [ "alarm",     "epoch",        "unsafe command alarm.epoch():int ",    
"ALARMepoch;",  "Return time since Jan 1, 1970 in seconds."     ]
-[ "alarm",     "sleep",        "unsafe pattern 
alarm.sleep(msecs:bat[:int]):bat[:int] ",       "ALARMsleep;",  "Sleep a few 
milliseconds and return the slept value"   ]
-[ "alarm",     "sleep",        "unsafe pattern alarm.sleep(msecs:int):int ",   
"ALARMsleep;",  "Sleep a few milliseconds and return the slept value"   ]
-[ "alarm",     "sleep",        "unsafe pattern alarm.sleep(msecs:int):void ",  
"ALARMsleep;",  "Sleep a few milliseconds"      ]
+[ "alarm",     "sleep",        "unsafe pattern alarm.sleep(msecs:any_1):any_1 
",       "ALARMsleep;",  "Sleep a few milliseconds and return the slept value"  
 ]
+[ "alarm",     "sleep",        "unsafe pattern alarm.sleep(msecs:any_1):void 
",        "ALARMsleep;",  "Sleep a few milliseconds"      ]
+[ "alarm",     "sleep",        "unsafe pattern 
alarm.sleep(msecs:bat[:any_1]):bat[:any_1] ",   "ALARMsleep;",  "Sleep a few 
milliseconds and return the slept value"   ]
 [ "alarm",     "time", "unsafe command alarm.time():int ",     "ALARMtime;",   
"Return time since program start in milliseconds."      ]
 [ "alarm",     "usec", "unsafe command alarm.usec():lng ",     "ALARMusec;",   
"Return time since Jan 1, 1970 in microseconds."        ]
 [ "algebra",   "antijoin",     "function algebra.antijoin(l:bat[:any_1], 
r:bat[:any_1], sl:bat[:oid], sr:bat[:oid], nil_matches:bit, estimate:lng) 
(X_0:bat[:oid], X_1:bat[:oid]);",   "",     ""      ]
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
@@ -636,9 +636,9 @@ stdout of test 'MAL-signatures` in direc
 [ "aggr",      "variancep",    "command aggr.variancep(b:bat[:any_2]):dbl ",   
"ALGvariancep;",        "Gives the variance of all tail values" ]
 [ "alarm",     "ctime",        "unsafe command alarm.ctime():str ",    
"ALARMctime;",  "Return the current time as a C-time string."   ]
 [ "alarm",     "epoch",        "unsafe command alarm.epoch():int ",    
"ALARMepoch;",  "Return time since Jan 1, 1970 in seconds."     ]
-[ "alarm",     "sleep",        "unsafe pattern 
alarm.sleep(msecs:bat[:int]):bat[:int] ",       "ALARMsleep;",  "Sleep a few 
milliseconds and return the slept value"   ]
-[ "alarm",     "sleep",        "unsafe pattern alarm.sleep(msecs:int):int ",   
"ALARMsleep;",  "Sleep a few milliseconds and return the slept value"   ]
-[ "alarm",     "sleep",        "unsafe pattern alarm.sleep(msecs:int):void ",  
"ALARMsleep;",  "Sleep a few milliseconds"      ]
+[ "alarm",     "sleep",        "unsafe pattern alarm.sleep(msecs:any_1):any_1 
",       "ALARMsleep;",  "Sleep a few milliseconds and return the slept value"  
 ]
+[ "alarm",     "sleep",        "unsafe pattern alarm.sleep(msecs:any_1):void 
",        "ALARMsleep;",  "Sleep a few milliseconds"      ]
+[ "alarm",     "sleep",        "unsafe pattern 
alarm.sleep(msecs:bat[:any_1]):bat[:any_1] ",   "ALARMsleep;",  "Sleep a few 
milliseconds and return the slept value"   ]
 [ "alarm",     "time", "unsafe command alarm.time():int ",     "ALARMtime;",   
"Return time since program start in milliseconds."      ]
 [ "alarm",     "usec", "unsafe command alarm.usec():lng ",     "ALARMusec;",   
"Return time since Jan 1, 1970 in microseconds."        ]
 [ "algebra",   "antijoin",     "function algebra.antijoin(l:bat[:any_1], 
r:bat[:any_1], sl:bat[:oid], sr:bat[:oid], nil_matches:bit, estimate:lng) 
(X_0:bat[:oid], X_1:bat[:oid]);",   "",     ""      ]
diff --git a/monetdb5/modules/kernel/alarm.c b/monetdb5/modules/kernel/alarm.c
--- a/monetdb5/modules/kernel/alarm.c
+++ b/monetdb5/modules/kernel/alarm.c
@@ -39,57 +39,95 @@ ALARMusec(lng *ret)
        return MAL_SUCCEED;
 }
 
+#define SLEEP_SINGLE(TPE) \
+       do { \
+               TPE *res = (TPE*) getArgReference(stk, pci, 0), *msecs = (TPE*) 
getArgReference(stk,pci,1); \
+               if (is_##TPE##_nil(*msecs)) \
+                       throw(MAL, "alarm.sleepr", "NULL values not allowed for 
sleeping time"); \
+               if (*msecs < 0) \
+                       throw(MAL, "alarm.sleepr", "Cannot sleep for a negative 
time"); \
+               MT_sleep_ms((unsigned int) *msecs); \
+               *res = *msecs; \
+       } while (0)
+
+#define SLEEP_MULTI(TPE) \
+       do { \
+               for (i = 0; i < j ; i++) { \
+                       if (is_##TPE##_nil(bb[i])) { \
+                               BBPreclaim(r); \
+                               BBPunfix(b->batCacheid); \
+                               throw(MAL, "alarm.sleepr", "NULL values not 
allowed for sleeping time"); \
+                       } \
+                       if (bb[i] < 0) { \
+                               BBPreclaim(r); \
+                               BBPunfix(b->batCacheid); \
+                               throw(MAL, "alarm.sleepr", "Cannot sleep for a 
negative time"); \
+                       } \
+               } \
+               for (i = 0; i < j ; i++) { \
+                       MT_sleep_ms((unsigned int) bb[i]); \
+                       rb[i] = bb[i]; \
+               } \
+       } while (0)
+
 str
 ALARMsleep(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci)
 {
-       BAT *r, *b;
-       int *restrict rb, *restrict bb;
+       BAT *r = NULL, *b = NULL;
+       int *restrict rb, *restrict bb, tpe;
        BUN i, j;
 
        (void) cntxt;
        if (getArgType(mb, pci, 0) != TYPE_void && isaBatType(getArgType(mb, 
pci, 1))) {
                bat *res = getArgReference_bat(stk, pci, 0);
                bat *bid = getArgReference_bat(stk, pci, 1);
-               
+               tpe = getArgType(mb, pci, 1);
+
                if (!(b = BATdescriptor(*bid)))
                        throw(MAL, "alarm.sleepr", SQLSTATE(HY005) "Cannot 
access column descriptor");
 
                j = BATcount(b);
                bb = Tloc(b, 0);
-               for (i = 0; i < j ; i++) {
-                       if (is_int_nil(bb[i])) {
-                               BBPunfix(b->batCacheid);
-                               throw(MAL, "alarm.sleepr", "NULL values not 
allowed for the sleeping time");
-                       } else if (bb[i]) {
-                               BBPunfix(b->batCacheid);
-                               throw(MAL, "alarm.sleepr", "Cannot sleep for a 
negative time");
-                       }
-               }
 
-               r = COLnew(0, TYPE_int, j, TRANSIENT);
-               if (r == NULL) {
+               if (!(r = COLnew(0, tpe, j, TRANSIENT))) {
                        BBPunfix(b->batCacheid);
                        throw(MAL, "alarm.sleepr", SQLSTATE(HY013) 
MAL_MALLOC_FAIL);
                }
+               rb = Tloc(r, 0);
 
-               rb = Tloc(r, 0);
-               for (i = 0; i < j ; i++) {
-                       MT_sleep_ms(bb[i]);
-                       rb[i] = bb[i];
+               switch (tpe) {
+                       case TYPE_bte:
+                               SLEEP_MULTI(bte);
+                               break;
+                       case TYPE_sht:
+                               SLEEP_MULTI(sht);
+                               break;
+                       case TYPE_int:
+                               SLEEP_MULTI(int);
+                               break;
+                       default: {
+                               BBPreclaim(r);
+                               BBPunfix(b->batCacheid);
+                               throw(MAL, "alarm.sleepr", SQLSTATE(42000) 
"Sleep function not available for type %s", ATOMname(tpe));
+                       }
                }
 
                BBPunfix(b->batCacheid);
                BBPkeepref(*res = r->batCacheid);
        } else {
-               int *res = (int*) getArgReference(stk, pci, 0), *msecs = (int*) 
getArgReference(stk,pci,1);
-
-               if (is_int_nil(*msecs))
-                       throw(MAL, "alarm.sleepr", "NULL values not allowed for 
the sleeping time");
-               else if (*msecs < 0)
-                       throw(MAL, "alarm.sleepr", "Cannot sleep for a negative 
time");
-
-               MT_sleep_ms(*msecs);
-               *res = *msecs;
+               switch (getArgType(mb, pci, 1)) {
+                       case TYPE_bte:
+                               SLEEP_SINGLE(bte);
+                               break;
+                       case TYPE_sht:
+                               SLEEP_SINGLE(sht);
+                               break;
+                       case TYPE_int:
+                               SLEEP_SINGLE(int);
+                               break;
+                       default:
+                               throw(MAL, "alarm.sleepr", SQLSTATE(42000) 
"Sleep function not available for type %s", ATOMname(getArgType(mb, pci, 1)));
+               }
        }
        return MAL_SUCCEED;
 }
diff --git a/monetdb5/modules/kernel/alarm.mal 
b/monetdb5/modules/kernel/alarm.mal
--- a/monetdb5/modules/kernel/alarm.mal
+++ b/monetdb5/modules/kernel/alarm.mal
@@ -6,15 +6,15 @@
 
 module alarm;
 
-unsafe pattern alarm.sleep(msecs:int) :void
+unsafe pattern alarm.sleep(msecs:any_1) :void
 address ALARMsleep
 comment "Sleep a few milliseconds";
 
-unsafe pattern alarm.sleep(msecs:int) :int
+unsafe pattern alarm.sleep(msecs:any_1) :any_1
 address ALARMsleep
 comment "Sleep a few milliseconds and return the slept value";
 
-unsafe pattern alarm.sleep(msecs:bat[:int]) :bat[:int]
+unsafe pattern alarm.sleep(msecs:bat[:any_1]) :bat[:any_1]
 address ALARMsleep
 comment "Sleep a few milliseconds and return the slept value";
 
diff --git a/sql/backends/monet5/sql_upgrades.c 
b/sql/backends/monet5/sql_upgrades.c
--- a/sql/backends/monet5/sql_upgrades.c
+++ b/sql/backends/monet5/sql_upgrades.c
@@ -2508,12 +2508,24 @@ sql_update_linear_hashing(Client c, mvc 
                        "create function sys.debugflags()\n"
                        " returns table(flag string, val bool)\n"
                        " external name mdb.\"getDebugFlags\";\n"
+                       "create procedure sys.\"sleep\"(msecs tinyint)\n"
+                       " external name \"alarm\".\"sleep\";\n"
+                       "grant execute on procedure sys.\"sleep\"(tinyint) to 
public;\n"
+                       "create procedure sys.\"sleep\"(msecs smallint)\n"
+                       " external name \"alarm\".\"sleep\";\n"
+                       "grant execute on procedure sys.\"sleep\"(smallint) to 
public;\n"
                        "create procedure sys.\"sleep\"(msecs int)\n"
                        " external name \"alarm\".\"sleep\";\n"
-                       "grant execute on procedure sys.\"sleep\"(int) to 
public;\n"
-                       "create function sys.\"sleep\"(msecs int) returns 
integer\n"
+                       " grant execute on procedure sys.\"sleep\"(int) to 
public;\n"
+                       "create function sys.\"sleep\"(msecs tinyint) returns 
tinyint\n"
                        " external name \"alarm\".\"sleep\";\n"
-                       "grant execute on function sys.\"sleep\"(int) to 
public;\n");
+                       "grant execute on function sys.\"sleep\"(tinyint) to 
public;\n"
+                       "create function sys.\"sleep\"(msecs smallint) returns 
smallint\n"
+                       " external name \"alarm\".\"sleep\";\n"
+                       "grant execute on function sys.\"sleep\"(smallint) to 
public;\n"
+                       "create function sys.\"sleep\"(msecs int) returns int\n"
+                       " external name \"alarm\".\"sleep\";\n"
+                       " grant execute on function sys.\"sleep\"(int) to 
public;\n");
        pos += snprintf(buf + pos, bufsize - pos,
                        "update sys.functions set system = true where schema_id 
= (select id from sys.schemas where name = 'sys')"
                        " and name in ('debug', 'debugflags', 'sleep');\n");
diff --git a/sql/scripts/25_debug.sql b/sql/scripts/25_debug.sql
--- a/sql/scripts/25_debug.sql
+++ b/sql/scripts/25_debug.sql
@@ -83,11 +83,23 @@ create function sys.deltas ("schema" str
        external name "sql"."deltas";
 
 -- Sleep procedure
+create procedure sys."sleep"(msecs tinyint)
+       external name "alarm"."sleep";
+grant execute on procedure sys."sleep"(tinyint) to public;
+create procedure sys."sleep"(msecs smallint)
+       external name "alarm"."sleep";
+grant execute on procedure sys."sleep"(smallint) to public;
 create procedure sys."sleep"(msecs int)
        external name "alarm"."sleep";
 grant execute on procedure sys."sleep"(int) to public;
 
 -- Sleep function
-create function sys."sleep"(msecs int) returns integer
+create function sys."sleep"(msecs tinyint) returns tinyint
+       external name "alarm"."sleep";
+grant execute on function sys."sleep"(tinyint) to public;
+create function sys."sleep"(msecs smallint) returns smallint
+       external name "alarm"."sleep";
+grant execute on function sys."sleep"(smallint) to public;
+create function sys."sleep"(msecs int) returns int
        external name "alarm"."sleep";
 grant execute on function sys."sleep"(int) to public;
diff --git a/sql/test/emptydb/Tests/check.stable.out 
b/sql/test/emptydb/Tests/check.stable.out
--- a/sql/test/emptydb/Tests/check.stable.out
+++ b/sql/test/emptydb/Tests/check.stable.out
@@ -1177,8 +1177,12 @@ create procedure shpload(fid integer, fi
 create procedure shrink(sys string, tab string) external name sql.shrink;
 create procedure sys.shutdown("delay" tinyint) external name sql.shutdown;
 create procedure sys.shutdown("delay" tinyint, "force" bool) external name 
sql.shutdown;
-create function sys."sleep"(msecs int) returns integer external name 
"alarm"."sleep";
+create function sys."sleep"(msecs int) returns int external name 
"alarm"."sleep";
+create function sys."sleep"(msecs smallint) returns smallint external name 
"alarm"."sleep";
+create function sys."sleep"(msecs tinyint) returns tinyint external name 
"alarm"."sleep";
 create procedure sys."sleep"(msecs int) external name "alarm"."sleep";
+create procedure sys."sleep"(msecs smallint) external name "alarm"."sleep";
+create procedure sys."sleep"(msecs tinyint) external name "alarm"."sleep";
 create function st_area(geom geometry) returns double external name 
geom."Area";
 create function st_asbinary(geom geometry) returns string external name 
geom."AsBinary";
 create function st_asewkt(geom geometry) returns string external name 
geom."AsEWKT";
@@ -3394,8 +3398,12 @@ drop function pcre_replace(string, strin
 [ "sys",       "sin",  "SYSTEM",       "sin",  "mmath",        "Internal C",   
"Scalar function",      false,  false,  false,  "res_0",        "real", 24,     
0,      "out",  "arg_1",        "real", 24,     0,      "in",   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL    ]
 [ "sys",       "sinh", "SYSTEM",       "sinh", "mmath",        "Internal C",   
"Scalar function",      false,  false,  false,  "res_0",        "double",       
53,     0,      "out",  "arg_1",        "double",       53,     0,      "in",   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL    
]
 [ "sys",       "sinh", "SYSTEM",       "sinh", "mmath",        "Internal C",   
"Scalar function",      false,  false,  false,  "res_0",        "real", 24,     
0,      "out",  "arg_1",        "real", 24,     0,      "in",   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL    ]
-[ "sys",       "sleep",        "SYSTEM",       "create function 
sys.\"sleep\"(msecs int) returns integer external name \"alarm\".\"sleep\";",  
"alarm",        "MAL",  "Scalar function",      false,  false,  false,  
"result",       "int",  32,     0,      "out",  "msecs",        "int",  32,     
0,      "in",   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL    ]
+[ "sys",       "sleep",        "SYSTEM",       "create function 
sys.\"sleep\"(msecs int) returns int external name \"alarm\".\"sleep\";",      
"alarm",        "MAL",  "Scalar function",      false,  false,  false,  
"result",       "int",  32,     0,      "out",  "msecs",        "int",  32,     
0,      "in",   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL    ]
+[ "sys",       "sleep",        "SYSTEM",       "create function 
sys.\"sleep\"(msecs smallint) returns smallint external name 
\"alarm\".\"sleep\";",    "alarm",        "MAL",  "Scalar function",      
false,  false,  false,  "result",       "smallint",     16,     0,      "out",  
"msecs",        "smallint",     16,     0,      "in",   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL    ]
+[ "sys",       "sleep",        "SYSTEM",       "create function 
sys.\"sleep\"(msecs tinyint) returns tinyint external name 
\"alarm\".\"sleep\";",      "alarm",        "MAL",  "Scalar function",      
false,  false,  false,  "result",       "tinyint",      8,      0,      "out",  
"msecs",        "tinyint",      8,      0,      "in",   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL    ]
 [ "sys",       "sleep",        "SYSTEM",       "create procedure 
sys.\"sleep\"(msecs int) external name \"alarm\".\"sleep\";", "alarm",        
"MAL",  "Procedure",    true,   false,  false,  "msecs",        "int",  32,     
0,      "in",   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL    ]
+[ "sys",       "sleep",        "SYSTEM",       "create procedure 
sys.\"sleep\"(msecs smallint) external name \"alarm\".\"sleep\";",    "alarm",  
      "MAL",  "Procedure",    true,   false,  false,  "msecs",        
"smallint",     16,     0,      "in",   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL    
]
+[ "sys",       "sleep",        "SYSTEM",       "create procedure 
sys.\"sleep\"(msecs tinyint) external name \"alarm\".\"sleep\";",     "alarm",  
      "MAL",  "Procedure",    true,   false,  false,  "msecs",        
"tinyint",      8,      0,      "in",   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL    
]
 [ "sys",       "soundex",      "SYSTEM",       "soundex",      "txtsim",       
"Internal C",   "Scalar function",      false,  false,  false,  "res_0",        
"char", 0,      0,      "out",  "arg_1",        "char", 0,      0,      "in",   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL    
]
 [ "sys",       "soundex",      "SYSTEM",       "soundex",      "txtsim",       
"Internal C",   "Scalar function",      false,  false,  false,  "res_0",        
"clob", 0,      0,      "out",  "arg_1",        "clob", 0,      0,      "in",   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL    
]
 [ "sys",       "soundex",      "SYSTEM",       "soundex",      "txtsim",       
"Internal C",   "Scalar function",      false,  false,  false,  "res_0",        
"varchar",      0,      0,      "out",  "arg_1",        "varchar",      0,      
0,      "in",   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL    ]
@@ -5071,6 +5079,10 @@ drop function pcre_replace(string, strin
 [ "setworkerlimit",    "public",       "EXECUTE",      "monetdb",      0       
]
 [ "sleep",     "public",       "EXECUTE",      "monetdb",      0       ]
 [ "sleep",     "public",       "EXECUTE",      "monetdb",      0       ]
+[ "sleep",     "public",       "EXECUTE",      "monetdb",      0       ]
+[ "sleep",     "public",       "EXECUTE",      "monetdb",      0       ]
+[ "sleep",     "public",       "EXECUTE",      "monetdb",      0       ]
+[ "sleep",     "public",       "EXECUTE",      "monetdb",      0       ]
 [ "st_area",   "public",       "EXECUTE",      "monetdb",      0       ]
 [ "st_asbinary",       "public",       "EXECUTE",      "monetdb",      0       
]
 [ "st_asewkt", "public",       "EXECUTE",      "monetdb",      0       ]
diff --git a/sql/test/emptydb/Tests/check.stable.out.32bit 
b/sql/test/emptydb/Tests/check.stable.out.32bit
--- a/sql/test/emptydb/Tests/check.stable.out.32bit
+++ b/sql/test/emptydb/Tests/check.stable.out.32bit
@@ -1171,8 +1171,12 @@ create procedure shpload(fid integer, fi
 create procedure shrink(sys string, tab string) external name sql.shrink;
 create procedure sys.shutdown("delay" tinyint) external name sql.shutdown;
 create procedure sys.shutdown("delay" tinyint, "force" bool) external name 
sql.shutdown;
-create function sys."sleep"(msecs int) returns integer external name 
"alarm"."sleep";
+create function sys."sleep"(msecs int) returns int external name 
"alarm"."sleep";
+create function sys."sleep"(msecs smallint) returns smallint external name 
"alarm"."sleep";
+create function sys."sleep"(msecs tinyint) returns tinyint external name 
"alarm"."sleep";
 create procedure sys."sleep"(msecs int) external name "alarm"."sleep";
+create procedure sys."sleep"(msecs smallint) external name "alarm"."sleep";
+create procedure sys."sleep"(msecs tinyint) external name "alarm"."sleep";
 create function st_area(geom geometry) returns double external name 
geom."Area";
 create function st_asbinary(geom geometry) returns string external name 
geom."AsBinary";
 create function st_asewkt(geom geometry) returns string external name 
geom."AsEWKT";
@@ -3377,8 +3381,12 @@ drop function pcre_replace(string, strin
 [ "sys",       "sin",  "SYSTEM",       "sin",  "mmath",        "Internal C",   
"Scalar function",      false,  false,  false,  "res_0",        "real", 24,     
0,      "out",  "arg_1",        "real", 24,     0,      "in",   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   
NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL,   NULL    ]
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to