Changeset: cf51fe324217 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=cf51fe324217
Added Files:
        sql/test/VOC/Tests/median.Bug-3096.sql
        sql/test/VOC/Tests/median.Bug-3096.stable.err
        sql/test/VOC/Tests/median.Bug-3096.stable.out
Modified Files:
        .hgtags
        MonetDB.spec
        NT/installer32/MonetDB-ODBC-Installer.vdproj
        NT/installer32/MonetDB5-Geom-Module.vdproj
        NT/installer32/MonetDB5-SQL-Installer.vdproj
        NT/installer64/MonetDB-ODBC-Installer.vdproj
        NT/installer64/MonetDB5-Geom-Module.vdproj
        NT/installer64/MonetDB5-SQL-Installer.vdproj
        NT/monetdb_config.h.in
        NT/rules.msc
        clients/ChangeLog-Archive
        clients/ChangeLog.Apr2012
        clients/mapilib/mapi.rc
        clients/odbc/driver/driver.rc
        clients/odbc/winsetup/setup.rc
        clients/python/setup.py
        configure.ag
        debian/changelog
        gdk/ChangeLog-Archive
        gdk/ChangeLog.Apr2012
        gdk/gdk_heap.c
        gdk/gdk_posix.c
        gdk/libbat.rc
        libversions
        monetdb5/mal/mal_resolve.c
        monetdb5/mal/mal_resolve.h
        monetdb5/tools/libmonetdb5.rc
        sql/backends/monet5/sql.mx
        sql/backends/monet5/sql_scenario.c
        sql/scripts/39_analytics.sql
        sql/test/BugTracker-2009/Tests/explain_gives_crash.SF-2741829.stable.err
        sql/test/BugTracker-2009/Tests/explain_gives_crash.SF-2741829.stable.out
        sql/test/BugTracker-2012/Tests/predicate_select.Bug-3090.stable.out
        sql/test/Tests/systemfunctions.stable.out
        sql/test/VOC/Tests/All
        sql/test/leaks/Tests/check0.stable.out
        sql/test/leaks/Tests/check1.stable.out
        sql/test/leaks/Tests/check2.stable.out
        sql/test/leaks/Tests/check3.stable.out
        sql/test/leaks/Tests/check4.stable.out
        sql/test/leaks/Tests/check5.stable.out
        sql/test/mapi/Tests/php_monetdb.stable.out
        vertoo.data
Branch: default
Log Message:

Merged from Jul2012


diffs (truncated from 1051 to 300 lines):

diff --git a/.hgtags b/.hgtags
--- a/.hgtags
+++ b/.hgtags
@@ -482,3 +482,5 @@ 4a6a6523c78992de5d3a1e7a72454250f4964881
 cbc7f297899d61201e4d5a8cb06ae3aacf070111 Apr2012_SP1_release
 ebb4a17093e63a199a1d5d27855aa8a31c7e7785 Apr2012_SP1_release
 06c3e1846c2fc399d72edcac1ed0d877934fab67 Jun2012_root
+94ffb491c3f2a9dc47c1371760b928bb7d35c050 Apr2012_7
+95df797091e0a19c18771378f80eb8652742b062 Apr2012_SP2_release
diff --git a/MonetDB.spec b/MonetDB.spec
--- a/MonetDB.spec
+++ b/MonetDB.spec
@@ -27,7 +27,7 @@ Vendor: MonetDB BV <[email protected]>
 Group: Applications/Databases
 License: MPL - http://www.monetdb.org/Legal/MonetDBLicense
 URL: http://www.monetdb.org/
-Source: 
http://dev.monetdb.org/downloads/sources/Apr2012-SP1/%{name}-%{version}.tar.bz2
+Source: 
http://dev.monetdb.org/downloads/sources/Apr2012-SP2/%{name}-%{version}.tar.bz2
 
 BuildRequires: bison
 BuildRequires: bzip2-devel
@@ -655,6 +655,19 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/libmonet
 rm -fr $RPM_BUILD_ROOT
 
 %changelog
