aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2011-12-07 14:27:39 -0800
committerAlon Zakai <alonzakai@gmail.com>2011-12-07 14:27:39 -0800
commit02b8a149f5e501c54a90b525099de19a45b3be5b (patch)
tree1b2c47aa31bfe450f434b60321b7ba02e07c6783 /src
parentd4277c2123c23908c263de00d5797c3873ad1e89 (diff)
comment
Diffstat (limited to 'src')
-rw-r--r--src/settings.js4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/settings.js b/src/settings.js
index 2d645a12..84b68b54 100644
--- a/src/settings.js
+++ b/src/settings.js
@@ -65,6 +65,10 @@ var DOUBLE_MODE = 1; // How to load and store 64-bit doubles. Without typed arra
// 0 we will simply store and load doubles as 32-bit floats, so when they are stored/loaded
// they will truncate from 64 to 32 bits, and lose precision. This is faster, and might
// work for some code (but probably that code should just use floats and not doubles anyhow).
+ // Note that a downside of DOUBLE_MODE 1 is that we currently store the double in parts,
+ // then load it aligned, and that load-store will make JS engines alter it if it is being
+ // stored to a typed array for security reasons. That will 'fix' the number from being a
+ // NaN or an infinite number.
var EMULATE_UNALIGNED_ACCESSES = 1; // If set, the compiler will 'emulate' loads and stores that are not known to
// be sufficiently aligned, by working on individual bytes. This can be
// important in USE_TYPED_ARRAYS == 2, where unaligned accesses do not work,