diff --git a/ecmascript/ecma_vm.cpp b/ecmascript/ecma_vm.cpp index 60469a74..4655b3cf 100644 --- a/ecmascript/ecma_vm.cpp +++ b/ecmascript/ecma_vm.cpp @@ -79,7 +79,12 @@ namespace panda::ecmascript { /* static */ EcmaVM *EcmaVM::Create(const JSRuntimeOptions &options, EcmaParamConfiguration &config) { - auto vm = new EcmaVM(options, config); + JSRuntimeOptions newOptions = options; + // windows or mac disable asm interpreter and use c interpreter +#if defined(PANDA_TARGET_WINDOWS) || defined(PANDA_TARGET_MACOS) + newOptions.SetEnableAsmInterpreter(false); +#endif + auto vm = new EcmaVM(newOptions, config); if (UNLIKELY(vm == nullptr)) { LOG_ECMA(ERROR) << "Failed to create jsvm"; return nullptr;