some phpng benchmarks
| From: | Stas Malyshev | Date: | Fri, 16 May 2014 00:12:51 +0000 |
| Subject: | some phpng benchmarks | ||
| Groups: | php.internals | ||
| Request: | Send a blank email to internals+get-74241@lists.php.net to get a copy of this message | ||
Hi!
I've recently succeeded in running SugarCRM (if you don't know what it
is, it is a big app, lots of code, lots of memory used, lots of db
queries, etc.) on phpng and did some benchmarks, and I was asked to
share the results with everybody. So here it goes:
Benchmark setup:
1. lighttpd with fcgi driver
2. Single process PHP: sapi/cgi/php-cgi -b 9999
3. ab as benchmark driver, like: ab -k -c 1 -n 100 -C
'PHPSESSID=223876233264873232523'
'http://127.0.0.1:8080/sugar674u/index.php?module=Accounts&action=index&ajax_load=1'
4. SugarCRM 6.7.4
5. opcache and php config as described in wiki here:
https://wiki.php.net/phpng
Benchmark 1:
DetailView on Sugar. This view has a lot of data and SQL queries. Results:
MASTER:
-------
Total transferred: 21022400 bytes
HTML transferred: 20957000 bytes
Requests per second: 3.51 [#/sec] (mean)
Time per request: 284.997 [ms] (mean)
Transfer rate: 720.32 [Kbytes/sec] received
PHPNG:
-----
Total transferred: 21022400 bytes
HTML transferred: 20957000 bytes
Requests per second: 4.70 [#/sec] (mean)
Time per request: 212.929 [ms] (mean)
Transfer rate: 964.12 [Kbytes/sec] received
Benchmark 2:
ListView on Sugar. This view is smaller since it has only one data set
(list of records)
Results:
MASTER:
------
Total transferred: 12386000 bytes
HTML transferred: 12320600 bytes
Requests per second: 8.64 [#/sec] (mean)
Time per request: 115.692 [ms] (mean)
Transfer rate: 1045.45 [Kbytes/sec] received
PHPNG:
-----
Total transferred: 12386000 bytes
HTML transferred: 12320600 bytes
Requests per second: 12.03 [#/sec] (mean)
Time per request: 83.153 [ms] (mean)
Transfer rate: 1454.55 [Kbytes/sec] received
So, we have 25-30% improvement, which definitely sounds very good. Of
course, these benchmarks are single-thread no-load benchmarks on single
Will also look a bit later into seeing how it behaves memory-wise (it
uses a lot of memory usually so may be interesting to see what happens
there) and how latest version (which has shorter and leaner requests)
behaves.
--
Stanislav Malyshev, Software Architect
SugarCRM: http://www.sugarcrm.com/
(408)454-6900 ext. 227