-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bespoke handling of object types to reduce work
- Loading branch information
1 parent
e426cc4
commit b24c75d
Showing
3 changed files
with
126 additions
and
117 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,188 +1,188 @@ | ||
Benchmark cycles: 1,000 5,000 10,000 50,000 100,000 500,000 1,000,000 5,000,000 | ||
|
||
Boolean: | ||
1,000: 0.001 sec | ||
5,000: 0.001 sec | ||
1,000: 0 sec | ||
5,000: 0.002 sec | ||
10,000: 0.001 sec | ||
50,000: 0.003 sec | ||
50,000: 0.002 sec | ||
100,000: 0.002 sec | ||
500,000: 0.01 sec | ||
1,000,000: 0.021 sec | ||
5,000,000: 0.106 sec | ||
Average: 45,972,414 ops/sec | ||
500,000: 0.008 sec | ||
1,000,000: 0.016 sec | ||
5,000,000: 0.082 sec | ||
Average: 58,991,150 ops/sec | ||
|
||
Infinity: | ||
1,000: 0.001 sec | ||
1,000: 0 sec | ||
5,000: 0.001 sec | ||
10,000: 0.001 sec | ||
50,000: 0.003 sec | ||
100,000: 0.004 sec | ||
500,000: 0.02 sec | ||
1,000,000: 0.039 sec | ||
5,000,000: 0.196 sec | ||
Average: 25,154,717 ops/sec | ||
100,000: 0.003 sec | ||
500,000: 0.016 sec | ||
1,000,000: 0.03 sec | ||
5,000,000: 0.151 sec | ||
Average: 32,517,073 ops/sec | ||
|
||
NaN: | ||
1,000: 0 sec | ||
5,000: 0 sec | ||
10,000: 0 sec | ||
10,000: 0.001 sec | ||
50,000: 0.001 sec | ||
100,000: 0.003 sec | ||
500,000: 0.013 sec | ||
1,000,000: 0.027 sec | ||
5,000,000: 0.135 sec | ||
Average: 37,240,223 ops/sec | ||
100,000: 0.002 sec | ||
500,000: 0.01 sec | ||
1,000,000: 0.021 sec | ||
5,000,000: 0.104 sec | ||
Average: 47,956,835 ops/sec | ||
|
||
null: | ||
1,000: 0 sec | ||
1,000: 0.001 sec | ||
5,000: 0 sec | ||
10,000: 0 sec | ||
50,000: 0.002 sec | ||
10,000: 0.001 sec | ||
50,000: 0.003 sec | ||
100,000: 0.002 sec | ||
500,000: 0.014 sec | ||
1,000,000: 0.028 sec | ||
5,000,000: 0.139 sec | ||
Average: 36,032,432 ops/sec | ||
500,000: 0.01 sec | ||
1,000,000: 0.021 sec | ||
5,000,000: 0.103 sec | ||
Average: 47,276,596 ops/sec | ||
|
||
Number: | ||
1,000: 0 sec | ||
5,000: 0 sec | ||
10,000: 0 sec | ||
50,000: 0.002 sec | ||
50,000: 0.001 sec | ||
100,000: 0.002 sec | ||
500,000: 0.013 sec | ||
1,000,000: 0.026 sec | ||
5,000,000: 0.129 sec | ||
Average: 38,755,814 ops/sec | ||
500,000: 0.01 sec | ||
1,000,000: 0.02 sec | ||
5,000,000: 0.1 sec | ||
Average: 50,120,301 ops/sec | ||
|
||
String: | ||
1,000: 0 sec | ||
5,000: 0 sec | ||
5,000: 0.001 sec | ||
10,000: 0.001 sec | ||
50,000: 0.001 sec | ||
100,000: 0.002 sec | ||
50,000: 0.002 sec | ||
100,000: 0.003 sec | ||
500,000: 0.01 sec | ||
1,000,000: 0.021 sec | ||
5,000,000: 0.104 sec | ||
Average: 47,956,835 ops/sec | ||
1,000,000: 0.02 sec | ||
5,000,000: 0.103 sec | ||
Average: 47,614,286 ops/sec | ||
|
||
undefined: | ||
1,000: 0 sec | ||
5,000: 0 sec | ||
10,000: 0 sec | ||
50,000: 0.002 sec | ||
10,000: 0.001 sec | ||
50,000: 0.001 sec | ||
100,000: 0.004 sec | ||
500,000: 0.018 sec | ||
1,000,000: 0.037 sec | ||
5,000,000: 0.18 sec | ||
Average: 27,659,751 ops/sec | ||
500,000: 0.016 sec | ||
1,000,000: 0.033 sec | ||
5,000,000: 0.163 sec | ||
Average: 30,577,982 ops/sec | ||
|
||
Function: | ||
1,000: 0.001 sec | ||
1,000: 0 sec | ||
5,000: 0.001 sec | ||
10,000: 0.002 sec | ||
50,000: 0.008 sec | ||
100,000: 0.016 sec | ||
500,000: 0.081 sec | ||
1,000,000: 0.158 sec | ||
5,000,000: 0.805 sec | ||
Average: 6,218,284 ops/sec | ||
50,000: 0.007 sec | ||
100,000: 0.015 sec | ||
500,000: 0.073 sec | ||
1,000,000: 0.146 sec | ||
5,000,000: 0.728 sec | ||
Average: 6,858,025 ops/sec | ||
|
||
RegExp: | ||
1,000: 0.001 sec | ||
5,000: 0.003 sec | ||
5,000: 0.002 sec | ||
10,000: 0.006 sec | ||
50,000: 0.015 sec | ||
100,000: 0.03 sec | ||
500,000: 0.149 sec | ||
1,000,000: 0.297 sec | ||
5,000,000: 1.488 sec | ||
Average: 3,351,433 ops/sec | ||
500,000: 0.146 sec | ||
1,000,000: 0.294 sec | ||
5,000,000: 1.468 sec | ||
Average: 3,397,554 ops/sec | ||
|
||
Array: | ||
1,000: 0.002 sec | ||
5,000: 0.006 sec | ||
10,000: 0.009 sec | ||
50,000: 0.035 sec | ||
100,000: 0.068 sec | ||
500,000: 0.34 sec | ||
1,000,000: 0.673 sec | ||
1,000: 0.003 sec | ||
5,000: 0.005 sec | ||
10,000: 0.012 sec | ||
50,000: 0.036 sec | ||
100,000: 0.074 sec | ||
500,000: 0.367 sec | ||
1,000,000: 0.699 sec | ||
5,000,000: 3.331 sec | ||
Average: 1,493,280 ops/sec | ||
Average: 1,472,498 ops/sec | ||
|
||
Date: | ||
1,000: 0 sec | ||
5,000: 0.002 sec | ||
10,000: 0.002 sec | ||
5,000: 0.001 sec | ||
10,000: 0.003 sec | ||
50,000: 0.01 sec | ||
100,000: 0.015 sec | ||
500,000: 0.074 sec | ||
1,000,000: 0.147 sec | ||
5,000,000: 0.735 sec | ||
Average: 6,767,513 ops/sec | ||
100,000: 0.014 sec | ||
500,000: 0.072 sec | ||
1,000,000: 0.144 sec | ||
5,000,000: 0.718 sec | ||
Average: 6,929,314 ops/sec | ||
|
||
Error: | ||
1,000: 0.001 sec | ||
5,000: 0.005 sec | ||
10,000: 0.013 sec | ||
50,000: 0.052 sec | ||
100,000: 0.102 sec | ||
500,000: 0.498 sec | ||
1,000,000: 1.017 sec | ||
5,000,000: 4.996 sec | ||
Average: 997,307 ops/sec | ||
50,000: 0.049 sec | ||
100,000: 0.097 sec | ||
500,000: 0.483 sec | ||
1,000,000: 0.966 sec | ||
5,000,000: 4.899 sec | ||
Average: 1,023,491 ops/sec | ||
|
||
Event: | ||
1,000: 0.002 sec | ||
5,000: 0.005 sec | ||
10,000: 0.009 sec | ||
50,000: 0.029 sec | ||
5,000: 0.006 sec | ||
10,000: 0.008 sec | ||
50,000: 0.03 sec | ||
100,000: 0.059 sec | ||
500,000: 0.293 sec | ||
1,000,000: 0.586 sec | ||
5,000,000: 2.935 sec | ||
Average: 1,701,378 ops/sec | ||
500,000: 0.291 sec | ||
1,000,000: 0.582 sec | ||
5,000,000: 2.913 sec | ||
Average: 1,713,184 ops/sec | ||
|
||
Map: | ||
1,000: 0.002 sec | ||
5,000: 0.007 sec | ||
10,000: 0.007 sec | ||
50,000: 0.031 sec | ||
100,000: 0.061 sec | ||
500,000: 0.308 sec | ||
1,000,000: 0.613 sec | ||
5,000,000: 3.083 sec | ||
Average: 1,621,109 ops/sec | ||
1,000: 0.001 sec | ||
5,000: 0.006 sec | ||
10,000: 0.006 sec | ||
50,000: 0.03 sec | ||
100,000: 0.06 sec | ||
500,000: 0.298 sec | ||
1,000,000: 0.596 sec | ||
5,000,000: 2.983 sec | ||
Average: 1,674,874 ops/sec | ||
|
||
Object: | ||
1,000: 0.003 sec | ||
5,000: 0.007 sec | ||
10,000: 0.011 sec | ||
50,000: 0.056 sec | ||
100,000: 0.11 sec | ||
500,000: 0.549 sec | ||
1,000,000: 1.095 sec | ||
5,000,000: 5.478 sec | ||
Average: 912,026 ops/sec | ||
50,000: 0.055 sec | ||
100,000: 0.105 sec | ||
500,000: 0.525 sec | ||
1,000,000: 1.051 sec | ||
5,000,000: 5.246 sec | ||
Average: 951,878 ops/sec | ||
|
||
Object (circular): | ||
1,000: 0.001 sec | ||
1,000: 0.002 sec | ||
5,000: 0.007 sec | ||
10,000: 0.011 sec | ||
50,000: 0.053 sec | ||
10,000: 0.01 sec | ||
50,000: 0.052 sec | ||
100,000: 0.1 sec | ||
500,000: 0.504 sec | ||
1,000,000: 1.009 sec | ||
5,000,000: 5.032 sec | ||
Average: 992,407 ops/sec | ||
500,000: 0.497 sec | ||
1,000,000: 0.994 sec | ||
5,000,000: 4.984 sec | ||
Average: 1,003,009 ops/sec | ||
|
||
Set: | ||
1,000: 0.001 sec | ||
5,000: 0.006 sec | ||
10,000: 0.006 sec | ||
50,000: 0.028 sec | ||
10,000: 0.007 sec | ||
50,000: 0.027 sec | ||
100,000: 0.056 sec | ||
500,000: 0.279 sec | ||
1,000,000: 0.559 sec | ||
5,000,000: 2.798 sec | ||
Average: 1,785,695 ops/sec | ||
500,000: 0.275 sec | ||
1,000,000: 0.549 sec | ||
5,000,000: 2.749 sec | ||
Average: 1,816,349 ops/sec |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters