Re: Class Autoloading
Marcel van der Boom <[email protected]> Fri, 24 Jul 2009 10:00:58 +0200
| Newsgroups | gmane.comp.cms.xaraya.devel |
|---|---|
| Message-ID | <[email protected]> |
On 23 jul 2009, at 19:46, [email protected] wrote: > ... but the point is > that using the autoload mechanism automatically ensures that only > what's > actually needed is loaded. Like the consistent use of interfaces, > saves > us from ourselves... One thing to keep in mind perhaps is performance. The rationale for the import method back then was speed, nothing more, nothing less. There should be some notes of my benchmarking on mailing lists or in repository. At the time autoload was so buggy it was not even worth considering, this may have improved (it should). The penalty for autoloading (apart from some ad-hoc naming convention) is that the system has /some/ information on where to look for certain classes, to be used at the time a class is not found as opposed to the /exact/ information sys::import provides. I have no idea what the search time penalty for that is, but it may be worth benchmarking that, at least for the common inclusion routes. I remember being somewhat surprised by the 'include_once vs include' penalty back then, as in that it was much higher than i had thought. marcel -- Marcel van der Boom -- http://hsdev.com/mvdb.vcf HS-Development BV -- http://www.hsdev.com So! web applications -- http://make-it-so.info Cobra build -- http://cobra.mrblog.nl _______________________________________________ Xaraya_devel mailing list [email protected] http://xaraya.com/mailman/listinfo/xaraya_devel