Skip to content

Latest commit

 

History

History
72 lines (42 loc) · 3.22 KB

conditional.md

File metadata and controls

72 lines (42 loc) · 3.22 KB

Darwin x64 - 13.3.0

nodememorycpu
v0.10.298.59 GBIntel(R) Core(TM) i5-2500S CPU @ 2.70GHz

Benchmark Results

if else13,533,087 ops/sec ±11.50% (33 runs sampled)
switch5,858,068 ops/sec ±11.01% (31 runs sampled)
lookup table11,290,067 ops/sec ±10.24% (41 runs sampled)

Notes:

  • Fastest is if else

Linux x64 - 3.8.4-1-ARCH

nodememorycpu
v0.10.30519 MBQEMU Virtual CPU version 1.0

Benchmark Results

if else1,096,334 ops/sec ±5.38% (59 runs sampled)
switch468,797 ops/sec ±13.07% (60 runs sampled)
lookup table1,234,662 ops/sec ±4.67% (25 runs sampled)

Notes:

  • Fastest is lookup table

Linux x64 - 3.13.0-34-generic

nodememorycpu
v0.10.298.30 GBIntel(R) Core(TM) i5-4200M CPU @ 2.50GHz

Benchmark Results

if else8,652,776 ops/sec ±15.31% (28 runs sampled)
switch3,515,121 ops/sec ±13.77% (25 runs sampled)
lookup table9,019,769 ops/sec ±15.23% (31 runs sampled)

Notes:

  • Fastest is lookup table,if else

Darwin x64 - 13.2.0

nodememorycpu
v0.11.134.29 GBIntel(R) Core(TM) i7-3615QM CPU @ 2.30GHz

Benchmark Results

if else31,263,817 ops/sec ±11.10% (45 runs sampled)
switch32,227,559 ops/sec ±9.25% (42 runs sampled)
lookup table17,833,511 ops/sec ±7.22% (53 runs sampled)

Notes:

  • Fastest is switch,if else

Darwin x64 - 13.3.0

nodememorycpu
v0.11.138.59 GBIntel(R) Core(TM) i5-2500S CPU @ 2.70GHz

Benchmark Results

if else18,819,577 ops/sec ±11.12% (25 runs sampled)
switch19,971,338 ops/sec ±12.56% (26 runs sampled)
lookup table10,489,793 ops/sec ±11.43% (34 runs sampled)

Notes:

  • Fastest is switch,if else

Darwin x64 - 13.3.0

nodememorycpu
v0.10.318.59 GBIntel(R) Core(TM) i5-2500S CPU @ 2.70GHz

Benchmark Results

if else14,418,388 ops/sec ±20.75% (30 runs sampled)
switch5,415,693 ops/sec ±19.19% (27 runs sampled)
lookup table9,930,633 ops/sec ±15.73% (35 runs sampled)

Notes:

  • Fastest is if else