Skip to content

Commit 64e5d07

Browse files
committed
Added a benchmarks for MSIE JavaScript Engine's modes
1 parent 4715174 commit 64e5d07

File tree

1 file changed

+34
-1
lines changed

1 file changed

+34
-1
lines changed

test/JavaScriptEngineSwitcher.Benchmarks/JsExecutionBenchmark.cs

Lines changed: 34 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,18 +206,51 @@ public void Jurassic(bool withPrecompilation)
206206
Func<IJsEngine> createJsEngine = () => new JurassicJsEngine();
207207
TransliterateStrings(createJsEngine, withPrecompilation);
208208
}
209+
#if NET46
210+
211+
[Benchmark]
212+
public void MsieClassic()
213+
{
214+
Func<IJsEngine> createJsEngine = () => new MsieJsEngine(new MsieSettings
215+
{
216+
EngineMode = JsEngineMode.Classic
217+
});
218+
TransliterateStrings(createJsEngine, false);
219+
}
209220

221+
[Benchmark]
222+
public void MsieChakraActiveScript()
223+
{
224+
Func<IJsEngine> createJsEngine = () => new MsieJsEngine(new MsieSettings
225+
{
226+
EngineMode = JsEngineMode.ChakraActiveScript
227+
});
228+
TransliterateStrings(createJsEngine, false);
229+
}
230+
#endif
210231
[Benchmark]
211232
[Arguments(false)]
212233
[Arguments(true)]
213-
public void Msie(bool withPrecompilation)
234+
public void MsieChakraIeJsRt(bool withPrecompilation)
214235
{
215236
Func<IJsEngine> createJsEngine = () => new MsieJsEngine(new MsieSettings {
216237
EngineMode = JsEngineMode.ChakraIeJsRt
217238
});
218239
TransliterateStrings(createJsEngine, withPrecompilation);
219240
}
220241

242+
[Benchmark]
243+
[Arguments(false)]
244+
[Arguments(true)]
245+
public void MsieChakraEdgeJsRt(bool withPrecompilation)
246+
{
247+
Func<IJsEngine> createJsEngine = () => new MsieJsEngine(new MsieSettings
248+
{
249+
EngineMode = JsEngineMode.ChakraEdgeJsRt
250+
});
251+
TransliterateStrings(createJsEngine, withPrecompilation);
252+
}
253+
221254
[Benchmark]
222255
public void NiL()
223256
{

0 commit comments

Comments
 (0)