diff options
author | Alon Zakai <alonzakai@gmail.com> | 2012-11-28 18:45:50 -0800 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2012-12-07 14:23:19 -0800 |
commit | b5fbdf8a71688fe65f260e99caa1308146db549a (patch) | |
tree | fb3f2d0691256e4f177dffc9cfa4ac1415dd8443 /src/compiler.js | |
parent | edfa19745e86763db4574ccb9fc73f5ecfaadecb (diff) |
default heap to 16MB, and make sure asm.js heaps are power-of-two
Diffstat (limited to 'src/compiler.js')
-rw-r--r-- | src/compiler.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/compiler.js b/src/compiler.js index 05a03ffb..96784cf3 100644 --- a/src/compiler.js +++ b/src/compiler.js @@ -172,7 +172,10 @@ RUNTIME_DEBUG = LIBRARY_DEBUG || GL_DEBUG; // Settings sanity checks assert(!(USE_TYPED_ARRAYS === 2 && QUANTUM_SIZE !== 4), 'For USE_TYPED_ARRAYS == 2, must have normal QUANTUM_SIZE of 4'); -assert(!(ASM_JS && ALLOW_MEMORY_GROWTH), 'Cannot grow asm.js heap'); +if (ASM_JS) { + assert(!ALLOW_MEMORY_GROWTH, 'Cannot grow asm.js heap'); + assert((TOTAL_MEMORY&(TOTAL_MEMORY-1)) == 0, 'asm.js heap must be power of 2'); +} // Output some info and warnings based on settings |