aboutsummaryrefslogtreecommitdiff
path: root/src/preamble.js
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2013-09-13 16:15:15 -0700
committerAlon Zakai <alonzakai@gmail.com>2013-09-13 16:15:15 -0700
commit73579052dae38b12067b350be0a11a74090d0dfe (patch)
treec23d4dd6c83ed67c4878385460732f395646ec22 /src/preamble.js
parent1fc6762e3176843ffc378c8b4f43dd73fed25ebe (diff)
refactor memory initializer code to use run dependenciesfailure
Diffstat (limited to 'src/preamble.js')
-rw-r--r--src/preamble.js23
1 files changed, 1 insertions, 22 deletions
diff --git a/src/preamble.js b/src/preamble.js
index 579e3065..02935f8f 100644
--- a/src/preamble.js
+++ b/src/preamble.js
@@ -1020,28 +1020,7 @@ __ATEXIT__.push({ func: function() { PGOMonitor.dump() } });
addOnPreRun(function() { addRunDependency('pgo') });
#endif
-function loadMemoryInitializer(filename) {
- function applyData(data) {
-#if USE_TYPED_ARRAYS == 2
- HEAPU8.set(data, STATIC_BASE);
-#else
- allocate(data, 'i8', ALLOC_NONE, STATIC_BASE);
-#endif
- }
-
- // always do this asynchronously, to keep shell and web as similar as possible
- addOnPreRun(function() {
- if (ENVIRONMENT_IS_NODE || ENVIRONMENT_IS_SHELL) {
- applyData(Module['readBinary'](filename));
- } else {
- Browser.asyncLoad(filename, function(data) {
- applyData(data);
- }, function(data) {
- throw 'could not load memory initializer ' + filename;
- });
- }
- });
-}
+var memoryInitializer = null;
// === Body ===