+* Thu Jun 07 2012 Sjoerd Mullender <[email protected]> - 11.9.7-20120607
+- Rebuilt.
+
+* Wed May 23 2012 Fabian Groffen <[email protected]> - 11.9.7-20120607
+- clients: Resolved a cosmetical error where tab-characters would cause
+  misalignments in tabular result views.  For the time being, tabs are
+  now represented as a single space in tabular view.
+
+* Thu May 17 2012 Fabian Groffen <[email protected]> - 11.9.7-20120607
+- gdk: Limit number of detected CPU cores to 16 on 32-bits systems to avoid
+  running quickly out of addressable resources followed by a kill from
+  the OS.
+
 * Wed May 16 2012 Fabian Groffen <[email protected]> - 11.9.5-20120516
 - Rebuilt.
 
diff --git a/clients/ChangeLog-Archive b/clients/ChangeLog-Archive
--- a/clients/ChangeLog-Archive
+++ b/clients/ChangeLog-Archive
@@ -1,6 +1,11 @@
 # DO NOT EDIT THIS FILE -- MAINTAINED AUTOMATICALLY
 # This file contains past ChangeLog entries
 
+* Wed May 23 2012 Fabian Groffen <[email protected]> - 11.9.7-20120607
+- Resolved a cosmetical error where tab-characters would cause
+  misalignments in tabular result views.  For the time being, tabs are
+  now represented as a single space in tabular view.
+
 * Fri Mar  9 2012 Sjoerd Mullender <[email protected]> - 11.9.1-20120418
 - ODBC: Implemented the SQL_ATTR_CONNECTION_TIMEOUT attribute.
 
diff --git a/clients/ChangeLog.Apr2012 b/clients/ChangeLog.Apr2012
--- a/clients/ChangeLog.Apr2012
+++ b/clients/ChangeLog.Apr2012
@@ -1,8 +1,3 @@
 # ChangeLog file for clients
 # This file is updated with Maddlog
 
-* Wed May 23 2012 Fabian Groffen <[email protected]>
-- Resolved a cosmetical error where tab-characters would cause
-  misalignments in tabular result views.  For the time being, tabs are
-  now represented as a single space in tabular view.
-
diff --git a/debian/changelog b/debian/changelog
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,25 @@
+monetdb (11.9.7-20120607) unstable; urgency=low
+
+  * Rebuilt.
+
+ -- Sjoerd Mullender <[email protected]>  Thu, 07 Jun 2012 11:36:25 +0200
+
+monetdb (11.9.7-20120607) unstable; urgency=low
+
+  * clients: Resolved a cosmetical error where tab-characters would cause
+    misalignments in tabular result views.  For the time being, tabs are
+    now represented as a single space in tabular view.
+
+ -- Fabian Groffen <[email protected]>  Wed, 23 May 2012 11:36:24 +0200
+
+monetdb (11.9.7-20120607) unstable; urgency=low
+
+  * gdk: Limit number of detected CPU cores to 16 on 32-bits systems to avoid
+    running quickly out of addressable resources followed by a kill from
+    the OS.
+
+ -- Fabian Groffen <[email protected]>  Thu, 17 May 2012 11:36:24 +0200
+
 monetdb (11.9.5-20120516) unstable; urgency=low
 
   * Rebuilt.
diff --git a/gdk/ChangeLog-Archive b/gdk/ChangeLog-Archive
--- a/gdk/ChangeLog-Archive
+++ b/gdk/ChangeLog-Archive
@@ -1,6 +1,11 @@
 # DO NOT EDIT THIS FILE -- MAINTAINED AUTOMATICALLY
 # This file contains past ChangeLog entries
 
+* Thu May 17 2012 Fabian Groffen <[email protected]> - 11.9.7-20120607
+- Limit number of detected CPU cores to 16 on 32-bits systems to avoid
+  running quickly out of addressable resources followed by a kill from
+  the OS.
+
 * Fri Apr 27 2012 Fabian Groffen <[email protected]> - 11.9.3-20120514
 - Implemented MT_getrss for Mac OS X systems, this allows the server to
   know about how much memory is currently in use.
