Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/107.0.0.0 Safari/537.36
Chrome 107
Windows
Desktop
one year ago
Test name Executions per second
if else if 306797.3 Ops/sec
if else 6371708.5 Ops/sec
if if 6402072.5 Ops/sec
switch case 336063.4 Ops/sec
indexOf 319669.8 Ops/sec
if != && 298621.7 Ops/sec
if == && 335042.1 Ops/sec
if != || 334464.8 Ops/sec
if || 310129.2 Ops/sec
if if if ... 300374.9 Ops/sec
Script Preparation code:
Tests:
  • if else if

  • if else

  • if if

  • switch case

  • indexOf

  • if != &&

  • if == &&

  • if != ||

  • if ||

  • if if if ...


;