Skip to content

PHP and NodeJS Benchmark with 512 concurrency. How PHP wins? #8170

Answered by joanhey
indramal asked this question in Q&A
Discussion options

You must be logged in to vote

In reality the difference is bigger. Because the spectre/meldown/retbleed mitigations affected the Xeon Gold in the citrine servers.
And Nginx is very affected for that. We are waiting the new servers, with new CPUs.

Php-ngx is not the normal PHP + Nginx, it's using ngx-php that is a PHP lib embedded in Nginx.
The normal php with Nginx is at number 6, and now have only 9K req/s more than Nodejs. In round 18, before the mitigations, normal PHP was ~40K req/s faster than Nodejs.

When Nodejs use the database, drop drastically.
And Workerman (php from cli without server) or Ngx-php are a lot faster than Nodejs in all tests.

Normal PHP with Nginx, using Fastcgi never will be faster than Nodejs…

Replies: 3 comments 15 replies

Comment options

You must be logged in to vote
7 replies
@indramal
Comment options

@ishtms
Comment options

@joanhey
Comment options

@joanhey
Comment options

@indramal
Comment options

Answer selected by indramal
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
8 replies
@joanhey
Comment options

@masfahru
Comment options

@masfahru
Comment options

@joanhey
Comment options

@masfahru
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
5 participants