1 / 11

virtual techdays

INDIA │ 9-11 February 2011. virtual techdays. Parallelism in .NET 4.0. Parag Paithankar │ Technology Advisor - Web , Microsoft India. INDIA │ 9-11 February 2011. virtual techdays. What and Why of Parallelism Threading: From There to Now Exploring The Task Parallel Library (TPL)

nile
Download Presentation

virtual techdays

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. INDIA │ 9-11 February2011 virtual techdays Parallelism in .NET 4.0 Parag Paithankar│ Technology Advisor - Web, Microsoft India

  2. INDIA │ 9-11 February2011 virtual techdays • What and Why of Parallelism • Threading: From There to Now • Exploring The Task Parallel Library (TPL) • Quick introduction Task Factories and Task Schedulers and why we need them? • Diagnostics tools in Visual Studio 2010 • Summary • Q&A S E S S I O N A G E N D A

  3. INDIA │ 9-11 February2011 virtual techdays • What is Parallelism? • The ability to run multiple tasks in Parallel without really worrying about the underlying synchronization and management of threads • Why do we need it? • Computers have evolved from single core to multiple cores • Software needs to take advantage of this • Splitting larger jobs in smaller chunks (across cores) increasing performance and scalability together What and Why of Parallelism

  4. INDIA │ 9-11 February2011 virtual techdays • Scenario 1: • There: Threading but not Threading • Windows Messaging technique • Scenario 2: • There: Threading for Performance • Scenario 3: • Now: Threading with managed synchronization • ThreadPool • Scenario 4: • Now! Tasks across cores! • Imperative Task Parallelism: System.Threading.Tasks • Imperative Data Parallelism: Parallel.For, Parallel.ForEach • Declarative Data Parallelism: PLINQ (AsParallel) Threading: From There to Now

  5. INDIA │ 9-11 February2011 virtual techdays Parallel Programming Architecture

  6. INDIA │ 9-11 February2011 virtual techdays • Set of Public Types and APIs in • System.Threading • System.Threading.Tasks • Enables scalability by leveraging multiple cores • TPL: • Handles work partitioning • Thread Scheduling (ThreadPool) • Cancellation support • State Management Exploring the Task Parallel Library (TPL)

  7. INDIA │ 9-11 February2011 virtual techdays • Imperative Task Parallelism • Create and run tasks implicitly using Parallel.Invoke • Explicitly using Tasks objects • Imperative Data Parallelism • Parallel.For and Parallel.ForEach loops • Declarative Data Parallelism • PLINQ Components of TPL

  8. INDIA │ 9-11 February2011 virtual techdays • Task Factories • Exists in Task.TaskFactory in System.Threading • Creates Task Objects which can be started immediately • Manage Task Waits– Task continuation • Use for TPL with classic Async Programming models • Task Schedulers • Exists in Task.TaskScheduler in System.Threading • Ensures that Tasks complete • Based on ThreadPool Quick introduction Task Factories and Task Schedulers and why we need them?

  9. INDIA │ 9-11 February2011 virtual techdays • New Windows in Debugger: • Parallel Tasks • Parallel Stacks Visual Studio 2010 support for Parallelism

  10. INDIA │ 9-11 February2011 virtual techdays • Parallel Computing Resources on MSDN • http://msdn.microsoft.com/en-us/concurrency/default RESOURCES

  11. THANKS│ 9-11 February2011 virtual techdays paragp@microsoft.com │ blogs.msdn.com/parag

More Related