Skip to content

Commit c01b9c8

Browse files
joeybloggsjoeybloggs
authored andcommitted
update benchmarks and add link to go-http-routing-benchmark
1 parent 49d567d commit c01b9c8

File tree

1 file changed

+28
-21
lines changed

1 file changed

+28
-21
lines changed

README.md

Lines changed: 28 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -294,32 +294,39 @@ Benchmarks
294294
-----------
295295
Run on MacBook Pro (Retina, 15-inch, Late 2013) 2.6 GHz Intel Core i7 16 GB 1600 MHz DDR3 using Go version go1.6 darwin/amd64
296296

297-
NOTICE: lars uses a custom version of [httprouter](https://github.com/julienschmidt/httprouter)
297+
NOTICE: lars uses a custom version of [httprouter](https://github.com/julienschmidt/httprouter), benchmarks can be found [here](https://github.com/joeybloggs/go-http-routing-benchmark/tree/lars-only)
298298

299299
```go
300300
go test -bench=. -benchmem=true
301-
githubAPI: 52600 Bytes
302-
gplusAPI: 3624 Bytes
303-
parseAPI: 6616 Bytes
304-
staticAPI: 30104 Bytes
301+
#GithubAPI Routes: 203
302+
LARS: 49016 Bytes
303+
304+
#GPlusAPI Routes: 13
305+
LARS: 3624 Bytes
306+
307+
#ParseAPI Routes: 26
308+
LARS: 6616 Bytes
309+
310+
#Static Routes: 157
311+
LARS: 30104 Bytes
305312

306313
PASS
307-
BenchmarkLARS_GithubStatic-8 20000000 92.8 ns/op 0 B/op 0 allocs/op
308-
BenchmarkLARS_GithubParam-8 10000000 166 ns/op 0 B/op 0 allocs/op
309-
BenchmarkLARS_GithubAll-8 50000 33751 ns/op 0 B/op 0 allocs/op
310-
BenchmarkLARS_GPlusStatic-8 20000000 72.9 ns/op 0 B/op 0 allocs/op
311-
BenchmarkLARS_GPlusParam-8 20000000 99.1 ns/op 0 B/op 0 allocs/op
312-
BenchmarkLARS_GPlus2Params-8 10000000 128 ns/op 0 B/op 0 allocs/op
313-
BenchmarkLARS_GPlusAll-8 1000000 1665 ns/op 0 B/op 0 allocs/op
314-
BenchmarkLARS_ParseStatic-8 20000000 75.1 ns/op 0 B/op 0 allocs/op
315-
BenchmarkLARS_ParseParam-8 20000000 82.5 ns/op 0 B/op 0 allocs/op
316-
BenchmarkLARS_Parse2Params-8 20000000 97.3 ns/op 0 B/op 0 allocs/op
317-
BenchmarkLARS_ParseAll-8 500000 3061 ns/op 0 B/op 0 allocs/op
318-
BenchmarkLARS_StaticAll-8 50000 22858 ns/op 0 B/op 0 allocs/op
319-
BenchmarkLARS_Param-8 20000000 81.1 ns/op 0 B/op 0 allocs/op
320-
BenchmarkLARS_Param5-8 10000000 135 ns/op 0 B/op 0 allocs/op
321-
BenchmarkLARS_Param20-8 5000000 310 ns/op 0 B/op 0 allocs/op
322-
BenchmarkLARS_ParamWrite-8 20000000 83.9 ns/op 0 B/op 0 allocs/op
314+
BenchmarkLARS_Param 20000000 75.3 ns/op 0 B/op 0 allocs/op
315+
BenchmarkLARS_Param5 10000000 126 ns/op 0 B/op 0 allocs/op
316+
BenchmarkLARS_Param20 5000000 311 ns/op 0 B/op 0 allocs/op
317+
BenchmarkLARS_ParamWrite 10000000 144 ns/op 0 B/op 0 allocs/op
318+
BenchmarkLARS_GithubStatic 20000000 101 ns/op 0 B/op 0 allocs/op
319+
BenchmarkLARS_GithubParam 10000000 154 ns/op 0 B/op 0 allocs/op
320+
BenchmarkLARS_GithubAll 50000 33295 ns/op 0 B/op 0 allocs/op
321+
BenchmarkLARS_GPlusStatic 20000000 72.4 ns/op 0 B/op 0 allocs/op
322+
BenchmarkLARS_GPlusParam 20000000 99.6 ns/op 0 B/op 0 allocs/op
323+
BenchmarkLARS_GPlus2Params 10000000 124 ns/op 0 B/op 0 allocs/op
324+
BenchmarkLARS_GPlusAll 1000000 1640 ns/op 0 B/op 0 allocs/op
325+
BenchmarkLARS_ParseStatic 20000000 73.9 ns/op 0 B/op 0 allocs/op
326+
BenchmarkLARS_ParseParam 20000000 79.9 ns/op 0 B/op 0 allocs/op
327+
BenchmarkLARS_Parse2Params 20000000 97.1 ns/op 0 B/op 0 allocs/op
328+
BenchmarkLARS_ParseAll 500000 2974 ns/op 0 B/op 0 allocs/op
329+
BenchmarkLARS_StaticAll 50000 23641 ns/op 0 B/op 0 allocs/op
323330
```
324331

325332
Package Versioning

0 commit comments

Comments
 (0)