Apcu is useful also. It's basically the same idea, but exposed to your own code. That is, an mmap() based cache that you can use to store state between requests. Somewhat like how people use redis or memcached, but typically faster since there's no networked api call.