/mobile Handheld Friendly website
Ubuntu : Intel® Q6600® one core |
This chart shows 3 comparisons - Time-used, Memory-used and Code-used ~ speed and size.
Each chart bar shows, for one unidentified benchmark, how much the fastest PHP program used compared to the fastest Java 7 -server program.
Look at speed another way - look at a box plot of Time-used data.
This table shows 3 comparisons - Time-used, Memory-used and Code-used ~ speed and size.
Each table row shows, for one named benchmark, how much the fastest PHP program used compared to the fastest Java 7 -server program.
| PHP used what fraction? used how many times more? | ||||
|---|---|---|---|---|
| Benchmark | Time | Memory | Code | |
| pidigits | ± | 1/4 | 1/2 | |
| regex-dna | ± | 1/3 | 1/3 | |
| reverse-complement | 2× | ± | 1/2 | |
| k-nucleotide | 10× | ± | 1/3 | |
| spectral-norm | 27× | 1/3 | 1/2 | |
| n-body | 30× | 1/5 | ± | |
| fasta | 31× | 1/6 | ± | |
| mandelbrot | 44× | 1/25 | 1/2 | |
| fannkuch-redux | 45× | 1/6 | 1/3 | |
| binary-trees | 58× | 2× | ± | |
| PHP used what fraction? used how many times more? | |||||||
|---|---|---|---|---|---|---|---|
| Time-used | |- | |--- | 25% | median | 75% | ---| | -| |
| (Elapsed secs) | ± | ± | 2× | 28× | 44× | 58× | 58× |
± read the measurements and then read the program source code.
This table shows 5 measurements - CPU Time, Elapsed Time, Memory, Code and ≈ CPU Load ~ speed and size.
For each named benchmark, measurements of the fastest PHP program are shown for comparison against measurements of the fastest Java 7 -server program.
| Program Source Code | CPU secs | Elapsed secs | Memory KB | Code B | ≈ CPU Load |
|---|---|---|---|---|---|
| pidigits | |||||
| PHP | 4.56 | 4.57 | 3,836 | 537 | 1% 1% 0% 100% |
| Java 7 -server | 5.44 | 5.44 | 16,944 | 938 | 0% 0% 0% 100% |
| regex-dna | |||||
| PHP | 27.58 | 27.60 | 212,000 | 459 | 0% 0% 0% 100% |
| Java 7 -server | 21.58 | 21.61 | 557,612 | 1284 | 0% 0% 0% 100% |
| reverse-complement | |||||
| PHP | 4.55 | 4.58 | 443,220 | 343 | 0% 1% 1% 100% |
| Java 7 -server | 1.87 | 1.90 | 511,340 | 745 | 1% 1% 0% 100% |
| k-nucleotide | |||||
| PHP | 340.87 | 341.02 | 246,780 | 757 | 0% 0% 0% 100% |
| Java 7 -server | 33.81 | 33.93 | 336,388 | 2431 | 0% 0% 0% 100% |
| spectral-norm | |||||
| PHP | 435.29 | 435.41 | 4,616 | 397 | 0% 0% 0% 100% |
| Java 7 -server | 16.21 | 16.21 | 14,860 | 950 | 0% 0% 0% 100% |
| n-body | |||||
| PHP | 733.19 | 733.39 | 2,528 | 1082 | 0% 0% 0% 100% |
| Java 7 -server | 24.32 | 24.33 | 13,744 | 1424 | 0% 0% 0% 100% |
| fasta | |||||
| PHP | 151.21 | 153.51 | 2,528 | 1030 | 0% 0% 0% 100% |
| Java 7 -server | 4.92 | 4.92 | 14,828 | 1507 | 1% 0% 0% 100% |
| mandelbrot | |||||
| PHP | 1,169.87 | 1,170.22 | 2,744 | 443 | 0% 0% 0% 100% |
| Java 7 -server | 26.86 | 26.87 | 67,760 | 796 | 0% 0% 0% 100% |
| fannkuch-redux | |||||
| PHP | 3,225.57 | 3,226.38 | 2,512 | 482 | 0% 0% 0% 100% |
| Java 7 -server | 71.27 | 71.29 | 13,856 | 1282 | 0% 0% 0% 100% |
| binary-trees | |||||
| PHP | 902.03 | 903.99 | 1,253,300 | 483 | 0% 0% 0% 100% |
| Java 7 -server | 15.64 | 15.68 | 506,672 | 603 | 0% 0% 0% 100% |
| fasta-redux | |||||
| Java 7 -server | 0.11 | 0.11 | ? | 1443 | 0% 0% 0% 100% |
Remember - those are just the fastest PHP and Java 7 -server programs measured on this OS/machine. Check if there are other implementations of these benchmark programs for PHP.
Maybe one of those other PHP programs is fastest on a different OS/machine.
Remember - those are just the fastest PHP and Java 7 -server programs measured on this OS/machine. Check if there are faster implementations of these benchmark programs for other programming languages.
Maybe one of those other programs is fastest on a different OS/machine.
PHP 5.4.0 (cli) (built: Mar 2 2012 10:00:03)
Overall Performance: PHP is rarely the bottleneck (HTML slides)
Home Page: http://www.php.net/
Download: http://www.php.net/downloads.php