Keeping Async Methods Alive

Consider a type that will print out a message when it’s finalized, and that has a Dispose method which will suppress finalization: class DisplayOnFinalize : IDisposable {     public void Dispose() { GC.SuppressFinalize(this); }     ~DisplayOnFinalize() { Console.WriteLine(“Finalized”); } } Now consider a simple usage of this class: void Foo() {     var tcs =… Read more

What’s New For Parallelism in .NET 4.5

.NET 4 and Visual Studio 2010 saw the introduction of a wide range of new support for parallelism: the Task Parallel Library (TPL), Parallel LINQ (PLINQ), new synchronization and coordination primitives and collections (e.g. ConcurrentDictionary), an improved ThreadPool for handling parallel workloads, new debugger windows, new concurrency visualizations, and more. Since then, we’ve been hard… Read more

Concurrency Visualizer: A Case Study

Boby George and Pooja Nagpal – testers on the Parallel Computing Platform team responsible for the parallel programming support in .NET 4- built a parallel spell checker algorithm and used the Concurrency Visualizer to analyze and improve the performance and scalability of their implementation. Optimizing Parallel Applications Using Concurrency Visualizer: A Case Study demonstrates how the… Read more

Lesser-known Multi-threaded Debugging Support in Visual Studio 2010

We’ve been very excited about the new debugging windows in Visual Studio 2010, namely Parallel Tasks and Parallel Stacks, as well as the newly revamped Threads window, and thus we’ve talked about them quite a bit. For an overview, you can read the MSDN Magazine article at http://msdn.microsoft.com/en-us/magazine/ee410778.aspx, and Daniel Moth has a larger collection… Read more