Parallelism? Async != Parallel?

A Task is just a task. It can run asynchronously with @async on the same thread or parallel with @spawn on parallel threads. Therefore the task mechanism is for #1 and #2.

Perhaps this is easier to understand if you think of @async and @spawn doing two things:

  1. both create a Task, then
  2. #1 starts it on the thread you are on, #2 starts it on one of all available threads.
7 Likes