2009年7月25日星期六

Benchmarking php op-codes caches

1)No PHP op-code cache:

Document Path:          /cookingbama/food.php?food_id=3
Document Length:        5489 bytes

Concurrency Level:      5
Time taken for tests:   50.571265 seconds
Complete requests:      3000
Failed requests:        0
Write errors:           0
Total transferred:      17199000 bytes
HTML transferred:       16467000 bytes
Requests per second:    59.32 [#/sec] (mean)
Time per request:       84.285 [ms] (mean)
Time per request:       16.857 [ms] (mean, across all concurrent requests)
Transfer rate:          332.11 [Kbytes/sec] received

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0    0   0.0      0       0
Processing:    30   83  47.7     73     322
Waiting:       30   81  47.3     70     322
Total:         30   83  47.7     73     322

Percentage of the requests served within a certain time (ms)
  50%     73
  66%     96
  75%    109
  80%    120
  90%    149
  95%    177
  98%    214
  99%    236
100%    322 (longest request)

2)Xcache:

Document Path:          /cookingbama/food.php?food_id=3
Document Length:        5489 bytes

Concurrency Level:      5
Time taken for tests:   4.970640 seconds
Complete requests:      3000
Failed requests:        0
Write errors:           0
Total transferred:      17199000 bytes
HTML transferred:       16467000 bytes
Requests per second:    603.54 [#/sec] (mean)
Time per request:       8.284 [ms] (mean)
Time per request:       1.657 [ms] (mean, across all concurrent requests)
Transfer rate:          3378.84 [Kbytes/sec] received

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0    0   0.0      0       0
Processing:     2    7   4.1      7      48
Waiting:        2    7   4.1      7      47
Total:          2    7   4.1      7      48

Percentage of the requests served within a certain time (ms)
  50%      7
  66%      9
  75%     10
  80%     10
  90%     12
  95%     15
  98%     18
  99%     21
100%     48 (longest request)

3)eAccelerator

Document Path:          /cookingbama/food.php?food_id=3
Document Length:        5489 bytes

Concurrency Level:      5
Time taken for tests:   6.9865 seconds
Complete requests:      3000
Failed requests:        0
Write errors:           0
Total transferred:      17199000 bytes
HTML transferred:       16467000 bytes
Requests per second:    499.18 [#/sec] (mean)
Time per request:       10.016 [ms] (mean)
Time per request:       2.003 [ms] (mean, across all concurrent requests)
Transfer rate:          2794.57 [Kbytes/sec] received

Connection Times (ms)
              min  mean[+/-sd] median   max
Connect:        0    0   0.2      0       9
Processing:     3    9   6.1      8      57
Waiting:        3    9   6.1      8      57
Total:          3    9   6.1      8      57

Percentage of the requests served within a certain time (ms)
  50%      8
  66%     10
  75%     12
  80%     13
  90%     18
  95%     22
  98%     26
  99%     30
100%     57 (longest request)

Xcache is the winner.