Articles
Vous lisez une vieille version : ce document dispose d'une version plus récente : Base configuration for PHP 5.2.5
Ce document est aussi disponible en français
Since PHP 5.2.3 has been published, over 9700 tests were sent to the Quality Assurance Team. In those tests reports, we can find the list of failed tests, and an anonymous PHPinfo(), that helps the PHP team to understand the origin of the errors. With such a number of phpinfo(), it is tempting to get some stats about compilation choices.
Attention : thos statistics are based on the report sent to PHP.net. There is no proof they are representative of the usual PHP usage, may it be on the Web or as CLI. The only credibility here lies in the high number of processed phpinfo(). That, and some math thoeries...
From this study, PHP architectures have from 5 to 61 extensions. The most popular configuration havent 23 extensions, and rarely less. Then, probability lowers as more extensions are being used. The maximum number of PHP extension tested at the same time is currently 61.
Standard configuration
The standard configuration is the list of PHP extension that are almost certainly on any given PHP binary.
The only one that is universally present is called 'standard' : if you can't find it, you're probably not using PHP.
Date and pcre are also compulsory in PHP 5.2.3 and you 'll have them always handy. Sessions and reflection are close to be universal, though not exactly : this is were we can see that both Web and CLI test reports are being send to php.net.

Popular extensions
This list are the popular extensions : the one you may bet on, but may also be absent. Some of those extension are definitely on the raise, like json or mysqli, while some are loosing ground, like mysql. There is a noticeable gap between those extension and the standard one : sqlite, the lowest from standard group, is still in over 90% of PHP binaries. mysql, the highest of the popular extensions, is showing 65% of presence. All in all, MySQL is present in 85% of binaries, close to a standard extension (mysqli + mysql).

The rare extensions
The last group of extension are the rare one : they never go beyond 10%. They usually require some extra work to have them working with PHP, may it be compiling an external library, downloading the driver from PECL or the editor's site, or even working on the code. Whenever your application is relying on one of those extension, your users may find it hard to have it hosted.
A large share of the below extensions are in PECL, while the others are on specific sites. This is a fun graph, to discover new extensions.

All extensions
And here is the full graph, and below, the tabulated details of every PHP extensions.

