Comment by e12e
12 hours ago
> as slow as PHP is.
Citation needed? I love hating PHP, but of the reasons I would chose something other than PHP, speed and resource consumption is pretty far down the list?
12 hours ago
> as slow as PHP is.
Citation needed? I love hating PHP, but of the reasons I would chose something other than PHP, speed and resource consumption is pretty far down the list?
PHP is sync. This means every IO operation i do runs sync. This is why PHP will always be the slowest ones out there. Open a file, SQL queries, sending emails etc. Its all sync. Its all slow.
PS. I fully aware of hacks around this like reactphp and the other related async things, but those are all just heavy dependencies and for most sane devs non starters.
Ok?
I must admit I haven't run the numbers, but if this can be trusted, sync PHP isn't far off from golang - while async does rather well?
I probably would only reach for PHP if I needed to run on shared hosting (or rather, my customers did) - in which case few other technologies would compete, obviously.
https://phpbenchlab.com/php-8-5-vs-nodejs-vs-go-vs-python-cp...