Showing results for .NET 4 - .NET Parallel Programming

Mar 2, 2010
0
0

FAQ :: Parallel.ForEach and non-generic collections?

Danny Shih
Danny Shih

.NET 2.0 introduced Generics to allow enhanced code reusability and type safety.  Since then, generic collections (IEnumerable<T>, List<T>, Dictionary<T>, etc.) have become standard and are recommended over their non-generic counterparts (IEnumerable, ArrayList, HashTable, etc.).  As a result, Parallel.ForEach only suppo...

Parallel ExtensionsTask Parallel Library.NET 4
Feb 15, 2010
0
0

Parallel patterns in Visual Basic

Stephen Toub - MSFT
Stephen Toub - MSFT

I previously posted in November about a paper I'd written on patterns for parallel programming.  The original paper had over 200 snippets of C# code to demonstrate and exemplify the ideas being discussed.  Due to popular demand (and in honor of the many Visual Basic MVPs on campus this week for the MVP Summit), we've now posted another ve...

Parallel Extensions.NET 4
Feb 11, 2010
0
0

FAQ :: Which .NET language is best for parallelism?

Danny Shih
Danny Shih

The new parallelization support in the .NET Framework 4 is implemented purely in libraries and the runtime and does not require special compiler support.  Therefore, it is available to all compliant .NET languages.  This includes all of the managed languages that ship as part of Visual Studio 2010 (Visual C#, Visual Basic, Visual F#, and ...

Parallel Extensions.NET 4FAQ
Feb 10, 2010
0
0

F# PowerPack supports PLINQ

Stephen Toub - MSFT
Stephen Toub - MSFT

The F# team has released the F# PowerPack for download on CodePlex, and we're very excited that the PowerPack now has direct support for PLINQ.  From the CodePlex site: F# Parallel LINQ IntegrationFSharp.PowerPack.Parallel.dll provides an F#-style API for parallel operations on sequences that are part of .NET 4.0 as System.Linq.ParallelEnumera...

Parallel Extensions.NET 4PLINQ
Feb 10, 2010
0
0

“Parallelism in .NET” Series by Reed Copsey, Jr.

Igor Ostrovsky - MSFT
Igor Ostrovsky - MSFT

Reed Copsey, Jr. has been writing a great series of articles on parallelism with the .NET Framework 4. The articles provide the insights of an expert developer who has been using parallelism with .NET to speed up real-world programs. Recommended reading.Parallelism in .NETIntroductionPart 1, Decomposition Par...

Parallel ExtensionsTask Parallel Library.NET 4
Feb 9, 2010
0
0

Maintaining a Consistent Application State with TPL

Zlatko Michailov - MSFT
Zlatko Michailov - MSFT

The aim of this post is to help developers writing applications in which operations may need to be performed and then later undone due to a subsequent failure. It shows a pattern for how to maintain such a consistent application state by utilizing functionality from the Task Parallel Library (TPL) in the .NET Framework 4. For the purposes of this ...

Task Parallel Library.NET 4Code Samples
Feb 7, 2010
0
0

Are you using Parallel Extensions? We’d love to know.

Stephen Toub - MSFT
Stephen Toub - MSFT

Are you using Parallel LINQ (PLINQ), the Task Parallel Library (TPL), or any of the new coordination and synchronization primitives in .NET 4 (or in the Parallel Extensions June 2008 CTP or with the recent Reactive Extensions release)?  Are you planning to use or are you already using this support in a production application or libra...

Parallel Extensions.NET 4
Jan 26, 2010
0
0

FAQ :: Are all of the new concurrent collections lock-free?

Danny Shih
Danny Shih

(This answer is based on the .NET Framework 4.  As the details below are undocumented implementation details, they may change in future releases.)No.  All of the collections in the new System.Collections.Concurrent namespace employ lock-free techniques to some extent in order to achieve general performance benefits, but traditional locks ...

.NET 4Coordination Data StructuresFAQ
Jan 8, 2010
0
1

ConcurrentDictionary’s support for adding and updating

Stephen Toub - MSFT
Stephen Toub - MSFT

ConcurrentDictionary<TKey,TValue> is a new type in the .NET Framework 4, living in the System.Collections.Concurrent namespace.  As noted in the MSDN documentation, ConcurrentDictionary “represents a thread-safe collection of key-value pairs that can be accessed by multiple threads concurrently.”  While ConcurrentDiction...

Parallel Extensions.NET 4Coordination Data Structures
Jan 5, 2010
0
0

FAQ :: Why is the speedup not X on my X-way machine?

Danny Shih
Danny Shih

We’ll be regularly posting answers to frequently asked questions that we’ve gotten on the forum, internal email lists, etc.  Here’s the first – enjoy! Why is the speedup not X on my X-way machine?  Or, why does my parallel code run slower?  Less than ideal speedup can typically be attributed to two things: 1.    &...

Parallel ExtensionsTask Parallel Library.NET 4