I agree very much... perhaps we need an update/patch on the cfmx compiler
for intelligent parsing. here is the straight Java code that i compiled
using J2SE 1.4.1 RC (http://java.sun.com/j2se/) and this gave
me the exact same results as CFMX *.jsp (*20ms*).. was impressed with this.
/*****************/
public class JavaScale{
public static void main(String args[]){
long sms,ems,vnum=0;
sms=System.currentTimeMillis();
for(int x=1;x<=1000000;x++)
{vnum=vnum+x;}
ems=System.currentTimeMillis();
System.out.println(vnum);
System.out.println(sms);
System.out.println(ems);
System.out.println("Elapsed Time:"+ (ems-sms));
}
}
/*******************/
CFMX *.java code looks kinda ugly.. man!
for
(X.set(((java.lang.Object)("1")));_compare(this._autoscalarize(X),1000000.0)
<=0;X.set(coldfusion.runtime.Cast._Object((coldfusion.runtime.Cast._double(t
his._autoscalarize(X)))+(1.0)))){{
Z.set(coldfusion.runtime.Cast._Object((coldfusion.runtime.Cast._double(this.
_autoscalarize(Z)))+(coldfusion.runtime.Cast._double(this._autoscalarize(X))
)));
}
Are there any known issues if we leave this set to *true*
<param-name>coldfusion.compiler.saveJava</param-name>
<param-value>true</param-value>
This is good info.
Thanks
Joe
> -----Original Message-----
> From: Dick Applebaum [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, September 17, 2002 12:33 PM
> To: CF-Talk
> Subject: Re: FW: Jsp Vs Cfm (CFMX) -- Test Code
>
>
> Ya'know, in the olden days of maimframes, and CoBOL, RPG, etc, they
> used to resolve this sort of problem with an "Optimizing" compiler.
>
> The Optimzer would perform another pass (either pre or
> post-compilation) and try to optimize the code --- especially
> subroutines and loops (and other high-potential code).
>
> It seems that something of that order would be useful here (especially
> going from an untyped language to a strongly-typed language).
>
> The Optimizer could look for key words (for, do, etc,) and make some
> intelligent guesses about the variables involved, or better yet,
> substitute an optimized, precompiled, code block for the user-specified
> code.
>
> Again, I don't know much Java, but it seems that CF ought to be able to
> generate something much closer to the jsp code.
>
> Maybe this is an opportunity -- CFMX plugin anyone?
>
> Dick
>
>
> On Tuesday, September 17, 2002, at 09:06 AM, Dick Applebaum wrote:
>
> > here's the critical piece of gen'd Java code:
> >
> > STIME.set(coldfusion.runtime.Cast._Object(this.GetTickCount()));
> > for
> > (X.set(((java.lang.Object)("1")));_compare(this._autoscalarize(X),10000
> > 0
> > 0.0)<=0;X.set(coldfusion.runtime.Cast._Object((coldfusion.runtime.Cast.
> > _
> > double(this._autoscalarize(X)))+(1.0)))){{
> >
> > Z.set(coldfusion.runtime.Cast._Object((coldfusion.runtime.Cast._double(
> > t
> > his._autoscalarize(Z)))+(coldfusion.runtime.Cast._double(this._autoscal
> > a
> > rize(X)))));
> > }
> > }
> > ETIME.set(coldfusion.runtime.Cast._Object(this.GetTickCount()));
> >
> > Kind of Ugly!
> >
> > Dick
> >
> >
>
______________________________________________________________________
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists