summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2014-01-06 12:16:36 +0900
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2014-01-06 12:16:36 +0900
commit6f685d760851e1ccf33017b2a749008475e2ac7c (patch)
tree1b8aba1b81e5491b50b0abc2622e27ddad548e69
parenta2d55c2b821dea1f6835ff43bbfe92530923ebda (diff)
fixme notes - fixme: many instances of module loading that bloat our mem
-rw-r--r--src/lib/ecore/ecore.c5
-rw-r--r--src/lib/ecore_imf/ecore_imf_module.c3
-rw-r--r--src/lib/eeze/eeze_sensor.c3
-rw-r--r--src/lib/eina/eina_mempool.c3
-rw-r--r--src/lib/ethumb/ethumb.c5
5 files changed, 19 insertions, 0 deletions
diff --git a/src/lib/ecore/ecore.c b/src/lib/ecore/ecore.c
index 58702060ee..3477aca4ad 100644
--- a/src/lib/ecore/ecore.c
+++ b/src/lib/ecore/ecore.c
@@ -183,6 +183,11 @@ ecore_system_modules_load(void)
183 eina_prefix_lib_get(_ecore_pfx)); 183 eina_prefix_lib_get(_ecore_pfx));
184 module_list = eina_module_arch_list_get(module_list, buf, MODULE_ARCH); 184 module_list = eina_module_arch_list_get(module_list, buf, MODULE_ARCH);
185 185
186 // XXX: MODFIX: do not list ALL modules and load them ALL! this is
187 // just polluting memory pages and I/O with modules and code that
188 // is then never used. detetc the module we need to use them use
189 // that. if anything load each module, have it do a detect and if
190 // it fails UNLOAD and try the next one.
186 eina_module_list_load(module_list); 191 eina_module_list_load(module_list);
187} 192}
188 193
diff --git a/src/lib/ecore_imf/ecore_imf_module.c b/src/lib/ecore_imf/ecore_imf_module.c
index d16ad6e41d..c8e6819898 100644
--- a/src/lib/ecore_imf/ecore_imf_module.c
+++ b/src/lib/ecore_imf/ecore_imf_module.c
@@ -93,6 +93,9 @@ ecore_imf_module_init(void)
93 snprintf(buf, sizeof(buf), "%s/ecore_imf/modules", eina_prefix_lib_get(pfx)); 93 snprintf(buf, sizeof(buf), "%s/ecore_imf/modules", eina_prefix_lib_get(pfx));
94 module_list = eina_module_arch_list_get(module_list, buf, MODULE_ARCH); 94 module_list = eina_module_arch_list_get(module_list, buf, MODULE_ARCH);
95 95
96 // XXX: MODFIX: do not list ALL modules and load them ALL! this is
97 // is wrong - we end up loading BOTH xim ANd scim (and maybe uim too)
98 // etc. etc. when we need only 1!
96 eina_module_list_load(module_list); 99 eina_module_list_load(module_list);
97} 100}
98 101
diff --git a/src/lib/eeze/eeze_sensor.c b/src/lib/eeze/eeze_sensor.c
index 7dee614b62..30c5d3c8e2 100644
--- a/src/lib/eeze/eeze_sensor.c
+++ b/src/lib/eeze/eeze_sensor.c
@@ -107,6 +107,9 @@ eeze_sensor_modules_load(void)
107 ERR("No modules found!"); 107 ERR("No modules found!");
108 return; 108 return;
109 } 109 }
110 // XXX: MODFIX: do not list ALL modules and load them ALL! this is
111 // this will, for example, load both udev AND fake modules - run
112 // their init funcs etc. etc. why? no!
110 eina_module_list_load(g_handle->modules_array); 113 eina_module_list_load(g_handle->modules_array);
111} 114}
112 115
diff --git a/src/lib/eina/eina_mempool.c b/src/lib/eina/eina_mempool.c
index 1757975362..29fc829492 100644
--- a/src/lib/eina/eina_mempool.c
+++ b/src/lib/eina/eina_mempool.c
@@ -200,6 +200,9 @@ eina_mempool_init(void)
200 goto mempool_init_error; 200 goto mempool_init_error;
201 } 201 }
202 202
203 // XXX: MODFIX: do not list ALL modules and load them ALL! this is
204 // wrong. load the module we need WHEN we need it (by name etc. etc.
205 // from api).
203 eina_module_list_load(_modules); 206 eina_module_list_load(_modules);
204 207
205 /* builtin backends */ 208 /* builtin backends */
diff --git a/src/lib/ethumb/ethumb.c b/src/lib/ethumb/ethumb.c
index f1c5466be8..2a97e39bca 100644
--- a/src/lib/ethumb/ethumb.c
+++ b/src/lib/ethumb/ethumb.c
@@ -202,6 +202,11 @@ _ethumb_plugins_load(void)
202 _plugins = eina_module_arch_list_get(_plugins, buf, MODULE_ARCH); 202 _plugins = eina_module_arch_list_get(_plugins, buf, MODULE_ARCH);
203 203
204 load: 204 load:
205 // XXX: MODFIX: do not list ALL modules and load them ALL! this is
206 // wasteful. admittedly this is low priority as we have only 1
207 // module - and that is emotion and ethumbd slaves die off quickly
208 // but we still pay a module load, init func etc. price even if
209 // the code is never needed!
205 if (_plugins) 210 if (_plugins)
206 eina_module_list_load(_plugins); 211 eina_module_list_load(_plugins);
207 212