1) The actorsystem creation is in the outer loop (VM warmup), your claim is 
not true, re-using the actor system does not change the results, as each Pi 
computation task is >500 ms, so actor system creation is neglectible 
(<1ms). Note that one iteration refers to a complete concurrent 
multiple-slice Pi calculation. I am looping only to get correct VM warmup 
and measure the average duration of last 10 runs.

2) I can see that Akka makes use of all CPU's. From a users point of view, 
the benchmark is about handling many small computation jobs (pi-computation 
slices) in concurrent with contention created when assembling the result. 
This is the original AKKA sample on how to do this.

Am Dienstag, 7. Januar 2014 12:49:08 UTC+1 schrieb hschoeneberg:
>
> Hey Rüdiger,
>
> you should probably reconsider your application's design: 
>
> In your calculate()-method you keep creating ActorSystems and spawn an 
> actor responsible for the actual computation. You should prefer creating 
> and keeping one ActorSystem for your benchmark and just spawn an actor to 
> handle your calculation request (i.e. your master). After completing the 
> calculation you let the actor die. This alone would probably boost the 
> performance. Also: There is no 1:1 correlation between actors and threads, 
> you can create way more actors which - depending on the dispatcher - use a 
> given thread pool for execution. 
>
> Kind regards,
> Hendrik
>
> Am Dienstag, 7. Januar 2014 01:26:11 UTC+1 schrieb Rüdiger Möller:
>>
>> Please checkout chart here.
>>
>> https://plus.google.com/109956740682506252532/posts/1hKcYyPuJzh
>>
>> [cut&pasted from g+]:
>> Hey  folks, i am currently writing a blog benchmarking akka vs 
>> traditional threading. I use the example provided by the akka java tutorial 
>> computing Pi. In order to compare the abillity to paralellize big amounts 
>> of tiny jobs, i use Pi-computaional slices of 100,000 jobs with iteration 
>> of 1000. 
>> Hardware is dual socket AMD opteron with each 8 real cores and 8 
>> 'virtual' (because the test uses floating point i just scale to 16 threads 
>> instead of 32).
>>
>> As you can see in the chart AKKA (2.03) performs very bad compared to 
>> threads and a homebrew actor lib.
>>
>> source of akka bench is here: 
>> https://gist.github.com/RuedigerMoeller/8272966
>> (added outer loop to original typesafe sample)
>>
>> Is there anything I miss or is this 'normal' Akka performance ?
>>
>> Threading-style code is here: 
>> https://gist.github.com/RuedigerMoeller/8273307
>>
>> I tried 2.1 with even worse results. 
>>
>> http://imgur.com/TAt9XOf
>>
>

-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: http://akka.io/faq/
>>>>>>>>>>      Search the archives: https://groups.google.com/group/akka-user
--- 
You received this message because you are subscribed to the Google Groups "Akka 
User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to