All links link to PHP manual, PECL web site or a search on Google.
| date | 100.00 % | |
| standard | 100.00 % | |
| pcre | 100.00 % | |
| session | 99.72 % | |
| Reflection | 99.66 % | |
| SPL | 99.27 % | |
| hash | 99.17 % | |
| filter | 99.06 % | |
| libxml | 99.05 % | |
| ctype | 99.04 % | |
| json | 99.00 % | |
| tokenizer | 98.94 % | |
| xml | 98.84 % | |
| iconv | 98.64 % | |
| SimpleXML | 98.57 % | |
| posix | 98.42 % | |
| xmlreader | 97.89 % | |
| xmlwriter | 97.87 % | |
| dom | 97.81 % | |
| PDO | 97.29 % | |
| pdo_sqlite | 96.10 % | |
| SQLite | 93.89 % | |
| mysql | 61.87 % | |
| zlib | 50.42 % | |
| gd | 43.04 % | |
| mbstring | 35.32 % | |
| ftp | 25.85 % | |
| openssl | 24.71 % | |
| curl | 23.45 % | |
| sockets | 21.51 % | |
| gettext | 20.86 % | |
| exif | 16.56 % | |
| calendar | 16.30 % | |
| mysqli | 14.66 % | |
| bcmath | 13.80 % | |
| mcrypt | 13.50 % | |
| bz2 | 12.99 % | |
| pgsql | 11.89 % | |
| soap | 10.56 % | |
| sysvsem | 7.99 % | |
| sysvshm | 7.99 % | |
| wddx | 7.62 % | |
| xsl | 7.51 % | |
| mhash | 7.51 % | |
| dba | 7.01 % | |
| imap | 6.84 % | |
| ldap | 6.83 % | |
| shmop | 5.95 % | |
| pdo_mysql | 5.73 % | |
| zip | 5.48 % | |
| mime_magic | 4.94 % | |
| gmp | 4.85 % | |
| xmlrpc | 4.75 % | |
| sysvmsg | 3.98 % | |
| pspell | 3.79 % | |
| dbase | 3.72 % | |
| pcntl | 3.43 % | |
| ncurses | 2.89 % | |
| mssql | 2.40 % | |
| pdo_pgsql | 2.24 % | |
| readline | 2.09 % | |
| snmp | 1.85 % | |
| odbc | 1.78 % | |
| tidy | 1.55 % | |
| apc | 1.05 % | |
| memcache | 0.76 % | |
| ming | 0.61 % | |
| eAccelerator | 0.52 % | |
| ionCube Loader | 0.47 % | |
| XCache | 0.42 % | |
| sybase | 0.34 % | |
| 0.32 % | ||
| fileinfo | 0.31 % | |
| xdebug | 0.29 % | |
| magickwand | 0.28 % | |
| suhosin | 0.22 % | |
| http | 0.18 % | |
| sybase_ct | 0.16 % | |
| imagick | 0.14 % | |
| ffmpeg | 0.13 % | |
| interbase | 0.13 % | |
| pdo_dblib | 0.13 % | |
| crack | 0.12 % | |
| com_dotnet | 0.11 % | |
| jobqueue_client | 0.09 % | |
| wsf | 0.08 % | |
| radius | 0.08 % | |
| uploadprogress | 0.08 % | |
| ssh2 | 0.08 % | |
| PDO_OCI | 0.07 % | |
| geoip | 0.07 % | |
| runkit | 0.07 % | |
| simplate | 0.06 % | |
| swishe | 0.06 % | |
| recode | 0.05 % | |
| lzf | 0.05 % | |
| mailparse | 0.05 % | |
| PDO_Firebird | 0.05 % | |
| yaz | 0.05 % | |
| java | 0.05 % | |
| MapScript | 0.05 % | |
| pdo_informix | 0.04 % | |
| ADOdb | 0.04 % | |
| fdf | 0.04 % | |
| adv_ini | 0.04 % | |
| APD | 0.04 % | |
| mnogosearch | 0.04 % | |
| svn | 0.03 % | |
| rrdtool | 0.03 % | |
| gnupg | 0.03 % | |
| php_dumper | 0.03 % | |
| dbg | 0.03 % | |
| amf | 0.02 % | |
| fribidi | 0.02 % | |
| kakapo | 0.02 % | |
| pfpro | 0.02 % | |
| daumauth | 0.02 % | |
| chinapay | 0.02 % | |
| xdiff | 0.02 % | |
| syck | 0.02 % | |
| namazu | 0.02 % | |
| stats | 0.01 % | |
| ps | 0.01 % | |
| sdo | 0.01 % | |
| timezonedb | 0.01 % | |
| PHPPROJ | 0.01 % | |
| id3 | 0.01 % | |
| rar | 0.01 % | |
| kakasi | 0.01 % | |
| sql_relay | 0.01 % | |
| face_detect | 0.01 % | |
| spread | 0.01 % | |
| Xaira | 0.01 % | |
| file_get_contents_compress | 0.01 % | |
| VersyPDF | 0.01 % | |
| KOSHIAN | 0.01 % | |
| ogr | 0.01 % | |
| translit | 0.01 % | |
| perl | 0.01 % | |
| yats | 0.01 % | |
| msql | 0.01 % | |
| ChartDirector PHP API | 0.01 % | |
| idn | 0.01 % | |
| flexis | 0.01 % | |
| vld | 0.01 % | |
| cybersource | 0.01 % | |
| mod_cluster | 0.01 % | |
| PostgreSQL | 0.01 % | |
| mecab | 0.01 % | |
| dio | 0.01 % | |
| ivan_test | 0.01 % | |
| odbtp | 0.01 % | |
| ibm_db2 | 0.01 % | |
| oci8 | 0.01 % | |
| dbx | 0.01 % |
Take note :
- There are configuration directives shown in the test report, though it is my understanding that they will change between compilation and production. They are not reliable enough to make any stats, like we did with the 2006 phpinfo() study. Extension, on the other hand, are there to stay.
- It is possible to get some more information from the tests reports about static aspects of PHP binaries (libraries versions, helpers, etc). If you want other insight, feel free to drop me a note
| < Précédent | Suivant > |
|---|
Commentaires
Vous pouvez ajouter votre commentaire! |
Vous devez vous connecter pour commenter


