Upload
llangit
View
3.217
Download
2
Tags:
Embed Size (px)
DESCRIPTION
Best of PDC08, parallel programming and F# introductions
Citation preview
Lynn Langit – Developer Evangelisthttp://blogs.msdn.com/SoCalDevGal
Daniel Moth - Parallel Computing Platformhttp://www.danielmoth.com/Blog
Luca Bolognesehttp://blogs.msdn.com/lucabol/
Parallel Pattern Library
Resource Manager
Task Scheduler
Task Parallel Library
PLINQ
Managed Library Native Library
ThreadsThreadsOperating System
Concurrency Runtime
Programming Models
AgentsLibrary
ThreadPool
Task SchedulerTask Scheduler
Resource ManagerResource Manager
Data Structures
Dat
a St
ruct
ures
Integrated Tooling
Tools
ParallelDebugger
Toolwindows
Profiler Concurrency
Analysis
Programming Models
Concurrency Runtime
Program Thread
Program Thread
CLR Thread Pool
GlobalQueue
Worker Thread 1
Worker Thread p
CLR Thread Pool: Work-Stealing
Worker Thread 1
Worker Thread p
Program Thread
Program Thread
GlobalQueue
LocalQueue
LocalQueue
Task 1Task 1Task 2Task 2
Task 3Task 3Task 5Task 5Task 4Task 4
Task 6Task 6
ThreadPoolThreadPoolThreadPool.QueueUserWorkItem(…);
System.Threading.Tasks
Task.StartNew(…);Starting
var p = Task.StartNew(() => { var t = Task.StartNew(…);});
Parent/Child
var f = Future.StartNew(() => C());…int result = f.Value;
Tasks with resultsTask t = Task.StartNew(…);
Task p = t.ContinueWith(…);t.Wait(2000);t.Cancel();
Continue/Wait/Cancel
var q = from p in people where p.Name == queryInfo.Name && p.State == queryInfo.State && p.Year >= yearStart && p.Year <= yearEnd orderby p.Year ascending select p;
Area Descriptions Example Scenarios
Imperative Data Parallelism
Apply the same operation to common collections/sets in parallel. Looping, data partitioning, reductions, scans, etc.
Medical imagingBond pricing
Task Parallelism Simultaneously perform multiple independent operations. Divide-and-conquer, tasks, threads, fork/join, futures, etc.
Process control automation
Shared Resources Building blocks for implementing concurrent components. Scalable and thread-safe collections, locks, etc.
Middle-tier configuration/state management
Declarative Data Parallelism
Define what computation needs to be done, without the how. Selections, filters, joins, aggregations, groupings, etc.
Statistical modeling
Coordination Exploit latent operations by doing work while waiting for data. Asynch I/O, async interaction points, message passing, etc.
Streaming audio
Task Parallel LibraryTask Parallel LibraryParallel Pattern LibraryParallel Pattern LibraryOpenMP, Cluster SOAOpenMP, Cluster SOA
Coordination Data StructuresCoordination Data StructuresTransactional MemoryTransactional Memory
MPI, MPI.net, CCRMPI, MPI.net, CCRNative Agents and MessagingNative Agents and Messaging
MaestroMaestro
PLINQPLINQ
www.microsoftpdc.comhttp://msdn.com/concurrency
Visual Studio 2010 &Visual Studio 2010 & Framework 4.0Framework 4.0
all PDC sessionsOverview - why and how parallelismPLINQ screencastOther Ch9 PLINQ screencastsPLINQ MSDN articleMSDN concurrencyVS 2010 on Ch9VS 2010 weekParallel Computing - VisionDaniel Moth blog
•Fewer side effects•More opportunities for parallelism•Used for advanced computation, math, data mining, financial•More concise, fewer bugs
• Improvements to the F# research release
April 2008 Microsoft Research
refresh release
• Broadly improved VS 2008 integration• Simplifications in language and libraries
Just ReleasedSeptember 2008
CTP
• Full product-quality release• Fully stable and supported language• Aligned with future VS releases
2009Supported Release
F# tutorials
F# MSDN Developer Center
F# for Windows Azure
F# Samples
Expert F# book and code samples
• On the Web:• http://fsharp.net
• Books:
Thanks vets!