Arun 8 anni fa
parent
commit
0291cc247e

+ 0 - 20
lib/Backend/IRBuilderAsmJs.cpp

@@ -4747,27 +4747,7 @@ IRBuilderAsmJs::BuildFloat64x2_2(Js::OpCodeAsmJs newOpcode, uint32 offset, BUILD
     Js::OpCode opcode;
 
     opcode = GetSimdOpcode(newOpcode);
-    /*
-    switch (newOpcode)
-    {
-
-    case Js::OpCodeAsmJs::Simd128_Return_D2:
-    if (m_func->IsLoopBody())
-    {
-    IR::Instr* slotInstr = GenerateStSlotForReturn(src1Opnd, IRType::TySimd128F4);
-    AddInstr(slotInstr, offset);
-    }
-    opcode = Js::OpCode::Ld_A;
-    break;
-    case Js::OpCodeAsmJs::Simd128_Ld_D2:
-    opcode = Js::OpCode::Ld_A; //to make the compiler happy
-    Assert(false); //should be unreachable
-    break;
 
-    default:
-    opcode = GetSimdOpcode(newOpcode);
-    }
-    */
     AssertMsg((uint32)opcode, "Invalid backend SIMD opcode");
 
     IR::Instr * instr = IR::Instr::New(opcode, dstOpnd, src1Opnd, m_func);

+ 1 - 1
lib/Common/ConfigFlagsList.h

@@ -897,7 +897,7 @@ FLAGNR(Boolean, WasmIgnoreResponse    , "Ignore the type of the Response object"
 FLAGNR(Number,  WasmMaxTableSize      , "Maximum size allowed to the WebAssembly.Table", DEFAULT_CONFIG_WasmMaxTableSize)
 FLAGNR(Boolean, WasmSignExtends       , "Use new WebAssembly sign extension operators", DEFAULT_CONFIG_WasmSignExtends)
 #ifdef ENABLE_WASM_SIMD
-FLAGR(Boolean, WasmSimd, "Enable SIMD in WebAssembly", DEFAULT_CONFIG_WasmSimd)
+FLAGNR(Boolean, WasmSimd              , "Enable SIMD in WebAssembly", DEFAULT_CONFIG_WasmSimd)
 #endif
 
 #ifdef ENABLE_SIMDJS

+ 0 - 4
lib/Runtime/Base/ThreadConfigFlagsList.h

@@ -56,7 +56,3 @@ FLAG_RELEASE(IsWinRTAdaptiveAppsEnabled, WinRTAdaptiveApps)
 //SIMD_JS
 FLAG_RELEASE(IsSimdjsEnabled, Simdjs)
 #endif
-
-#ifdef ENABLE_WASM_SIMD
-FLAG_RELEASE(IsWasmSimdEnabled, WasmSimd)
-#endif

+ 0 - 1
lib/Runtime/ByteCode/OpCodesAsmJs.h

@@ -334,7 +334,6 @@ MACRO_EXTEND_WMS( PrintF64, Double2, None)
 
 #include "OpCodesSimd.h"
 
-MACRO_EXTEND(AsmJsEntryTracing, Empty, None)
 // help the caller to undefine all the macros
 #undef MACRO
 #undef MACRO_WMS

+ 3 - 3
lib/Runtime/Language/InterpreterStackFrame.cpp

@@ -2081,7 +2081,7 @@ namespace Js
 #if defined(ENABLE_WASM_SIMD) || defined(ENABLE_SIMDJS)
 
 #ifdef ENABLE_WASM_SIMD
-            if (function->GetScriptContext()->GetConfig()->IsWasmSimdEnabled())
+            if (CONFIG_FLAG(WasmSimd))
 #elif ENABLE_SIMDJS
             if (function->GetScriptContext()->GetConfig()->IsSimdjsEnabled())
 #endif
@@ -3126,7 +3126,7 @@ namespace Js
 #endif
 
 #ifdef ENABLE_WASM_SIMD
-                if (scriptContext->GetConfig()->IsWasmSimdEnabled() && i == 2) // last argument ?
+                if (CONFIG_FLAG(WasmSimd) && i == 2) // last argument ?
 #endif
 
 #if defined(ENABLE_SIMDJS) || defined(ENABLE_WASM_SIMD)
@@ -3198,7 +3198,7 @@ namespace Js
 #endif
 
 #ifdef ENABLE_WASM_SIMD
-            else if (scriptContext->GetConfig()->IsWasmSimdEnabled() && info->GetArgType(i).isSIMD())
+            else if (CONFIG_FLAG(WasmSimd) && info->GetArgType(i).isSIMD())
 #endif
 
 #if defined(ENABLE_SIMDJS) || defined(ENABLE_WASM_SIMD)

+ 3 - 3
lib/Runtime/Language/SimdInt64x2Operation.h

@@ -13,9 +13,9 @@ namespace Js {
         static SIMDValue OpSub(const SIMDValue& a, const SIMDValue& b);
         static SIMDValue OpNeg(const SIMDValue& a);
 
-        //pointer-based arguments are used to ensure that calling conventions are consistent across x86/x64
-        //and match call sequences JIT generates.
-        //TODO: nikolayk back to "const SIMDValue& a"
+        //These are directly called into from JIT as of now. Pointer-based arguments are used to ensure 
+        //that calling conventions are consistent across x86/x64 and match call sequences JIT generates.
+        //TODO: Change back to "const SIMDValue& a" after getting rid of the jit helpers.
         template<typename T> static void OpTrunc(SIMDValue* dst, SIMDValue* src);
         static void OpShiftLeftByScalar(SIMDValue* dst, SIMDValue* src, int count);
         static void OpShiftRightByScalar(SIMDValue* dst, SIMDValue* src, int count);