ウノウラボの記事で知ったのですが、
requireはrequire_once()より3-4倍遅い?
空ファイルを forループで1万回呼んだ結果、4倍程度早かった。
元ネタでは
Ilia advises against using magic functions like __autoload() and __get(), but the advantage of __autoload() in particular is obvious in any large project and is used by many php frameworks. My primitive testing, however, shows inverse results. With a simply autoload requiring a class and 10000 loops of new Foo() versus require_once(‘foo.php’); new Foo() shows that __autoload() is ~3.7 times faster.
こう書かれています。うーむ。require_onceで読み込んでからnewしたほうが早いに違いないと思っていましたが、__autoloadなら内部処理で全て賄えるのを、require_onceをスクリプトで実行する分、オーバーヘッドができてしまうということなのでしょうか。これからは__autoloadを気兼ねなく使えそうです。