3 ms·
> Getting decent performance and/or scaling was/is a major challenge. The rest of what you say I agree with, but the language was never a performance bottlenec
by nkozyra 5y ago
> Getting decent performance and/or scaling was/is a major challenge.
The rest of what you say I agree with, but the language was never a performance bottleneck over other scripting languages.
It certainly scaled better than ruby or perl or python apps with the same logic.
The fact that each request was fundamentally stateless and ephemeral helped this if you needed to distribute your app and made development faster as well.
Back to V5 it outperformed its competition in benchmarks
- cutler 5y agoParadoxically, PHP's stateless architecture is also what makes it dog-slow with large frameworks such as Laravel. Now you have to load the whole framework with every request.
- aetherspawn 5y agoSort of, but you don't need to parse it. Anyone using PHP in serious prod uses something like memcached/opcache to skip parsing, which speeds up TTFB typically by about 200x.
- fogihujy 5y agoEven a bog standard LAMP setup has opcache enabled nowadays.
- progforlyfe 5y ago> the whole framework Files are autoloaded lazily, meaning only classes that are touched are loaded on any given request. If the code is split into well sized, purposeful modules, it becomes a non issue.
- jeltz 5y agoIt outperformed them in benchmarks but not in practice due to having to reload all libraries on every request.