Giter Site home page Giter Site logo

Not totally fair about skynet HOT 8 OPEN

atemerev avatar atemerev commented on September 26, 2024
Not totally fair

from skynet.

Comments (8)

defectus avatar defectus commented on September 26, 2024 1

@ochrons Totally agree. Just because you call something async doesn't mean it is in fact async! And that's why the node version is so fast - it just does the calculation without any overhead that is normally associated with concurrent programing (IPC, thread management etc.).

from skynet.

megri avatar megri commented on September 26, 2024

Also, the C# example uses Task which are similar to Scala Future. Actors — at least how they are envisioned in Scala — are constructs which encapsulate accessible state in a concurrent environment. There is no need for accessible state in these examples so the overhead is probably unnecessary.

from skynet.

wizzard0 avatar wizzard0 commented on September 26, 2024

Yep, IMHO Go, C# and Haskell examples are close (task-based), so are Erlang and Akka ones (actor-based). There's a PR with Future-based Scala example, need to measure that :)

from skynet.

jadbox avatar jadbox commented on September 26, 2024

The Node example using Promises also puts it into an entirely different category. It would be better to use the async module for Node or use the Cluster feature (although that creates an entirely new process).

from skynet.

ochrons avatar ochrons commented on September 26, 2024

Yeah, Node version is not concurrent at all. If we allow for that, all examples would be quite different and probably perform better since the actual "computation" is a no-op.

from skynet.

kdex avatar kdex commented on September 26, 2024

As for Node's asynchrony: Note that you're actually benchmarking a Promise library, not native promises.

from skynet.

joshburgess avatar joshburgess commented on September 26, 2024

I think the README should be updated to remove the word actors. C# Tasks are not actors, which makes the following sentence inaccurate and misleading:

"Creates an actor (goroutine, whatever), which spawns 10 new actors, each of them spawns 10 more actors, etc. until one million actors are created on the final level."

Actors and async tasks are not the same thing.

Something like actors do exist in the .NET world in the Orleans framework, but they are different than what's found in Akka or Erlang. For more info on Orleans' "Virtual Actors":

https://github.com/akka/akka-meta/blob/master/ComparisonWithOrleans.md

http://daprlabs.com/blog/blog/2014/04/03/microsoft-orleans-why-its-cool-useful/

For that matter, Goroutines and Elixir/Erlang processes are also a bit different from each other

Anyway, like others have said, it doesn't make sense to compare Tasks/Futures/Promises/etc. with Actors/Virtual Actors/Goroutines/Erlang processes, as they aren't really doing the same things.

from skynet.

shashwata avatar shashwata commented on September 26, 2024

One another thing I noticed was the delay in Akka test runs were mainly due to GC. I increased the JVM memory and ran the tests again and I got better performance. @atemerev, can you please the memory consumed by each implementation so that we understand we were not too unfair with JVM.

from skynet.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.