PHP Benchmark: include() vs file_get_contents()

Read Original

This article details a performance benchmark test comparing PHP's include() and file_get_contents() functions for reading files, specifically in the context of building a page caching plugin. The author explains the test setup, initial results showing include() as slower, and the significant performance improvement of include() when leveraging PHP's opcode cache on subsequent runs.

PHP Benchmark: include() vs file_get_contents()

Comments

No comments yet

Be the first to share your thoughts!

Browser Extension

Get instant access to AllDevBlogs from your browser

Top of the Week