1 / 17

F# for Parallel and Asynchronous Programming

FT20. F# for Parallel and Asynchronous Programming. Luke Hoban F# Program Manager Microsoft Corporation. F#: Productive, Functional, Scalable. demo . Luke Hoban F# Program Manager Microsoft. Parallel Computing and PDC09. Tools. Managed Languages. Visual F#. Axum. Visual Studio 2010.

pooky
Download Presentation

F# for Parallel and Asynchronous Programming

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. FT20 F# for Parallel and Asynchronous Programming Luke Hoban F# Program Manager Microsoft Corporation

  2. F#: Productive, Functional, Scalable demo Luke Hoban F# Program Manager Microsoft

  3. Parallel Computing and PDC09 Tools Managed Languages Visual F# Axum Visual Studio 2010 Parallel Debugger Windows Native Libraries Managed Libraries DryadLINQ Async AgentsLibrary Parallel Pattern Library • Profiler Concurrency • Analysis Parallel LINQ Rx Task ParallelLibrary Data Structures Data Structures Microsoft Research Native Concurrency Runtime Task Scheduler Race Detection Managed Concurrency Runtime Resource Manager ThreadPool Fuzzing Operating System HPC Server Threads UMS Threads Windows 7 / Server 2008 R2 Research / Incubation Visual Studio 2010 / .NET 4 Operating System Key:

  4. Shared State Four Big Concurrency Challenges • Inversion of Control • I/O Parallelism • Scaling to multi-machine

  5. Shared State Concurrency Challenges • Inversion of Control • Difficult to maintain and test • Very difficult to parallelize! • Locking is fundamentally error prone: • Must guess where parallelism will be needed • All consumers need to participate • I/O Parallelism • Scaling to Multi-Machine

  6. F#: Immutability and Functional Programming demo Luke Hoban F# Program Manager Microsoft

  7. Shared State Concurrency Challenges • Inversion of Control • We’re used to writing code linearly • Async requires decoupling Begin from End • Very difficult to • Combine multiple asynchronous operations • Deal with exceptions and cancellation • I/O Parallelism • Scaling to Multi-Machine

  8. Shared State Concurrency Challenges • Inversion of Control • I/O Parallelism • Software is often I/O-bound • Leveraging web services • Working with data on disk • Network and disk speeds increasing slower • I/O resources are inherently parallel • Huge opportunity for performance • Scaling to Multi-Machine

  9. F#: async { … } demo Luke Hoban F# Program Manager Microsoft

  10. Shared State Concurrency Challenges • Inversion of Control • I/O Parallelism • To scale up, must to go beyond a single machine • Multi-machine resources becoming common • Roll-you-own clusters with cheap hardware • On-demand cloud compute with Azure • But • Shared memory doesn’t scale • Scaling to Multi-Machine

  11. F#: Agents and Azure demo Luke Hoban F# Program Manager Microsoft

  12. Shared State • immutability Recap: Some Concurrency Challenges • Inversion of Control • async { … } • I/O Parallelism • async { … } • Scaling to Multi-Machine • agents

  13. In Summary

  14. YOUR FEEDBACK IS IMPORTANT TO US! Please fill out session evaluation forms online at MicrosoftPDC.com

  15. Learn More On Channel 9 • Expand your PDC experience through Channel 9 • Explore videos, hands-on labs, sample code and demos through the new Channel 9 training courses channel9.msdn.com/learn Built by Developers for Developers….

More Related