diff options
Diffstat (limited to 'src/preamble.js')
-rw-r--r-- | src/preamble.js | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/preamble.js b/src/preamble.js index 0124e6c3..505217ab 100644 --- a/src/preamble.js +++ b/src/preamble.js @@ -286,12 +286,11 @@ function __initializeRuntime__() { Module['FHEAP'] = FHEAP; STACK_ROOT = STACKTOP = alignMemoryPage(10); + var totalStack = 1024*1024; // XXX: Changing this value can lead to bad perf on v8! try { - var x = TOTAL_STACK; - } catch(e) { - TOTAL_STACK = 1024*1024; // Reserved room for stack XXX: Changing this value can lead to bad perf on v8! - } - STACK_MAX = STACK_ROOT + TOTAL_STACK; + totalStack = TOTAL_STACK; + } catch(e){} + STACK_MAX = STACK_ROOT + totalStack; STATICTOP = alignMemoryPage(STACK_MAX); } |