Changeset: 69f00b632588 for MonetDB
URL: http://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=69f00b632588
Modified Files:
        gdk/gdk.h
        gdk/gdk_col.c
        gdk/gdk_colop.c
        gdk/gdk_inspect.c
        monetdb5/mal/mal_box.c
        monetdb5/mal/mal_dataflow.c
        monetdb5/mal/mal_dataflow.h
        monetdb5/mal/mal_interpreter.c
        monetdb5/mal/mal_type.c
        monetdb5/modules/atoms/str.c
        monetdb5/modules/kernel/algebra.c.mx
        monetdb5/modules/kernel/algebra.h.mx
        monetdb5/modules/kernel/algebra.mal.mx
        monetdb5/modules/kernel/calc.c.mx
        monetdb5/modules/kernel/calc.h.mx
        monetdb5/modules/kernel/calc.mal.mx
        monetdb5/modules/kernel/colcalc.c.mx
        monetdb5/modules/kernel/colcalc.h.mx
        monetdb5/modules/kernel/colcalc.mal.mx
        monetdb5/modules/kernel/colcast.mal.mx
        monetdb5/modules/kernel/colcolor.c.mx
        monetdb5/modules/kernel/colcolor.h.mx
        monetdb5/modules/kernel/colifthen.c.mx
        monetdb5/modules/kernel/colifthen.h.mx
        monetdb5/modules/kernel/colifthen.mal.mx
        monetdb5/modules/kernel/colmath.c.mx
        monetdb5/modules/kernel/colmath.h.mx
        monetdb5/modules/kernel/colmath.mal.mx
        monetdb5/modules/kernel/colmtime.c.mx
        monetdb5/modules/kernel/colmtime.h.mx
        monetdb5/modules/kernel/colmtime.mal.mx
        monetdb5/modules/kernel/colstr.c
        monetdb5/modules/kernel/column.c.mx
        monetdb5/modules/kernel/column.h.mx
        monetdb5/modules/kernel/column.mal.mx
        monetdb5/modules/kernel/mmath.c.mx
        monetdb5/modules/kernel/mmath.h.mx
        monetdb5/modules/kernel/mmath.mal.mx
        monetdb5/optimizer/opt_datacyclotron.c
        monetdb5/optimizer/opt_dataflow.c
        monetdb5/optimizer/opt_wrapper.c
Branch: headless
Log Message:

Make compilable after recent merges.


diffs (truncated from 1868 to 300 lines):

diff --git a/gdk/gdk.h b/gdk/gdk.h
--- a/gdk/gdk.h
+++ b/gdk/gdk.h
@@ -3281,7 +3281,7 @@
 /* Inspection routines to be used outside GDK */
 gdk_export lng COLgetDiskSize(COL *b);
 gdk_export lng COLgetMemorySize(COL *b);
-gdk_export lng COLgetDatabaseSize();
+gdk_export lng COLgetDatabaseSize(void);
 gdk_export int COLinfo(COL *b, COL **bpx, COL **bvx);
 
 gdk_export ptr COLget(COL *b, oid o);
diff --git a/gdk/gdk_col.c b/gdk/gdk_col.c
--- a/gdk/gdk_col.c
+++ b/gdk/gdk_col.c
@@ -911,7 +911,7 @@
  * The upper layers should assure that we don't run out of memory space
  * using the BUNappendCheck.
  */
-int
+static int
 BUNappendCheck(COL *b, oid incr)
 {
        assert(incr <= BUN_MAX); /* i.e. not BUN_NONE */
@@ -1126,6 +1126,7 @@
                                b->seqbase++;
                        }
                } else {
+                       unsigned short hs = b->width;
                        char tmp[16];
                        /* avoid compiler warning: dereferencing type-punned 
pointer
                         * will break strict-aliasing rules */
diff --git a/gdk/gdk_colop.c b/gdk/gdk_colop.c
--- a/gdk/gdk_colop.c
+++ b/gdk/gdk_colop.c
@@ -638,7 +638,7 @@
  * through the definition of MIL we do not want the nils to appear in
  * the result (as (nil @{<,=,>@} ANY) = bit(nil) != true).
  */
-COL *
+static COL *
 COL_scanselect(COL *b, COL *s, COL *bn, ptr tl, ptr th, bit li, bit hi, int 
equi, int anti, int lval, int hval, int lnil, int nocheck)
 {
        COLiter bi;
@@ -1282,7 +1282,7 @@
 
 /* Sort b in-place according to stable and reverse.
  * Change o (if given) in-place with the obtained ordering */
-COL *
+static COL *
 COLorder_internal(COL *b, COL *o, int stable, int reverse)
 {
        COLcheck(b, "COLorder_internal");
diff --git a/gdk/gdk_inspect.c b/gdk/gdk_inspect.c
--- a/gdk/gdk_inspect.c
+++ b/gdk/gdk_inspect.c
@@ -96,7 +96,7 @@
 }
 
 lng
-COLgetDatabaseSize()
+COLgetDatabaseSize(void)
 {
     COL *b;
     bat i;
diff --git a/monetdb5/mal/mal_box.c b/monetdb5/mal/mal_box.c
--- a/monetdb5/mal/mal_box.c
+++ b/monetdb5/mal/mal_box.c
@@ -435,37 +435,6 @@
        return 0;
 }
 
-/*
- * The function bindCOL relates a logical column name with a physical
- * representation. The bind commands are typically found in the boxes,
- * which provide users a partial view over the column storage area.
- * That is, all bats bound can be taken out of the box upon need.
- * A variable can be rebound to another column at any time.
-*/
-int
-bindCOL(Box box, str name, str location)
-{
-       int i;
-       ValPtr v;
-       MALtype tpe= newMALtype(TYPE_any);
-
-       i = findVariable(box->sym, name);
-       if ( box->val == NULL)
-               return 0;
-       if (i < 0)
-               i = newVariable(box->sym, GDKstrdup(name), tpe);
-       v = &box->val->stk[i];
-       v->val.bval = CBPindex(location);
-
-       if (v->val.bval == 0)
-               return -1;
-       v->vtype = TYPE_bat;
-#ifdef DEBUG_MAL_BOX
-       mnstr_printf(GDKout, "bindBox:'%s' to '%s' [%d] in '%s'\n", name, 
location, v->val.bval, box->name);
-#endif
-       return 0;
-}
-
 int
 releaseBox(Box box, str name)
 {
@@ -727,10 +696,3 @@
                }
        }
 }
-
-void
-printBox(stream *fd, Box obj)
-{
-       if ( obj &&  obj->val )
-               printStack(fd, obj->sym, obj->val);
-}
diff --git a/monetdb5/mal/mal_dataflow.c b/monetdb5/mal/mal_dataflow.c
--- a/monetdb5/mal/mal_dataflow.c
+++ b/monetdb5/mal/mal_dataflow.c
@@ -49,6 +49,7 @@
 #include "mal_linker.h"
 #include "mal_listing.h"
 #include "mal_type.h"
+#include "mal_dataflow.h"
 
 #define MEMORY_THRESHOLD  0.8
 #define MAXHOT 16
@@ -153,7 +154,7 @@
 #define heapinfo(X) if((X) && (X)->base) vol = (X)->free; else vol = 0;
 #define hashinfo(X) if((X) && (X)->mask) vol = 
((X)->mask+(X)->lim+1)*sizeof(int) + sizeof(*(X)); else vol = 0;
 
-static lng
+lng
 getMemoryClaim(MalBlkPtr mb, MalStkPtr stk, InstrPtr pci, int i, int flag){
        lng total=0, vol = 0;
        oid cnt = 0;
@@ -180,7 +181,7 @@
        return total;
 }
 
-int
+static int
 DFLOWadmission(lng argclaim, lng hotclaim)
 {
        /* optimistically set memory */
diff --git a/monetdb5/mal/mal_dataflow.h b/monetdb5/mal/mal_dataflow.h
--- a/monetdb5/mal/mal_dataflow.h
+++ b/monetdb5/mal/mal_dataflow.h
@@ -29,6 +29,6 @@
 
 mal_export str runMALdataflow( Client cntxt, MalBlkPtr mb, int startpc,
                int stoppc, MalStkPtr stk, MalStkPtr env, InstrPtr pcicaller);
-mal_export void getMemoryClaim(MalBlkPtr mb, MalStkPtr stk, InstrPtr pci, int 
i, int flag);
+mal_export lng getMemoryClaim(MalBlkPtr mb, MalStkPtr stk, InstrPtr pci, int 
i, int flag);
 
 #endif /*  _MAL_DATAFLOW_H*/
diff --git a/monetdb5/mal/mal_interpreter.c b/monetdb5/mal/mal_interpreter.c
--- a/monetdb5/mal/mal_interpreter.c
+++ b/monetdb5/mal/mal_interpreter.c
@@ -135,7 +135,7 @@
  * Also we cannot overwrite values on the stack as this maybe part of a
  * sequence of factory calls.
  */
-inline void
+inline static void
 initStack(MalBlkPtr mb, MalStkPtr stk, int start)
 {
        int i;
diff --git a/monetdb5/mal/mal_type.c b/monetdb5/mal/mal_type.c
--- a/monetdb5/mal/mal_type.c
+++ b/monetdb5/mal/mal_type.c
@@ -223,11 +223,3 @@
        }
        return 0;
 }
