OPcache on CloudSonic

Cache compiled PHP in memory so your application never re-parses the same file twice

TL;DR OPcache

OPcache is configured on every CloudSonic server with JIT tracing mode enabled, caching compiled PHP so your application never recompiles the same code twice.

OPcache is a PHP extension that improves performance by storing precompiled script bytecode in memory, eliminating the need to reload and reparse PHP files on every request. It is configured on every CloudSonic server with JIT tracing mode enabled, which is the highest performance compilation mode available in modern PHP. OPcache works alongside Redis object caching and Nginx FastCGI caching as one of three caching layers active on every CloudSonic server.

OPcache for PHP Performance on CloudSonic

OPcache on CloudSonic is configured with JIT tracing mode enabled, which is the highest performance JIT compilation mode available in modern PHP. The OPcache memory allocation is sized appropriately for the server's available RAM so the compiled bytecode of your entire PHP application fits in memory without eviction under normal load. OPcache works alongside Redis object caching for database query results and Nginx FastCGI caching for full page HTML output as one of three caching layers that work together to minimise the PHP processing required on every request.

Warning OPcache timestamp validation is disabled on CloudSonic for performance, meaning PHP files are not automatically revalidated after changes; you must clear the OPcache manually after each deployment.