Skip to content

Commit 2be4414

Browse files
committed
update the benchmark result.
fix #55
1 parent f77aee9 commit 2be4414

File tree

1 file changed

+22
-8
lines changed

1 file changed

+22
-8
lines changed

README.md

Lines changed: 22 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -235,7 +235,7 @@ make deps
235235
## Benchmark
236236

237237
We wrote some simple benchmark scripts.
238-
Machine environment: 9600kf 3.7G CPU.
238+
Machine environment: MacBook Pro (16-inch, 2019), CPU 2.3 GHz Intel Core i9.
239239

240240
```shell
241241
$ make
@@ -248,23 +248,37 @@ resty -I=./lib -I=./deps/share/lua/5.1 benchmark/match-parameter.lua
248248
matched res: 1
249249
route count: 100000
250250
match times: 1000000
251-
time used : 1.1389999389648 sec
252-
QPS : 877963
253-
each time : 1.1389999389648 ns
251+
time used : 0.46799993515015 sec
252+
QPS : 2136752
253+
each time : 0.46799993515015 ns
254254

255255
resty -I=./lib -I=./deps/share/lua/5.1 benchmark/match-prefix.lua
256256
matched res: 500
257257
route count: 100000
258258
match times: 1000000
259-
time used : 0.54299998283386 sec
260-
QPS : 1841620
259+
time used : 0.43799996376038 sec
260+
QPS : 2283105
261261

262262
resty -I=./lib -I=./deps/share/lua/5.1 benchmark/match-static.lua
263263
matched res: 500
264264
route count: 100000
265265
match times: 1000000
266-
time used : 0.10500001907349 sec
267-
QPS : 9523807
266+
time used : 0.082000017166138 sec
267+
QPS : 12195119
268+
269+
resty -I=./lib -I=./deps/share/lua/5.1 benchmark/match-hosts.lua
270+
matched res: 500
271+
route count: 1000
272+
match times: 100000
273+
time used : 1.6740000247955 sec
274+
QPS : 59737
275+
276+
resty -I=./lib -I=./deps/share/lua/5.1 benchmark/match-wildcard-hosts.lua
277+
matched res: 500
278+
route count: 1000
279+
match times: 5000
280+
time used : 0.11899995803833 sec
281+
QPS : 42016
268282
```
269283

270284
[Back to TOC](#table-of-contents)

0 commit comments

Comments
 (0)