I have implemented generating text strings as char arrays, with a compiler option to turn it on and off, and did some timings on the benchmark. Just as I suspected, the benchmark did not show much performance difference, when the option was turned on and then off.
Now I am wondering if there is any value in committing my change. :( -Kin-man > Date: Mon, 08 Sep 2003 15:18:34 -0700 (PDT) > From: Kin-Man Chung <[EMAIL PROTECTED]> > Subject: Re: AW: [5.0] JSP performance ... > To: [EMAIL PROTECTED] > Content-MD5: +Y/z1F8l8EXxpI9LL3yPSA== > > I took a look at o.a.j.runtime.JspWriterImpl and the methods > > write(String s, int off, int len) > and > write(char cbuf[], int off, int len) > > in particualr, and failed to see any performance gain of the 2nd over the > first. They are very similar, the only different is that the first uses > String.getChars while the second uses System.arraycopy, but those two > methods should be on par in terms of performance. That is, I don't see > any extra unnecessary copies. > > Perhasp the culprit is those extra writes? > > -Kin-man > > > Date: Mon, 08 Sep 2003 23:03:19 +0200 > > From: Remy Maucherat <[EMAIL PROTECTED]> > > Subject: Re: AW: [5.0] JSP performance ... > > To: Tomcat Developers List <[EMAIL PROTECTED]> > > > > Kin-Man Chung wrote: > > > This seems easy enough to implement, so I'll look into it. Concatenating > > > texts is also on my list, and it should help a little in this case. > > > > That would be awesome. > > The test had a *lot* of writes, so this would save hundreds of write > > invocations (as well as making them faster as it would user char arrays). > > > > JSP performance should be really good with that change. > > > > Remy > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]