Shallow Dive PFX

Loading...

Flash Player 9 (or above) is needed to view presentations.
We have detected that you do not have it on your computer. To install it, go here.

0 comments

Post a comment

    Post a comment
    Embed Video
    Edit your comment Cancel

    Favorites, Groups & Events

    Shallow Dive PFX - Presentation Transcript

    1. Shallow Dive: Parallel Fx Alex Moore Software Developer, TDCI
    2. No More Free Lunch Processors not getting much faster
    3. No More Free Lunch transistors++
    4. No More Free Lunch transistors++ speed++
    5. No More Free Lunch transistors++ speed++
    6. No More Free Lunch transistors++ speed++ cores++
    7. Elephant in the Room
    8. Elephant in the Room Parallel / Concurrent Programming is about to reach it’s boiling point
    9. Elephant in the Room Can’t ignore it much longer
    10. Elephant in the Room There will be language, library, and tool support for this soon. There will be language, library, tool, and hardware support for this soon. Concurrency is one of the main themes for C# 4.0, the PFX will probably be part of .Net 4.0, Visual Studio 2010 will have tools to help better debug concurrent programs, and Intel’s next Core processor, the i7, will have a whole slew of improvements to help run concurrent and threaded applications better.
    11. Parallel Extensions to the .Net Framework PLINQ C D Task Parallel Library S Scheduler System.Threading
    12. How to Express Parallelism
    13. How to Express Parallelism Threading sucks
    14. How to Express Parallelism Declarative data parallelism - PLINQ
    15. How to Express Parallelism Declarative data parallelism - PLINQ Imperative data parallelism - Parallel.For
    16. How to Express Parallelism Declarative data parallelism - PLINQ Imperative data parallelism - Parallel.For Imperative task parallelism - Tasks, Futures
    17. PLINQ from x in set where x == somevalue select expensiveFunction(x);
    18. PLINQ from x in set where x == somevalue select expensiveFunction(x); from x in set.AsParallel() where x == somevalue select expensiveFunction(x);
    19. Parallel.For for( int i = 0; i < 10; i++ ) { ... }
    20. Parallel.For for( int i = 0; i < 10; i++ ) { ... } Parallel.For( 0, 10, i => { ... } );
    21. Parallel.ForEach foreach( var x in set ) { ... }
    22. Parallel.ForEach foreach( var x in set ) { ... } Parallel.ForEach( set, x => {...});
    23. Tasks A(); B(); C(); Do_Something();
    24. Tasks Task t1 = Task.Create( ()=> A(); ); Task t2 = Task.Create( ()=> B(); ); Task t3 = Task.Create( ()=> C(); ); Task.WaitAll(t1, t2, t3); Do_Something();
    25. Futures var a = A(); var b = B(); var c = C(); Do_Something(a,b,c);
    26. Futures var a = Future.Create( ()=> A(); ); var b = Future.Create( ()=> B(); ); var c = Future.Create( ()=> C(); ); Do_Something(a,b,c);
    27. Demos
    28. Box of Sharp Knives PFX is a big box of sharp knives. Yes they are shiny and you want to grab them but be careful.
    29. Box of Sharp Knives ★ Not a silver bullet for performance This should not be your first choice for improving performance. Clean “responsible” design will go a long way when optimizing code, and will help when deciding where to apply concurrency.
    30. Box of Sharp Knives ★ Not a silver bullet for performance ✓ Get the CTP ✓ Read, Do, and Learn This should not be your first choice for improving performance. Clean “responsible” design will go a long way when optimizing code, and will help when deciding where to apply concurrency.
    31. Questions? Comments ? Are there any questions ? Comments ?
    32. How to find info • MSDN Magazine - October ‘08 • Channel 9 - “Parallel Extensions” • Blogs: Joe Duffy, Herb Sutter • http://geekswithblogs.net/alexmoore/ archive/2008/10/22/parallel-extensions- links.aspx
    33. Thanks! Alex Moore Blog: geekswithblogs.net/alexmoore Twitter: @alexmoore

    + Alex MooreAlex Moore, 2 years ago

    custom

    406 views, 0 favs, 0 embeds more stats

    This is my 10 minute introduction to The Parallel E more

    More info about this document

    © All Rights Reserved

    Go to text version

    • Total Views 406
      • 406 on SlideShare
      • 0 from embeds
    • Comments 0
    • Favorites 0
    • Downloads 0
    Most viewed embeds

    more

    All embeds

    less

    Flagged as inappropriate Flag as inappropriate
    Flag as inappropriate

    Select your reason for flagging this presentation as inappropriate. If needed, use the feedback form to let us know more details.

    Cancel
    File a copyright complaint
    Having problems? Go to our helpdesk?

    Categories