On Apr 22, 7:11 pm, Jon Harrop <[EMAIL PROTECTED]> wrote:
> On Tuesday 22 April 2008 18:45:28 Richard Warburton wrote:
>
> > Could you please provide the source code for this performance comparison.
>
> Sure. The Java:
>
> public class test
> {
>     int foo(int n)
>     {
>       return n - 1;
>     }
>
>     void bar()
>     {
>     }
>
>     void baz()
>     {
>     }
>
>     void run()
>     {
>         Exception e = new Exception("");

The scores change quite dramatically if I change this to:

    Exception e = new Exception("") {
      @Override
      public synchronized Throwable fillInStackTrace() {
        return this;
      }
    };

From an average of 850 to an average of 50.

Regards,
Ismael
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "JVM 
Languages" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/jvm-languages?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to