diff --git a/gdk/ChangeLog.Apr2012 b/gdk/ChangeLog.Apr2012
--- a/gdk/ChangeLog.Apr2012
+++ b/gdk/ChangeLog.Apr2012
@@ -1,8 +1,3 @@
 # ChangeLog file for MonetDB
 # This file is updated with Maddlog
 
-* Thu May 17 2012 Fabian Groffen <[email protected]>
-- Limit number of detected CPU cores to 16 on 32-bits systems to avoid
-  running quickly out of addressable resources followed by a kill from
-  the OS.
-
diff --git a/gdk/gdk_heap.c b/gdk/gdk_heap.c
--- a/gdk/gdk_heap.c
+++ b/gdk/gdk_heap.c
@@ -229,10 +229,10 @@ decompose_filename(str nme)
 /*
  * @- HEAPalloc
  *
- * Normally, we use GDKmalloc for creating a new heap.  Huge heaps, though, 
come
- * from memory mapped files that we create with a large seek. This is fast, 
and leads to
- * files-with-holes on Unixes (on Windows, it actually always performs I/O 
which is not
- * nice).
+ * Normally, we use GDKmalloc for creating a new heap.  Huge heaps,
+ * though, come from memory mapped files that we create with a large
+ * seek. This is fast, and leads to files-with-holes on Unixes (on
+ * Windows, it actually always performs I/O which is not nice).
  */
 static size_t
 HEAPmargin(size_t maxsize)
