data-structure-typed 1.50.4 → 1.50.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +1 -1
- package/README.md +116 -55
- package/SPECIFICATION.md +2 -2
- package/SPECIFICATION_zh-CN.md +81 -0
- package/{SPONSOR-zh-CN.md → SPONSOR_zh-CN.md} +1 -1
- package/benchmark/report.html +24 -24
- package/benchmark/report.json +261 -237
- package/dist/cjs/data-structures/base/iterable-base.d.ts +10 -8
- package/dist/cjs/data-structures/base/iterable-base.js +8 -12
- package/dist/cjs/data-structures/base/iterable-base.js.map +1 -1
- package/dist/cjs/data-structures/binary-tree/binary-tree.js +19 -19
- package/dist/cjs/data-structures/binary-tree/binary-tree.js.map +1 -1
- package/dist/cjs/data-structures/binary-tree/rb-tree.d.ts +158 -135
- package/dist/cjs/data-structures/binary-tree/rb-tree.js +415 -386
- package/dist/cjs/data-structures/binary-tree/rb-tree.js.map +1 -1
- package/dist/cjs/data-structures/binary-tree/tree-multi-map.d.ts +1 -0
- package/dist/cjs/data-structures/binary-tree/tree-multi-map.js +84 -76
- package/dist/cjs/data-structures/binary-tree/tree-multi-map.js.map +1 -1
- package/dist/cjs/data-structures/graph/abstract-graph.d.ts +1 -0
- package/dist/cjs/data-structures/graph/abstract-graph.js +3 -0
- package/dist/cjs/data-structures/graph/abstract-graph.js.map +1 -1
- package/dist/cjs/data-structures/heap/heap.js.map +1 -1
- package/dist/cjs/data-structures/linked-list/doubly-linked-list.d.ts +14 -76
- package/dist/cjs/data-structures/linked-list/doubly-linked-list.js +16 -86
- package/dist/cjs/data-structures/linked-list/doubly-linked-list.js.map +1 -1
- package/dist/cjs/data-structures/linked-list/singly-linked-list.d.ts +27 -69
- package/dist/cjs/data-structures/linked-list/singly-linked-list.js +35 -79
- package/dist/cjs/data-structures/linked-list/singly-linked-list.js.map +1 -1
- package/dist/cjs/data-structures/queue/deque.d.ts +0 -53
- package/dist/cjs/data-structures/queue/deque.js +0 -61
- package/dist/cjs/data-structures/queue/deque.js.map +1 -1
- package/dist/cjs/data-structures/queue/queue.d.ts +0 -70
- package/dist/cjs/data-structures/queue/queue.js +0 -87
- package/dist/cjs/data-structures/queue/queue.js.map +1 -1
- package/dist/mjs/data-structures/base/iterable-base.d.ts +10 -8
- package/dist/mjs/data-structures/base/iterable-base.js +8 -12
- package/dist/mjs/data-structures/binary-tree/binary-tree.js +19 -19
- package/dist/mjs/data-structures/binary-tree/rb-tree.d.ts +158 -135
- package/dist/mjs/data-structures/binary-tree/rb-tree.js +412 -386
- package/dist/mjs/data-structures/binary-tree/tree-multi-map.d.ts +1 -0
- package/dist/mjs/data-structures/binary-tree/tree-multi-map.js +84 -76
- package/dist/mjs/data-structures/graph/abstract-graph.d.ts +1 -0
- package/dist/mjs/data-structures/graph/abstract-graph.js +3 -0
- package/dist/mjs/data-structures/linked-list/doubly-linked-list.d.ts +14 -76
- package/dist/mjs/data-structures/linked-list/doubly-linked-list.js +16 -86
- package/dist/mjs/data-structures/linked-list/singly-linked-list.d.ts +27 -69
- package/dist/mjs/data-structures/linked-list/singly-linked-list.js +33 -79
- package/dist/mjs/data-structures/queue/deque.d.ts +0 -53
- package/dist/mjs/data-structures/queue/deque.js +0 -61
- package/dist/mjs/data-structures/queue/queue.d.ts +0 -70
- package/dist/mjs/data-structures/queue/queue.js +0 -86
- package/dist/umd/data-structure-typed.js +539 -756
- package/dist/umd/data-structure-typed.min.js +2 -2
- package/dist/umd/data-structure-typed.min.js.map +1 -1
- package/package.json +1 -1
- package/src/data-structures/base/iterable-base.ts +14 -10
- package/src/data-structures/binary-tree/binary-tree.ts +19 -19
- package/src/data-structures/binary-tree/rb-tree.ts +437 -395
- package/src/data-structures/binary-tree/tree-multi-map.ts +85 -82
- package/src/data-structures/graph/abstract-graph.ts +4 -0
- package/src/data-structures/heap/heap.ts +1 -1
- package/src/data-structures/linked-list/doubly-linked-list.ts +16 -94
- package/src/data-structures/linked-list/singly-linked-list.ts +35 -87
- package/src/data-structures/queue/deque.ts +0 -67
- package/src/data-structures/queue/queue.ts +0 -98
- package/test/performance/data-structures/binary-tree/avl-tree.test.ts +3 -3
- package/test/performance/data-structures/binary-tree/binary-tree-overall.test.ts +3 -3
- package/test/performance/data-structures/binary-tree/rb-tree.test.ts +26 -16
- package/test/performance/data-structures/hash/hash-map.test.ts +6 -6
- package/test/performance/data-structures/heap/heap.test.ts +14 -14
- package/test/performance/data-structures/priority-queue/priority-queue.test.ts +11 -6
- package/test/performance/data-structures/queue/deque.test.ts +8 -8
- package/test/performance/data-structures/queue/queue.test.ts +5 -12
- package/test/performance/reportor.ts +43 -1
- package/test/unit/data-structures/binary-tree/overall.test.ts +23 -21
- package/test/unit/data-structures/binary-tree/rb-tree.test.ts +168 -105
- package/test/unit/data-structures/binary-tree/tree-multi-map.test.ts +311 -192
- package/test/unit/data-structures/linked-list/doubly-linked-list.test.ts +6 -6
- package/test/unit/data-structures/linked-list/singly-linked-list.test.ts +10 -10
- package/test/unit/data-structures/linked-list/skip-list.test.ts +4 -4
- package/test/unit/data-structures/queue/deque.test.ts +26 -26
- package/test/unit/data-structures/queue/queue.test.ts +20 -20
package/benchmark/report.json
CHANGED
|
@@ -1,391 +1,415 @@
|
|
|
1
1
|
{
|
|
2
|
-
"
|
|
2
|
+
"heap": {
|
|
3
3
|
"benchmarks": [
|
|
4
4
|
{
|
|
5
|
-
"test name": "
|
|
6
|
-
"time taken (ms)": "
|
|
7
|
-
"executions per sec": "
|
|
8
|
-
"sample deviation": "
|
|
5
|
+
"test name": "100,000 add",
|
|
6
|
+
"time taken (ms)": "6.42",
|
|
7
|
+
"executions per sec": "155.87",
|
|
8
|
+
"sample deviation": "1.90e-4"
|
|
9
9
|
},
|
|
10
10
|
{
|
|
11
|
-
"test name": "
|
|
12
|
-
"time taken (ms)": "
|
|
13
|
-
"executions per sec": "
|
|
14
|
-
"sample deviation": "
|
|
15
|
-
}
|
|
11
|
+
"test name": "100,000 add & poll",
|
|
12
|
+
"time taken (ms)": "31.50",
|
|
13
|
+
"executions per sec": "31.74",
|
|
14
|
+
"sample deviation": "8.72e-4"
|
|
15
|
+
}
|
|
16
|
+
],
|
|
17
|
+
"testName": "heap"
|
|
18
|
+
},
|
|
19
|
+
"rb-tree": {
|
|
20
|
+
"benchmarks": [
|
|
16
21
|
{
|
|
17
|
-
"test name": "
|
|
18
|
-
"time taken (ms)": "
|
|
19
|
-
"executions per sec": "
|
|
22
|
+
"test name": "100,000 add orderly",
|
|
23
|
+
"time taken (ms)": "42.46",
|
|
24
|
+
"executions per sec": "23.55",
|
|
20
25
|
"sample deviation": "0.01"
|
|
21
26
|
},
|
|
22
27
|
{
|
|
23
|
-
"test name": "
|
|
24
|
-
"time taken (ms)": "
|
|
25
|
-
"executions per sec": "
|
|
28
|
+
"test name": "100,000 delete orderly",
|
|
29
|
+
"time taken (ms)": "176.04",
|
|
30
|
+
"executions per sec": "5.68",
|
|
26
31
|
"sample deviation": "0.01"
|
|
27
|
-
}
|
|
28
|
-
],
|
|
29
|
-
"testName": "avl-tree"
|
|
30
|
-
},
|
|
31
|
-
"binary-tree-overall": {
|
|
32
|
-
"benchmarks": [
|
|
32
|
+
},
|
|
33
33
|
{
|
|
34
|
-
"test name": "
|
|
35
|
-
"time taken (ms)": "
|
|
36
|
-
"executions per sec": "
|
|
34
|
+
"test name": "100,000 add randomly",
|
|
35
|
+
"time taken (ms)": "98.02",
|
|
36
|
+
"executions per sec": "10.20",
|
|
37
37
|
"sample deviation": "0.00"
|
|
38
38
|
},
|
|
39
39
|
{
|
|
40
|
-
"test name": "
|
|
41
|
-
"time taken (ms)": "
|
|
42
|
-
"executions per sec": "
|
|
43
|
-
"sample deviation": "
|
|
40
|
+
"test name": "100,000 delete randomly",
|
|
41
|
+
"time taken (ms)": "182.58",
|
|
42
|
+
"executions per sec": "5.48",
|
|
43
|
+
"sample deviation": "0.00"
|
|
44
44
|
},
|
|
45
45
|
{
|
|
46
|
-
"test name": "
|
|
47
|
-
"time taken (ms)": "
|
|
48
|
-
"executions per sec": "
|
|
49
|
-
"sample deviation": "
|
|
46
|
+
"test name": "100,000 add orderly",
|
|
47
|
+
"time taken (ms)": "42.10",
|
|
48
|
+
"executions per sec": "23.76",
|
|
49
|
+
"sample deviation": "8.79e-4"
|
|
50
50
|
},
|
|
51
51
|
{
|
|
52
|
-
"test name": "
|
|
53
|
-
"time taken (ms)": "
|
|
54
|
-
"executions per sec": "
|
|
55
|
-
"sample deviation": "
|
|
52
|
+
"test name": "100,000 delete randomly",
|
|
53
|
+
"time taken (ms)": "182.16",
|
|
54
|
+
"executions per sec": "5.49",
|
|
55
|
+
"sample deviation": "5.65e-4"
|
|
56
56
|
},
|
|
57
57
|
{
|
|
58
|
-
"test name": "
|
|
59
|
-
"time taken (ms)": "
|
|
60
|
-
"executions per sec": "
|
|
61
|
-
"sample deviation": "0.
|
|
58
|
+
"test name": "100,000 getNode randomly",
|
|
59
|
+
"time taken (ms)": "180.63",
|
|
60
|
+
"executions per sec": "5.54",
|
|
61
|
+
"sample deviation": "0.00"
|
|
62
62
|
},
|
|
63
63
|
{
|
|
64
|
-
"test name": "
|
|
65
|
-
"time taken (ms)": "
|
|
66
|
-
"executions per sec": "
|
|
67
|
-
"sample deviation": "
|
|
64
|
+
"test name": "100,000 add & iterator",
|
|
65
|
+
"time taken (ms)": "129.92",
|
|
66
|
+
"executions per sec": "7.70",
|
|
67
|
+
"sample deviation": "0.00"
|
|
68
68
|
}
|
|
69
69
|
],
|
|
70
|
-
"testName": "
|
|
70
|
+
"testName": "rb-tree"
|
|
71
71
|
},
|
|
72
|
-
"
|
|
72
|
+
"queue": {
|
|
73
73
|
"benchmarks": [
|
|
74
74
|
{
|
|
75
|
-
"test name": "
|
|
76
|
-
"time taken (ms)": "
|
|
77
|
-
"executions per sec": "
|
|
78
|
-
"sample deviation": "0.
|
|
79
|
-
},
|
|
80
|
-
{
|
|
81
|
-
"test name": "100,000 add & delete randomly",
|
|
82
|
-
"time taken (ms)": "221.02",
|
|
83
|
-
"executions per sec": "4.52",
|
|
84
|
-
"sample deviation": "0.03"
|
|
75
|
+
"test name": "1,000,000 push",
|
|
76
|
+
"time taken (ms)": "44.33",
|
|
77
|
+
"executions per sec": "22.56",
|
|
78
|
+
"sample deviation": "0.01"
|
|
85
79
|
},
|
|
86
80
|
{
|
|
87
|
-
"test name": "100,000
|
|
88
|
-
"time taken (ms)": "
|
|
89
|
-
"executions per sec": "
|
|
90
|
-
"sample deviation": "
|
|
81
|
+
"test name": "100,000 push & shift",
|
|
82
|
+
"time taken (ms)": "4.68",
|
|
83
|
+
"executions per sec": "213.63",
|
|
84
|
+
"sample deviation": "1.41e-4"
|
|
91
85
|
},
|
|
92
86
|
{
|
|
93
|
-
"test name": "100,000
|
|
94
|
-
"time taken (ms)": "
|
|
95
|
-
"executions per sec": "
|
|
96
|
-
"sample deviation": "0.
|
|
87
|
+
"test name": "Native JS Array 100,000 push & shift",
|
|
88
|
+
"time taken (ms)": "2633.11",
|
|
89
|
+
"executions per sec": "0.38",
|
|
90
|
+
"sample deviation": "0.44"
|
|
97
91
|
}
|
|
98
92
|
],
|
|
99
|
-
"testName": "
|
|
93
|
+
"testName": "queue"
|
|
100
94
|
},
|
|
101
|
-
"
|
|
95
|
+
"deque": {
|
|
102
96
|
"benchmarks": [
|
|
103
97
|
{
|
|
104
|
-
"test name": "1,000
|
|
105
|
-
"time taken (ms)": "
|
|
106
|
-
"executions per sec": "
|
|
107
|
-
"sample deviation": "
|
|
98
|
+
"test name": "1,000,000 push",
|
|
99
|
+
"time taken (ms)": "24.62",
|
|
100
|
+
"executions per sec": "40.62",
|
|
101
|
+
"sample deviation": "0.00"
|
|
108
102
|
},
|
|
109
103
|
{
|
|
110
|
-
"test name": "1,000
|
|
111
|
-
"time taken (ms)": "
|
|
112
|
-
"executions per sec": "
|
|
104
|
+
"test name": "1,000,000 push & pop",
|
|
105
|
+
"time taken (ms)": "30.71",
|
|
106
|
+
"executions per sec": "32.56",
|
|
113
107
|
"sample deviation": "0.00"
|
|
114
108
|
},
|
|
115
109
|
{
|
|
116
|
-
"test name": "1,000
|
|
117
|
-
"time taken (ms)": "
|
|
118
|
-
"executions per sec": "
|
|
119
|
-
"sample deviation": "
|
|
110
|
+
"test name": "1,000,000 push & shift",
|
|
111
|
+
"time taken (ms)": "31.93",
|
|
112
|
+
"executions per sec": "31.32",
|
|
113
|
+
"sample deviation": "0.01"
|
|
120
114
|
},
|
|
121
115
|
{
|
|
122
|
-
"test name": "
|
|
123
|
-
"time taken (ms)": "
|
|
124
|
-
"executions per sec": "
|
|
125
|
-
"sample deviation": "
|
|
116
|
+
"test name": "100,000 push & shift",
|
|
117
|
+
"time taken (ms)": "3.25",
|
|
118
|
+
"executions per sec": "307.22",
|
|
119
|
+
"sample deviation": "2.74e-4"
|
|
126
120
|
},
|
|
127
121
|
{
|
|
128
|
-
"test name": "
|
|
129
|
-
"time taken (ms)": "
|
|
130
|
-
"executions per sec": "
|
|
131
|
-
"sample deviation": "0.
|
|
122
|
+
"test name": "Native JS Array 100,000 push & shift",
|
|
123
|
+
"time taken (ms)": "2455.51",
|
|
124
|
+
"executions per sec": "0.41",
|
|
125
|
+
"sample deviation": "0.29"
|
|
132
126
|
},
|
|
133
127
|
{
|
|
134
|
-
"test name": "
|
|
135
|
-
"time taken (ms)": "
|
|
136
|
-
"executions per sec": "
|
|
137
|
-
"sample deviation": "
|
|
128
|
+
"test name": "100,000 unshift & shift",
|
|
129
|
+
"time taken (ms)": "2.94",
|
|
130
|
+
"executions per sec": "340.31",
|
|
131
|
+
"sample deviation": "2.39e-4"
|
|
132
|
+
},
|
|
133
|
+
{
|
|
134
|
+
"test name": "Native JS Array 100,000 unshift & shift",
|
|
135
|
+
"time taken (ms)": "4314.20",
|
|
136
|
+
"executions per sec": "0.23",
|
|
137
|
+
"sample deviation": "0.41"
|
|
138
138
|
}
|
|
139
139
|
],
|
|
140
|
-
"testName": "
|
|
140
|
+
"testName": "deque"
|
|
141
141
|
},
|
|
142
142
|
"hash-map": {
|
|
143
143
|
"benchmarks": [
|
|
144
144
|
{
|
|
145
145
|
"test name": "1,000,000 set",
|
|
146
|
-
"time taken (ms)": "
|
|
147
|
-
"executions per sec": "
|
|
148
|
-
"sample deviation": "0.
|
|
146
|
+
"time taken (ms)": "116.60",
|
|
147
|
+
"executions per sec": "8.58",
|
|
148
|
+
"sample deviation": "0.02"
|
|
149
149
|
},
|
|
150
150
|
{
|
|
151
|
-
"test name": "Native Map 1,000,000 set",
|
|
152
|
-
"time taken (ms)": "
|
|
153
|
-
"executions per sec": "4.
|
|
154
|
-
"sample deviation": "0.
|
|
151
|
+
"test name": "Native JS Map 1,000,000 set",
|
|
152
|
+
"time taken (ms)": "202.39",
|
|
153
|
+
"executions per sec": "4.94",
|
|
154
|
+
"sample deviation": "0.01"
|
|
155
155
|
},
|
|
156
156
|
{
|
|
157
|
-
"test name": "Native Set 1,000,000 add",
|
|
158
|
-
"time taken (ms)": "
|
|
159
|
-
"executions per sec": "5.
|
|
157
|
+
"test name": "Native JS Set 1,000,000 add",
|
|
158
|
+
"time taken (ms)": "167.89",
|
|
159
|
+
"executions per sec": "5.96",
|
|
160
160
|
"sample deviation": "0.01"
|
|
161
161
|
},
|
|
162
162
|
{
|
|
163
163
|
"test name": "1,000,000 set & get",
|
|
164
|
-
"time taken (ms)": "
|
|
165
|
-
"executions per sec": "
|
|
164
|
+
"time taken (ms)": "125.21",
|
|
165
|
+
"executions per sec": "7.99",
|
|
166
166
|
"sample deviation": "0.03"
|
|
167
167
|
},
|
|
168
168
|
{
|
|
169
|
-
"test name": "Native Map 1,000,000 set & get",
|
|
170
|
-
"time taken (ms)": "
|
|
171
|
-
"executions per sec": "3.
|
|
169
|
+
"test name": "Native JS Map 1,000,000 set & get",
|
|
170
|
+
"time taken (ms)": "272.20",
|
|
171
|
+
"executions per sec": "3.67",
|
|
172
172
|
"sample deviation": "0.03"
|
|
173
173
|
},
|
|
174
174
|
{
|
|
175
|
-
"test name": "Native Set 1,000,000 add & has",
|
|
176
|
-
"time taken (ms)": "
|
|
177
|
-
"executions per sec": "5.
|
|
175
|
+
"test name": "Native JS Set 1,000,000 add & has",
|
|
176
|
+
"time taken (ms)": "168.51",
|
|
177
|
+
"executions per sec": "5.93",
|
|
178
178
|
"sample deviation": "0.01"
|
|
179
179
|
},
|
|
180
180
|
{
|
|
181
181
|
"test name": "1,000,000 ObjKey set & get",
|
|
182
|
-
"time taken (ms)": "
|
|
183
|
-
"executions per sec": "
|
|
184
|
-
"sample deviation": "0.
|
|
182
|
+
"time taken (ms)": "309.10",
|
|
183
|
+
"executions per sec": "3.24",
|
|
184
|
+
"sample deviation": "0.01"
|
|
185
185
|
},
|
|
186
186
|
{
|
|
187
|
-
"test name": "Native Map 1,000,000 ObjKey set & get",
|
|
188
|
-
"time taken (ms)": "
|
|
189
|
-
"executions per sec": "3.
|
|
190
|
-
"sample deviation": "0.
|
|
187
|
+
"test name": "Native JS Map 1,000,000 ObjKey set & get",
|
|
188
|
+
"time taken (ms)": "299.43",
|
|
189
|
+
"executions per sec": "3.34",
|
|
190
|
+
"sample deviation": "0.03"
|
|
191
191
|
},
|
|
192
192
|
{
|
|
193
|
-
"test name": "Native Set 1,000,000 ObjKey add & has",
|
|
194
|
-
"time taken (ms)": "
|
|
195
|
-
"executions per sec": "3.
|
|
196
|
-
"sample deviation": "0.
|
|
193
|
+
"test name": "Native JS Set 1,000,000 ObjKey add & has",
|
|
194
|
+
"time taken (ms)": "260.93",
|
|
195
|
+
"executions per sec": "3.83",
|
|
196
|
+
"sample deviation": "0.02"
|
|
197
197
|
}
|
|
198
198
|
],
|
|
199
199
|
"testName": "hash-map"
|
|
200
200
|
},
|
|
201
|
-
"
|
|
201
|
+
"trie": {
|
|
202
202
|
"benchmarks": [
|
|
203
203
|
{
|
|
204
|
-
"test name": "100,000
|
|
205
|
-
"time taken (ms)": "
|
|
206
|
-
"executions per sec": "
|
|
207
|
-
"sample deviation": "
|
|
208
|
-
},
|
|
209
|
-
{
|
|
210
|
-
"test name": "100,000 add & dfs",
|
|
211
|
-
"time taken (ms)": "33.14",
|
|
212
|
-
"executions per sec": "30.17",
|
|
213
|
-
"sample deviation": "0.00"
|
|
204
|
+
"test name": "100,000 push",
|
|
205
|
+
"time taken (ms)": "43.32",
|
|
206
|
+
"executions per sec": "23.08",
|
|
207
|
+
"sample deviation": "6.16e-4"
|
|
214
208
|
},
|
|
215
209
|
{
|
|
216
|
-
"test name": "
|
|
217
|
-
"time taken (ms)": "
|
|
218
|
-
"executions per sec": "
|
|
210
|
+
"test name": "100,000 getWords",
|
|
211
|
+
"time taken (ms)": "84.84",
|
|
212
|
+
"executions per sec": "11.79",
|
|
219
213
|
"sample deviation": "0.00"
|
|
220
214
|
}
|
|
221
215
|
],
|
|
222
|
-
"testName": "
|
|
216
|
+
"testName": "trie"
|
|
223
217
|
},
|
|
224
|
-
"
|
|
218
|
+
"avl-tree": {
|
|
225
219
|
"benchmarks": [
|
|
226
220
|
{
|
|
227
|
-
"test name": "
|
|
228
|
-
"time taken (ms)": "
|
|
229
|
-
"executions per sec": "
|
|
230
|
-
"sample deviation": "0.
|
|
221
|
+
"test name": "10,000 add randomly",
|
|
222
|
+
"time taken (ms)": "129.04",
|
|
223
|
+
"executions per sec": "7.75",
|
|
224
|
+
"sample deviation": "0.00"
|
|
231
225
|
},
|
|
232
226
|
{
|
|
233
|
-
"test name": "
|
|
234
|
-
"time taken (ms)": "
|
|
235
|
-
"executions per sec": "
|
|
236
|
-
"sample deviation": "
|
|
227
|
+
"test name": "10,000 get",
|
|
228
|
+
"time taken (ms)": "51.31",
|
|
229
|
+
"executions per sec": "19.49",
|
|
230
|
+
"sample deviation": "5.76e-4"
|
|
237
231
|
},
|
|
238
232
|
{
|
|
239
|
-
"test name": "
|
|
240
|
-
"time taken (ms)": "
|
|
241
|
-
"executions per sec": "5.
|
|
242
|
-
"sample deviation": "0.
|
|
233
|
+
"test name": "10,000 add & delete randomly",
|
|
234
|
+
"time taken (ms)": "190.44",
|
|
235
|
+
"executions per sec": "5.25",
|
|
236
|
+
"sample deviation": "0.00"
|
|
243
237
|
},
|
|
244
238
|
{
|
|
245
|
-
"test name": "
|
|
246
|
-
"time taken (ms)": "
|
|
247
|
-
"executions per sec": "
|
|
248
|
-
"sample deviation": "0.
|
|
239
|
+
"test name": "10,000 addMany",
|
|
240
|
+
"time taken (ms)": "137.94",
|
|
241
|
+
"executions per sec": "7.25",
|
|
242
|
+
"sample deviation": "0.00"
|
|
249
243
|
}
|
|
250
244
|
],
|
|
251
|
-
"testName": "
|
|
245
|
+
"testName": "avl-tree"
|
|
252
246
|
},
|
|
253
|
-
"
|
|
247
|
+
"binary-tree-overall": {
|
|
254
248
|
"benchmarks": [
|
|
255
249
|
{
|
|
256
|
-
"test name": "
|
|
257
|
-
"time taken (ms)": "
|
|
258
|
-
"executions per sec": "
|
|
259
|
-
"sample deviation": "
|
|
250
|
+
"test name": "10,000 RBTree add",
|
|
251
|
+
"time taken (ms)": "8.13",
|
|
252
|
+
"executions per sec": "122.97",
|
|
253
|
+
"sample deviation": "1.87e-4"
|
|
260
254
|
},
|
|
261
255
|
{
|
|
262
|
-
"test name": "10,000
|
|
263
|
-
"time taken (ms)": "
|
|
264
|
-
"executions per sec": "
|
|
265
|
-
"sample deviation": "
|
|
256
|
+
"test name": "10,000 RBTree add & delete randomly",
|
|
257
|
+
"time taken (ms)": "58.30",
|
|
258
|
+
"executions per sec": "17.15",
|
|
259
|
+
"sample deviation": "5.24e-4"
|
|
266
260
|
},
|
|
267
261
|
{
|
|
268
|
-
"test name": "10,000
|
|
269
|
-
"time taken (ms)": "
|
|
270
|
-
"executions per sec": "
|
|
271
|
-
"sample deviation": "
|
|
272
|
-
}
|
|
273
|
-
],
|
|
274
|
-
"testName": "singly-linked-list"
|
|
275
|
-
},
|
|
276
|
-
"priority-queue": {
|
|
277
|
-
"benchmarks": [
|
|
262
|
+
"test name": "10,000 RBTree get",
|
|
263
|
+
"time taken (ms)": "18.16",
|
|
264
|
+
"executions per sec": "55.06",
|
|
265
|
+
"sample deviation": "2.06e-4"
|
|
266
|
+
},
|
|
278
267
|
{
|
|
279
|
-
"test name": "
|
|
280
|
-
"time taken (ms)": "
|
|
281
|
-
"executions per sec": "
|
|
268
|
+
"test name": "10,000 AVLTree add",
|
|
269
|
+
"time taken (ms)": "129.10",
|
|
270
|
+
"executions per sec": "7.75",
|
|
282
271
|
"sample deviation": "0.00"
|
|
272
|
+
},
|
|
273
|
+
{
|
|
274
|
+
"test name": "10,000 AVLTree get",
|
|
275
|
+
"time taken (ms)": "51.37",
|
|
276
|
+
"executions per sec": "19.47",
|
|
277
|
+
"sample deviation": "7.26e-4"
|
|
278
|
+
},
|
|
279
|
+
{
|
|
280
|
+
"test name": "10,000 AVLTree add & delete randomly",
|
|
281
|
+
"time taken (ms)": "189.84",
|
|
282
|
+
"executions per sec": "5.27",
|
|
283
|
+
"sample deviation": "8.96e-4"
|
|
283
284
|
}
|
|
284
285
|
],
|
|
285
|
-
"testName": "
|
|
286
|
+
"testName": "binary-tree-overall"
|
|
286
287
|
},
|
|
287
|
-
"
|
|
288
|
+
"directed-graph": {
|
|
288
289
|
"benchmarks": [
|
|
289
290
|
{
|
|
290
|
-
"test name": "1,000
|
|
291
|
-
"time taken (ms)": "
|
|
292
|
-
"executions per sec": "
|
|
293
|
-
"sample deviation": "
|
|
291
|
+
"test name": "1,000 addVertex",
|
|
292
|
+
"time taken (ms)": "0.10",
|
|
293
|
+
"executions per sec": "9882.73",
|
|
294
|
+
"sample deviation": "1.12e-6"
|
|
294
295
|
},
|
|
295
296
|
{
|
|
296
|
-
"test name": "1,000
|
|
297
|
-
"time taken (ms)": "
|
|
298
|
-
"executions per sec": "
|
|
299
|
-
"sample deviation": "
|
|
297
|
+
"test name": "1,000 addEdge",
|
|
298
|
+
"time taken (ms)": "6.18",
|
|
299
|
+
"executions per sec": "161.76",
|
|
300
|
+
"sample deviation": "7.54e-4"
|
|
300
301
|
},
|
|
301
302
|
{
|
|
302
|
-
"test name": "
|
|
303
|
-
"time taken (ms)": "
|
|
304
|
-
"executions per sec": "
|
|
305
|
-
"sample deviation": "
|
|
303
|
+
"test name": "1,000 getVertex",
|
|
304
|
+
"time taken (ms)": "0.05",
|
|
305
|
+
"executions per sec": "2.17e+4",
|
|
306
|
+
"sample deviation": "3.35e-7"
|
|
306
307
|
},
|
|
307
308
|
{
|
|
308
|
-
"test name": "
|
|
309
|
-
"time taken (ms)": "
|
|
310
|
-
"executions per sec": "
|
|
311
|
-
"sample deviation": "0.
|
|
309
|
+
"test name": "1,000 getEdge",
|
|
310
|
+
"time taken (ms)": "23.36",
|
|
311
|
+
"executions per sec": "42.81",
|
|
312
|
+
"sample deviation": "0.00"
|
|
312
313
|
},
|
|
313
314
|
{
|
|
314
|
-
"test name": "
|
|
315
|
-
"time taken (ms)": "
|
|
316
|
-
"executions per sec": "
|
|
317
|
-
"sample deviation": "
|
|
315
|
+
"test name": "tarjan",
|
|
316
|
+
"time taken (ms)": "208.84",
|
|
317
|
+
"executions per sec": "4.79",
|
|
318
|
+
"sample deviation": "0.01"
|
|
318
319
|
},
|
|
319
320
|
{
|
|
320
|
-
"test name": "
|
|
321
|
-
"time taken (ms)": "
|
|
322
|
-
"executions per sec": "
|
|
323
|
-
"sample deviation": "0.
|
|
321
|
+
"test name": "topologicalSort",
|
|
322
|
+
"time taken (ms)": "178.78",
|
|
323
|
+
"executions per sec": "5.59",
|
|
324
|
+
"sample deviation": "0.00"
|
|
324
325
|
}
|
|
325
326
|
],
|
|
326
|
-
"testName": "
|
|
327
|
+
"testName": "directed-graph"
|
|
327
328
|
},
|
|
328
|
-
"
|
|
329
|
+
"doubly-linked-list": {
|
|
329
330
|
"benchmarks": [
|
|
330
331
|
{
|
|
331
332
|
"test name": "1,000,000 push",
|
|
332
|
-
"time taken (ms)": "
|
|
333
|
-
"executions per sec": "
|
|
334
|
-
"sample deviation": "0.
|
|
333
|
+
"time taken (ms)": "217.73",
|
|
334
|
+
"executions per sec": "4.59",
|
|
335
|
+
"sample deviation": "0.05"
|
|
335
336
|
},
|
|
336
337
|
{
|
|
337
|
-
"test name": "
|
|
338
|
-
"time taken (ms)": "
|
|
339
|
-
"executions per sec": "
|
|
340
|
-
"sample deviation": "
|
|
338
|
+
"test name": "1,000,000 unshift",
|
|
339
|
+
"time taken (ms)": "200.41",
|
|
340
|
+
"executions per sec": "4.99",
|
|
341
|
+
"sample deviation": "0.04"
|
|
341
342
|
},
|
|
342
343
|
{
|
|
343
|
-
"test name": "
|
|
344
|
-
"time taken (ms)": "
|
|
345
|
-
"executions per sec": "
|
|
346
|
-
"sample deviation": "0.
|
|
344
|
+
"test name": "1,000,000 unshift & shift",
|
|
345
|
+
"time taken (ms)": "168.75",
|
|
346
|
+
"executions per sec": "5.93",
|
|
347
|
+
"sample deviation": "0.04"
|
|
347
348
|
},
|
|
348
349
|
{
|
|
349
|
-
"test name": "
|
|
350
|
-
"time taken (ms)": "
|
|
351
|
-
"executions per sec": "
|
|
352
|
-
"sample deviation": "
|
|
350
|
+
"test name": "1,000,000 addBefore",
|
|
351
|
+
"time taken (ms)": "298.21",
|
|
352
|
+
"executions per sec": "3.35",
|
|
353
|
+
"sample deviation": "0.06"
|
|
353
354
|
}
|
|
354
355
|
],
|
|
355
|
-
"testName": "
|
|
356
|
+
"testName": "doubly-linked-list"
|
|
356
357
|
},
|
|
357
|
-
"
|
|
358
|
+
"singly-linked-list": {
|
|
358
359
|
"benchmarks": [
|
|
359
360
|
{
|
|
360
|
-
"test name": "1,000,000 push",
|
|
361
|
-
"time taken (ms)": "
|
|
362
|
-
"executions per sec": "
|
|
363
|
-
"sample deviation": "0.
|
|
361
|
+
"test name": "1,000,000 push & shift",
|
|
362
|
+
"time taken (ms)": "196.65",
|
|
363
|
+
"executions per sec": "5.09",
|
|
364
|
+
"sample deviation": "0.04"
|
|
364
365
|
},
|
|
365
366
|
{
|
|
366
|
-
"test name": "
|
|
367
|
-
"time taken (ms)": "
|
|
368
|
-
"executions per sec": "
|
|
367
|
+
"test name": "10,000 push & pop",
|
|
368
|
+
"time taken (ms)": "221.63",
|
|
369
|
+
"executions per sec": "4.51",
|
|
369
370
|
"sample deviation": "0.02"
|
|
371
|
+
},
|
|
372
|
+
{
|
|
373
|
+
"test name": "10,000 addBefore",
|
|
374
|
+
"time taken (ms)": "249.40",
|
|
375
|
+
"executions per sec": "4.01",
|
|
376
|
+
"sample deviation": "0.01"
|
|
370
377
|
}
|
|
371
378
|
],
|
|
372
|
-
"testName": "
|
|
379
|
+
"testName": "singly-linked-list"
|
|
373
380
|
},
|
|
374
|
-
"
|
|
381
|
+
"priority-queue": {
|
|
375
382
|
"benchmarks": [
|
|
376
383
|
{
|
|
377
|
-
"test name": "100,000
|
|
378
|
-
"time taken (ms)": "
|
|
379
|
-
"executions per sec": "
|
|
380
|
-
"sample deviation": "
|
|
384
|
+
"test name": "100,000 add",
|
|
385
|
+
"time taken (ms)": "28.95",
|
|
386
|
+
"executions per sec": "34.55",
|
|
387
|
+
"sample deviation": "0.00"
|
|
381
388
|
},
|
|
382
389
|
{
|
|
383
|
-
"test name": "100,000
|
|
384
|
-
"time taken (ms)": "
|
|
385
|
-
"executions per sec": "
|
|
390
|
+
"test name": "100,000 add & poll",
|
|
391
|
+
"time taken (ms)": "76.25",
|
|
392
|
+
"executions per sec": "13.11",
|
|
393
|
+
"sample deviation": "6.57e-4"
|
|
394
|
+
}
|
|
395
|
+
],
|
|
396
|
+
"testName": "priority-queue"
|
|
397
|
+
},
|
|
398
|
+
"stack": {
|
|
399
|
+
"benchmarks": [
|
|
400
|
+
{
|
|
401
|
+
"test name": "1,000,000 push",
|
|
402
|
+
"time taken (ms)": "39.72",
|
|
403
|
+
"executions per sec": "25.18",
|
|
404
|
+
"sample deviation": "0.01"
|
|
405
|
+
},
|
|
406
|
+
{
|
|
407
|
+
"test name": "1,000,000 push & pop",
|
|
408
|
+
"time taken (ms)": "49.18",
|
|
409
|
+
"executions per sec": "20.33",
|
|
386
410
|
"sample deviation": "0.01"
|
|
387
411
|
}
|
|
388
412
|
],
|
|
389
|
-
"testName": "
|
|
413
|
+
"testName": "stack"
|
|
390
414
|
}
|
|
391
415
|
}
|