Changeset: 987222398c69 for MonetDB
URL: https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=987222398c69
Modified Files:
        clients/Tests/exports.stable.out
        common/options/monet_options.c
        gdk/gdk.h
        gdk/gdk_utils.c
        monetdb5/modules/mal/tablet.c
        tools/mserver/mserver5.1.in
Branch: Apr2019
Log Message:

Removed unused gdk_vmtrim option.


diffs (136 lines):

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
@@ -211,7 +211,6 @@ BAT *COLcopy(BAT *b, int tt, bool writab
 BAT *COLnew(oid hseq, int tltype, BUN capacity, role_t role) 
__attribute__((__warn_unused_result__));
 size_t GDK_mem_maxsize;
 size_t GDK_vm_maxsize;
-int GDK_vm_trim;
 gdk_return GDKanalyticalavg(BAT *r, BAT *b, BAT *s, BAT *e, int tpe);
 gdk_return GDKanalyticalcount(BAT *r, BAT *b, BAT *s, BAT *e, const bit 
*restrict ignore_nils, int tpe);
 gdk_return GDKanalyticaldiff(BAT *r, BAT *b, BAT *p, int tpe);
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      10      /*MUST MATCH # OPTIONS BELOW */
+#define N_OPTIONS      9       /*MUST MATCH # OPTIONS BELOW */
        set = malloc(sizeof(opt) * N_OPTIONS);
        if (set == NULL)
                return 0;
@@ -234,20 +234,6 @@ mo_builtin_settings(opt **Set)
        set[i].value = strdup("0");
        i++;
        set[i].kind = opt_builtin;
-       set[i].name = strdup("gdk_vmtrim");
-       /* default for gdk_vmtrim is
-        * "yes" on 32 bit architectures and
-        * "no"  on 64 bit architectures;
-        * see also GDKinit() in gdk/gdk_utils.c */
-#if SIZEOF_VOID_P == 4
-       /* 32 bit architecture */
-       set[i].value = strdup("yes");
-#else
-       /* 64 bit architecture */
-       set[i].value = strdup("no");
-#endif
-       i++;
-       set[i].kind = opt_builtin;
        set[i].name = strdup("monet_prompt");
        set[i].value = strdup(">");
        i++;
diff --git a/gdk/gdk.h b/gdk/gdk.h
--- a/gdk/gdk.h
+++ b/gdk/gdk.h
@@ -1882,7 +1882,6 @@ gdk_export void *GDKmmap(const char *pat
 
 gdk_export size_t GDK_mem_maxsize;     /* max allowed size of committed memory 
*/
 gdk_export size_t GDK_vm_maxsize;      /* max allowed size of reserved vm */
-gdk_export int GDK_vm_trim;            /* allow trimming */
 
 gdk_export size_t GDKmem_cursize(void);        /* RAM/swapmem that MonetDB has 
claimed from OS */
 gdk_export size_t GDKvm_cursize(void); /* current MonetDB VM address space 
usage */
diff --git a/gdk/gdk_utils.c b/gdk/gdk_utils.c
--- a/gdk/gdk_utils.c
+++ b/gdk/gdk_utils.c
@@ -285,8 +285,6 @@ size_t GDK_mmap_pagesize = MMAP_PAGESIZE
 size_t GDK_mem_maxsize = GDK_VM_MAXSIZE;
 size_t GDK_vm_maxsize = GDK_VM_MAXSIZE;
 
-int GDK_vm_trim = 1;
-
 #define SEG_SIZE(x,y)  ((x)+(((x)&((1<<(y))-1))?(1<<(y))-((x)&((1<<(y))-1)):0))
 
 /* This block is to provide atomic addition and subtraction to select
@@ -787,8 +785,6 @@ GDKreset(int status, int exit)
                GDK_vm_maxsize = GDK_VM_MAXSIZE;
                GDKatomcnt = TYPE_str + 1;
 
-               GDK_vm_trim = 1;
-
                if (GDK_mem_maxsize / 16 < GDK_mmap_minsize_transient) {
                        GDK_mmap_minsize_transient = GDK_mem_maxsize / 16;
                        if (GDK_mmap_minsize_persistent > 
GDK_mmap_minsize_transient)
diff --git a/monetdb5/modules/mal/tablet.c b/monetdb5/modules/mal/tablet.c
--- a/monetdb5/modules/mal/tablet.c
+++ b/monetdb5/modules/mal/tablet.c
@@ -1587,7 +1587,6 @@ SQLload_file(Client cntxt, Tablet *as, b
        READERtask ptask[MAXWORKERS];
        int threads = (!maxrow || maxrow > (1 << 16)) ? (GDKnr_threads < 
MAXWORKERS && GDKnr_threads > 1 ? GDKnr_threads - 1 : MAXWORKERS - 1) : 1;
        lng lio = 0, tio, t1 = 0, total = 0, iototal = 0;
-       int vmtrim = GDK_vm_trim;
 
 #ifdef _DEBUG_TABLET_
        mnstr_printf(GDKout, "#Prepare copy work for %d threads col '%s' rec 
'%s' quot '%c'\n",
@@ -1606,11 +1605,6 @@ SQLload_file(Client cntxt, Tablet *as, b
                goto bailout;
        }
 
-       /* trimming process should not be active during this process. */
-       /* on sf10 experiments it showed a slowdown of a factor 2 on */
-       /* large tables. Instead rely on madvise */
-       GDK_vm_trim = 0;
-
        assert(rsep);
        assert(csep);
        assert(maxrow < 0 || maxrow <= (lng) BUN_MAX);
@@ -2006,8 +2000,6 @@ SQLload_file(Client cntxt, Tablet *as, b
        munlockall();
 #endif
 
-       /* restore system setting */
-       GDK_vm_trim = vmtrim;
        return res < 0 ? BUN_NONE : cnt;
 
   bailout:
@@ -2027,8 +2019,6 @@ SQLload_file(Client cntxt, Tablet *as, b
 #ifdef MLOCK_TST
        munlockall();
 #endif
-       /* restore system setting */
-       GDK_vm_trim = vmtrim;
        return BUN_NONE;
 }
 
diff --git a/tools/mserver/mserver5.1.in b/tools/mserver/mserver5.1.in
--- a/tools/mserver/mserver5.1.in
+++ b/tools/mserver/mserver5.1.in
@@ -112,15 +112,6 @@ The kernel tries to choose the values fo
 Changing these parameters is discouraged.
 .P
 .TP
-.B gdk_vmtrim
-Enable or disable the vmtrim thread which tries to unload memory that
-is not in use.
-Default:
-.B yes
-on 32 bit platforms,
-.B no
-on 64 bit platforms
-.TP
 .B gdk_debug
 You can enable debug output for specific kernel operations.
 By default debug is switched off for obvious reasons.
_______________________________________________
checkin-list mailing list
[email protected]
https://www.monetdb.org/mailman/listinfo/checkin-list

Reply via email to