what would be a good hardware spec and server configuration to have 5000 users do long polling with a php backend?
PHP is in any case a better choice, performance-wise, than Python or, god forbid, Java.
All just to make PHP a little faster. I think you are making my case.
Many websites don't ever get to 350M users, so it's safe to say that plain PHP will satisfy your startup for a long time. Also, PHP7 is pretty much on par with HHVM in real-world scenarios: https://kinsta.com/blog/the-definitive-php-7-final-version-h...
[Maybe it was just a joke and I did not get it... or I did get it but did not identify it as a joke... however... I would like to see some beef...]