time[sec] | |
---|---|
CPython 3.4.2(6f78fcb) | 20.5 |
CPython 3.4.2(a724607) | 14.2 |
PyPy 2.5 (6f78fcb) | 3.4 |
PyPy 2.5 (a724607) | 3.1 |
CPython (mysqlclient) | 2.8 |
Dataset is "world database (innodb)". It is deployed on here
time[sec] | |
---|---|
CPython 3.4.2(6f78fcb) | 20.5 |
CPython 3.4.2(a724607) | 14.2 |
PyPy 2.5 (6f78fcb) | 3.4 |
PyPy 2.5 (a724607) | 3.1 |
CPython (mysqlclient) | 2.8 |
Dataset is "world database (innodb)". It is deployed on here
package main | |
import ( | |
"fmt" | |
"github.com/ugorji/go/codec" | |
) | |
var mh = codec.MsgpackHandle{} |
package main | |
import ( | |
"fmt" | |
"github.com/ugorji/go/codec" | |
) | |
var mh = codec.MsgpackHandle{} |
環境:
ボトルネックが変化してもなるべくベンチマークのオプションを変えずにCPUを使うため、 wrk, nginx, Webアプリそれぞれ16プロセス(orスレッド) を利用する。 ただし、 meinheld, minefield については、 16 プロセスだと thundering herd 問題を起こしているらしく性能が激しく劣化するので、 worker=8 にする。
// 初期実装 | |
/* The Computer Language Benchmarks Game | |
* http://benchmarksgame.alioth.debian.org/ | |
* | |
* contributed by The Go Authors. | |
* modified by Tylor Arndt. | |
* modified by Chandra Sekar S to use optimized PCRE binding. | |
*/ | |
package main |
/* | |
* Copyright (c) 2014 DeNA Co., Ltd. | |
* | |
* Permission is hereby granted, free of charge, to any person obtaining a copy | |
* of this software and associated documentation files (the "Software"), to | |
* deal in the Software without restriction, including without limitation the | |
* rights to use, copy, modify, merge, publish, distribute, sublicense, and/or | |
* sell copies of the Software, and to permit persons to whom the Software is | |
* furnished to do so, subject to the following conditions: | |
* |
[ec2-user@ip-10-0-1-177 wrk]$ ./wrk -t1 -c1 -d3s http://10.0.1.150:8000/ | |
Running 3s test @ http://10.0.1.150:8000/ | |
1 threads and 1 connections | |
Thread Stats Avg Stdev Max +/- Stdev | |
Latency 135.24us 9.92us 453.00us 91.03% | |
Req/Sec 7.51k 426.94 8.11k 61.60% | |
21401 requests in 3.00s, 2.37MB read | |
Requests/sec: 7133.98 | |
Transfer/sec: 808.15KB | |
[ec2-user@ip-10-0-1-177 wrk]$ ./wrk -t4 -c100 -d10s http://10.0.1.150:8000/ |
$ python -c "import sys; print(sys.stdout.encoding)" | |
UTF-8 | |
$ python -c "import sys; print(sys.stdout.encoding)" | cat | |
None | |
$ PYTHONIOENCODING=utf-8 python -c "import sys; print(sys.stdout.encoding)" | cat | |
utf-8 | |
$ python3 -c "import sys; print(sys.stdout.encoding)" | |
UTF-8 | |
$ python3 -c "import sys; print(sys.stdout.encoding)" | cat | |
UTF-8 |
ROUTINE ====================== net/http.ReadRequest | |
11 403 samples (flat, cumulative) 27.2% of total | |
-------------------- /home/ec2-user/local/go/src/net/http/request.go | |
2 2 591: func ReadRequest(b *bufio.Reader) (req *Request, err error) { | |
. . 447b70: FS MOVQ FS:0xfffffff0, CX | |
2 2 447b79: LEAQ 0xffffff30(SP), AX | |
. . 447b81: CMPQ 0x10(CX), AX | |
. . 447b85: JA 0x447b8e | |
. . 447b87: CALL runtime.morestack_noctxt(SB) | |
. . 447b8c: JMP net/http.ReadRequest(SB) |