From 361a027ec9a0091a0bf461e6bda77eab9cb5a79c Mon Sep 17 00:00:00 2001 From: nlewycky Date: Wed, 24 Jul 2019 14:10:09 -0700 Subject: [PATCH] Only enable SIMD when using the LLVM backend. Co-Authored-By: Syrus Akbary --- src/bin/wasmer.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/bin/wasmer.rs b/src/bin/wasmer.rs index b1d414077..2f24548e3 100644 --- a/src/bin/wasmer.rs +++ b/src/bin/wasmer.rs @@ -317,7 +317,10 @@ fn execute_wasm(options: &Run) -> Result<(), String> { if !utils::is_wasm_binary(&wasm_binary) { let mut features = wabt::Features::new(); - features.enable_simd(); + if options.backend == Backend::LLVM { + // SIMD is only supported in the LLVM backend for now + features.enable_simd(); + } wasm_binary = wabt::wat2wasm_with_features(wasm_binary, features) .map_err(|e| format!("Can't convert from wast to wasm: {:?}", e))?; }