One o' th' major changes in Drupal 6 (where "major" is defined as "worthy o' a mention in Dries' keynote") were bein' a new feature o' th' menu an' theme hooks. The newly introduced "file" an' "file path" keys in those hooks' respective retun arrays. allow them t' define files that get included conditionally, only when needed. In theory, that should be a big performance boost; page handlers be virtually no nay ne'er called except fer on th' page they handle, so loadin' all o' that code on every other page is a waste o' CPU cycles. Of course, thar is also th' added cost o' th' extra disk hit t' load that one extra file we need. Modern operatin' systems should do a pretty good job o' cachin' th' file load, but that may vary with th' configuration.
So just how much benefit did we get from two dozen fragile patches that were a glorified cut an' paste? And is it worth doin' more o' it? Let's benchmark it an' find out.
The day is nearly upon us! Drupal 7 will open up developers to PHP 5 functionality when it is released next year. Already, there is talk of how, and if, to leverage PHP 5's object handling now that we don't need to deal with the weirdness of PHP 4's object model. Of course, because it's Drupal, our army of performance czars want to know just what the cost is for object handling, and especially advanced object magic like __get(), __call(), the ArrayAccess interface, and so forth.
So let's find out. :-)