Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7437089
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 29, 20262026-05-29T10:20:38+00:00 2026-05-29T10:20:38+00:00

According to Microsoft ( link ), there are two ways to start a task:

  • 0

According to Microsoft (link), there are two ways to start a task: Implicit and Explicit.

Assume that I created 4 different tasks in main thread called task1, task2, task3 and task4.

case1: I run them all, explicitly in main thread:

task1.Start();
task2.Start();
task3.Start();
task4.Start();

case2: I run them implicitly using Parallel.Invoke method in main thread:

Parallel.Invoke(task1, task2, task3, task4);

The only difference I noticed is that in case2, the main thread suspends until Invoke( ) returns.

My question is about the Task scheduler.
Does the task scheduler behave 4 tasks in case1 and case2 differently in terms of scheduling or they are completely equivalent ?

in the same link I have mentioned above we read:

Behind the scenes, tasks are queued to the ThreadPool, which has been
enhanced with algorithms (like hill-climbing) that determine and
adjust to the number of threads that maximizes throughput. This makes
tasks relatively lightweight, and you can create many of them to
enable fine-grained parallelism. To complement this, widely-known
work-stealing algorithms are employed to provide load-balancing.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-29T10:20:39+00:00Added an answer on May 29, 2026 at 10:20 am

    This blog post from the Parallel team should answer some of your questions.

    Short answer: with Tasks you will have to do a Task::WaitAll(…) on your main thread to prevent from exiting where as Parallel::Invoke will actually take care of this for you. Beyond that, nothing else because the same TPL infrastructure is used under Parallel::Invoke.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

According to the 'Microsoft Office Word™ 2003 Visual Basic Reference', it seems the Document
According to http://msdn.microsoft.com/en-us/library/aa916070.aspx (DnsQuery_W), DNS query libraries are available on Windows Mobile / CE
According to [MSDN: Array usage guidelines]( http://msdn.microsoft.com/en-us/library/k2604h5s(VS.71).aspx) : Array Valued Properties You should use
According to the UserNamePasswordValidator sample on http://msdn.microsoft.com/en-us/library/system.identitymodel.selectors.usernamepasswordvalidator.aspx one should throw a SecurityTokenException if the
According to the FAQ to GoDaddy they support SignTool from Microsoft, but mage.exe isn't
First off, according to http://msdn.microsoft.com/en-us/library/x0b5b5bc.aspx , the List.Find method is only listed as throwing
I have a question regarding a window style hexadecimal. According to http://support.microsoft.com/kb/111011/en-us , 0x16CF0000
According to this discussion , the iphone agreement says that it doesn't allow loading
According to the documentation, they're pretty much interchangeable. Is there a stylistic reason to
According to wikipedia! http://en.wikipedia.org/wiki/ORDBMS IBM's DB2, Oracle database, and Microsoft SQL Server, make claims

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.