-
-inline int
-getGDKType(MALtype tpe){
-       if (tpe.type == TYPE_any )
-               return TYPE_void;
-       return ATOMtype(tpe.type);
-}
-
diff --git a/monetdb5/modules/atoms/str.c b/monetdb5/modules/atoms/str.c
--- a/monetdb5/modules/atoms/str.c
+++ b/monetdb5/modules/atoms/str.c
@@ -1130,7 +1130,7 @@
                (A1) = int_nil; \
        }
 
-unsigned char *UTF8_PUTCHAR( int A1, unsigned char *A2)
+static unsigned char *UTF8_PUTCHAR( int A1, unsigned char *A2)
 {
        if ((A1) < 0 
 #if SIZEOF_INT > 4 
diff --git a/monetdb5/modules/kernel/algebra.c.mx 
b/monetdb5/modules/kernel/algebra.c.mx
--- a/monetdb5/modules/kernel/algebra.c.mx
+++ b/monetdb5/modules/kernel/algebra.c.mx
@@ -1,26 +1,25 @@
+@/
+The contents of this file are subject to the MonetDB Public License
+Version 1.1 (the "License"); you may not use this file except in
+compliance with the License. You may obtain a copy of the License at
+http://www.monetdb.org/Legal/MonetDBLicense
+
+Software distributed under the License is distributed on an "AS IS"
+basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
+License for the specific language governing rights and limitations
+under the License.
+
+The Original Code is the MonetDB Database System.
+
+The Initial Developer of the Original Code is CWI.
+Portions created by CWI are Copyright (C) 1997-July 2008 CWI.
+Copyright August 2008-2011 MonetDB B.V.
+All Rights Reserved.
+@
+
+@f algebra
+
 @c
-/*
- * //
- *  * The contents of this file are subject to the MonetDB Public License
- *  * Version 1.1 (the "License"); you may not use this file except in
- *  * compliance with the License. You may obtain a copy of the License at
- *  * http://www.monetdb.org/Legal/MonetDBLicense
- *  *
- *  * Software distributed under the License is distributed on an "AS IS"
- *  * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See the
- *  * License for the specific language governing rights and limitations
- *  * under the License.
- *  *
- *  * The Original Code is the MonetDB Database System.
- *  *
- *  * The Initial Developer of the Original Code is CWI.
- *  * Portions created by CWI are Copyright (C) 1997-July 2008 CWI.
- *  * Copyright August 2008-2011 MonetDB B.V.
- *  * All Rights Reserved.
- *
- *
- * @f algebra
- */
 /* Author(s) Peter Boncz, Martin Kersten, Niels Nes
  * BAT Algebra
  * This modules contains the most common algebraic BAT manipulation
@@ -85,7 +84,7 @@
                                        *(TYPE*)aggr  = lbase[o]; \
        }               } 
 
-void
+static void
 COLmin(COL *b, ptr aggr)
 {
        int t;
@@ -164,7 +163,7 @@
                                        *(TYPE*) aggr = lbase[o]; \
                        } }
 
-ptr
+static ptr
 COLmax(COL *b, ptr aggr)
 {
        int t;
@@ -662,7 +661,7 @@
        throw(MAL, "algebra.select", GDK_EXCEPTION);
 }
 
-str
+static str
 ALGantiselectInclusive(int *result, int *bid, ptr low, ptr high, bit *lin, bit 
*rin)
 {
        COL *b, *bn = NULL;
@@ -1061,6 +1060,7 @@
        throw(MAL, "algebra.tsort", GDK_EXCEPTION);
 }
 
+#if 0
 str
 ALGorder(int *ret, int *bid)
 {
@@ -1090,6 +1090,7 @@
        CBPreleaseref(b);
        return MAL_SUCCEED;
 }
+#endif
 
 str
 ALGssort(int *result, int *bid)
diff --git a/monetdb5/modules/kernel/algebra.h.mx 
b/monetdb5/modules/kernel/algebra.h.mx
--- a/monetdb5/modules/kernel/algebra.h.mx
+++ b/monetdb5/modules/kernel/algebra.h.mx
@@ -1,26 +1,25 @@
+@/
+The contents of this file are subject to the MonetDB Public License
+Version 1.1 (the "License"); you may not use this file except in
+compliance with the License. You may obtain a copy of the License at
+http://www.monetdb.org/Legal/MonetDBLicense
+
_______________________________________________
Checkin-list mailing list
[email protected]
http://mail.monetdb.org/mailman/listinfo/checkin-list

Reply via email to