[aura-dev] Re: "map/reduce" speed

  • From: Jeffrey Alexander <jeff.alexander@sun.com>
  • To: dev@aura.kenai.com
  • Subject: [aura-dev] Re: "map/reduce" speed
  • Date: Mon, 22 Jun 2009 17:14:56 -0400

On Mon, 2009-06-22 at 16:58 -0400, François Maillet wrote:
> It's weird because the original version worked on my system.
> 
> But by casting to int in the process method, you can optimizing it  
> further by changing the collect function to this :
> 
> def collect(results):
>      return sum(results.toArray())

Done.  The result is pretty much the same.  It does seem like this runs
faster than the JavaScript version, although this is just based on
running several times and seeing the numbers.  The Python seems to take
about 110ms whereas the JavaScript takes about 120ms.  Since this all
involves compiling code down to the JVM, I'd guess that the 10ms may be
lost in invoking the compiler.

> Might help for the benchmark.

That change didn't make a difference.  It almost certainly ends up as
the same bytecodes.

Jeff





[aura-dev] "map/reduce" speed

Jeffrey Alexander 06/22/2009

[aura-dev] Re: "map/reduce" speed

Paul Lamere 06/22/2009

[aura-dev] Re: Re: "map/reduce" speed

Stephen Green 06/22/2009

[aura-dev] Re: Re: Re: "map/reduce" speed

Jeffrey Alexander 06/22/2009

[aura-dev] Re: Re: "map/reduce" speed

Jeffrey Alexander 06/22/2009

[aura-dev] Re: Re: Re: "map/reduce" speed

Paul Lamere 06/22/2009

[aura-dev] Re: Re: Re: "map/reduce" speed

François Maillet 06/22/2009

[aura-dev] Re: "map/reduce" speed

Jeffrey Alexander 06/22/2009

[aura-dev] Re: Re: "map/reduce" speed

François Maillet 06/22/2009

[aura-dev] Re: "map/reduce" speed

Jeffrey Alexander 06/22/2009
  • Mysql
  • Glassfish
  • Jruby
  • Rails
  • Nblogo
Terms of Use; Privacy Policy;
© 2010, Oracle Corporation and/or its affiliates
(revision 20120518.3c65429)
 
 
Close
loading
Please Confirm
Close