> Not so fast there cowboy.  :)  The 200 mili and 400 mili 
> numbers were 1 million loops of a 4-faceted cfif and cfswitch 
> structure respectively comparing string values on CF8.
> 
> That same test on CF7.0.2 yields 1 second for the cfif and 
> 115 seconds (nearly two minutes!) for cfswitch.  Good luck 
> trying to blame two minutes of page load time on network delays.  :)
> 
> Do many people use 1 million cfif's or cfswitch's on a page?  
> Probably not. 
> Truth is though; there is at least one documented case where 
> a large number of cfswitch's on CF7 was literally bringing 
> down someone's server until they converted them to cfif's.  
> 
> The problem may not affect everyone, but it's worth noting as 
> opposed to writing it off IMO.

I have to say, I fully agree with Sean here, and disagree with you.

If ANYONE uses one million of ANYTHING in a single program, that person has
bigger problems than optimization choices. CF is simply not the appropriate
platform for a million operations of anything in a single program. That's
not what it's for. If you have those kind of requirements, use something
else - Java comes to mind - and invoke it from CF.

A completely unrealistic test tells you how to optimize for completely
unrealistic environments. What's more, the optimization won't apply
universally to similar unrealistic environments in the future, because the
internals of CF (and other CFML interpreters/compilers) change frequently
enough to make your optimization choice fail in other versions.

"premature optimization is the root of all evil":
http://en.wikipedia.org/wiki/Optimization_(computer_science)#Quotes

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/

Fig Leaf Software provides the highest caliber vendor-authorized
instruction at our training centers in Washington DC, Atlanta,
Chicago, Baltimore, Northern Virginia, or on-site at your location.
Visit http://training.figleaf.com/ for more information!


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Get involved in the latest ColdFusion discussions, product
development sharing, and articles on the Adobe Labs wiki.
http://labs/adobe.com/wiki/index.php/ColdFusion_8

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:293661
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

Reply via email to