@@ -357,7 +357,8 @@ HEAPextend(Heap *h, size_t size)
                        return 0;
                }
        } else {
-               /* extend a malloced heap, possibly switching over to 
file-mapped storage */
+               /* extend a malloced heap, possibly switching over to
+                * file-mapped storage */
                Heap bak = *h;
                size_t cur = GDKmem_inuse(), tot = GDK_mem_maxsize;
                int exceeds_swap = size > (tot + tot - MIN(tot + tot, cur));
@@ -370,7 +371,8 @@ HEAPextend(Heap *h, size_t size)
                h->size = size;
 
                if (can_mmap) {
-                       /* in anonymous vm, if have to realloc anyway, we 
reserve some extra space */
+                       /* in anonymous vm, if have to realloc anyway,
+                        * we reserve some extra space */
                        h->maxsize = HEAPmargin(MAX(size, h->maxsize));
                } else {
                        h->maxsize = size;      /* for normal GDKmalloc, 
maxsize = size */
diff --git a/gdk/gdk_posix.c b/gdk/gdk_posix.c
--- a/gdk/gdk_posix.c
+++ b/gdk/gdk_posix.c
@@ -329,7 +329,7 @@ MT_getrss(void)
        kvm_close(kd);
 
        return rss * MT_pagesize();
-#else
+#elif defined(__linux__)
        /* get RSS on Linux */
        int fd;
 
diff --git a/libversions b/libversions
--- a/libversions
+++ b/libversions
@@ -35,13 +35,13 @@
 
 # version of the GDK library (subdirectory gdk; also includes
 # common/options and common/utils)
-GDK_VERSION=5:1:0
+GDK_VERSION=5:2:0
 
 # version of the MAPI library (subdirectory clients/mapilib)
-MAPI_VERSION=6:0:0
+MAPI_VERSION=6:1:0
 
 # version of the MONETDB5 library (subdirectory monetdb5, not including extras)
-MONETDB5_VERSION=11:1:0
+MONETDB5_VERSION=11:2:0
 
 # version of the STREAM library (subdirectory common/stream)
 STREAM_VERSION=4:1:1
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
@@ -87,9 +87,9 @@
 #include "mal_resolve.h"
 #include "mal_namespace.h"
 
-malType getPolyType(malType t, int *polytype);
-int updateTypeMap(int formal, int actual, int polytype[MAXTYPEVAR]);
-int typeKind(MalBlkPtr mb, InstrPtr p, int i);
+static malType getPolyType(malType t, int *polytype);
+static int updateTypeMap(int formal, int actual, int polytype[MAXTYPEVAR]);
+static int typeKind(MalBlkPtr mb, InstrPtr p, int i);
 
 #define MAXMALARG 256
 
@@ -883,7 +883,7 @@ chkProgram(stream *out, Module s, MalBlk
  * header leads to a dynamic typed statement. In principle we have
  * to type check the function upon each call.
  */
-int
+static int
 typeKind(MalBlkPtr mb, InstrPtr p, int i)
 {
        malType t = getArgType(mb, p, i);
@@ -898,7 +898,7 @@ typeKind(MalBlkPtr mb, InstrPtr p, int i
  * It suffices to determine the actual return value taking into
  * account the type variable constraints.
  */
-malType
+static malType
 getPolyType(malType t, int *polytype)
 {
        int hi, ti;
@@ -926,7 +926,7 @@ getPolyType(malType t, int *polytype)
  * The routine returns the instanciated formal type for subsequent
  * type resolution.
  */
-int
+static int
 updateTypeMap(int formal, int actual, int polytype[MAXTYPEVAR])
 {
        int h, t, ret = 0;
diff --git a/monetdb5/mal/mal_resolve.h b/monetdb5/mal/mal_resolve.h
--- a/monetdb5/mal/mal_resolve.h
+++ b/monetdb5/mal/mal_resolve.h
@@ -39,7 +39,6 @@ mal_export int fcnBinder(stream *out, Mo
 extern str traceFcnName;
 mal_export void expandMacro(MalBlkPtr mb, InstrPtr p, MalBlkPtr mc);
 
-#endif /*  _MAL_RESOLVE_H*/
 /*
  * @- Type resolution algorithm.
  * Every actual argument of a function call should be type compatible
@@ -50,3 +49,5 @@ mal_export void expandMacro(MalBlkPtr mb
  * type for subsequent use.
  */
 mal_export int resolveType(int dsttype, int srctype);
+
+#endif /*  _MAL_RESOLVE_H*/
diff --git a/sql/backends/monet5/sql.mx b/sql/backends/monet5/sql.mx
--- a/sql/backends/monet5/sql.mx
+++ b/sql/backends/monet5/sql.mx
@@ -7136,6 +7136,45 @@ freeVariables(Client c, MalBlkPtr mb, Ma
  * Assume val is id,oid sorted. 
  */
 @h
+sql5_export str SQLmiddle_val(Client cntxt, MalBlkPtr mb, MalStkPtr stk, 
InstrPtr pci);
+@c
+str
+SQLmiddle_val(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr pci)
+{
+       BAT *v;
+       BUN cnt = 0, pos;
+       ValPtr res = getArgReference(stk, pci, 0);
+       int *type = (int*) getArgReference(stk, pci, 0);
+       bat valid = *(bat*) getArgReference(stk, pci, 1);
+       BATiter vi;
+
+       (void)cntxt;
+       (void)mb;
+       if( (v = BATdescriptor(valid)) == NULL ) 
+               throw(SQL, "sql.middle", "Cannot access descriptor");
+
+       *type = v->ttype;
+       cnt = BATcount(v);
+       if (cnt == 0) {
+               VALset(res, v->ttype, ATOMnilptr(v->ttype));
+               BBPunfix(v->batCacheid);
+               return MAL_SUCCEED;
+       }
+       pos = cnt/2;
+       vi = bat_iterator(v);
+       VALset(res, v->ttype, BUNtail(vi, pos));
+       BBPunfix(v->batCacheid);
+       return MAL_SUCCEED;
+}
+@mal
+pattern sql.middle_val( val:bat[:any_1,:any_2]):any_2
+address SQLmiddle_val;
+
+@h
+/*
+ * Compute the median.
+ * Assume val is id,oid sorted. 
+ */
_______________________________________________
Checkin-list mailing list
[email protected]
http://mail.monetdb.org/mailman/listinfo/checkin-list

Reply via email to