aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2014-01-07 17:52:36 -0800
committerAlon Zakai <alonzakai@gmail.com>2014-01-07 17:52:49 -0800
commit9ca7d4129ee227ffdb3e53b0bda94e424e19ab18 (patch)
tree2aa47d9cac949872df2e44db0a6dfdb66957c4b9
parent3bb84257eac6bcf74e80dab5559fdc436773ccd6 (diff)
notice simd signal from fastcomp
-rwxr-xr-xemscripten.py3
-rw-r--r--src/jsifier.js2
2 files changed, 4 insertions, 1 deletions
diff --git a/emscripten.py b/emscripten.py
index 42db0803..1a3bddd7 100755
--- a/emscripten.py
+++ b/emscripten.py
@@ -804,6 +804,9 @@ def emscript_fast(infile, settings, outfile, libraries=[], compiler_engine=None,
map(lambda x: x[1:], metadata['implementedFunctions'])
)
) + map(lambda x: x[1:], metadata['externs'])
+ if metadata['simd']:
+ settings['SIMD'] = 1
+ settings['ASM_JS'] = 2
# Save settings to a file to work around v8 issue 1579
settings_file = temp_files.get('.txt').name
diff --git a/src/jsifier.js b/src/jsifier.js
index 8de20c80..a503e90d 100644
--- a/src/jsifier.js
+++ b/src/jsifier.js
@@ -1871,7 +1871,7 @@ function JSify(data, functionsOnly) {
print('// Warning: printing of i64 values may be slightly rounded! No deep i64 math used, so precise i64 code not included');
print('var i64Math = null;');
}
- if (Types.usesSIMD) {
+ if (Types.usesSIMD || SIMD) {
print(read('simd.js'));
}