PHP performance: accelerators and HTTP servers
First, which is the fastest accelerator: XCache or APC?
And should I have nginx, lighttpd, Apache or Apache with nginx as a reverse proxy for static contents. What's better?
There is no general answer on this. It depends on what you need. I always choose APC for new projects. I used XCache but I think APC is better for the following reasons.
So pure performance is not everything :)
APC is more user friendly and gives you better hit miss stats. XCache is about the same in performance but not as stable. It really depends on your server and what your running on it. You need to benchmark different scenarios and find your sweet spot. For my WordPress installation on a VPS with 768M Ram I got the best results using an Nginx reverse proxy static cache along with Memcached. Here is the bench to get an idea of what I achieved with this set up:
$ ab -n 1000 -c 100
yielded 1712.33 requests per second