Parallel Extensions

In the Parallel Extensions (parallel extensions), also known as Parallel Framework Extensions ( PFX ) is a library to support concurrent programming using the Managed Code in the Microsoft. NET framework. The Parallel Extensions basically consist of two parts: Parallel LINQ (PLINQ ) and the Task Parallel Library (TPL). The library has different data types ( referenced objects ) and functions for the management and control of parallel processes during the term. The library first appeared ( as a CTP) on November 29, 29 in 2007 and was updated in December 2007 and June 2008. Since version 4.0 of the. NET framework are the Parallel Extensions integral part of the framework and can be used in all. NET languages ​​.

Parallel LINQ

Parallel LINQ (PLINQ ) offers the ability to run LINQ queries in parallel, provided that it can create a time advantage ( SpeedUp ) compared with a sequential search. Either multiple LINQ queries are called parallel or carrying amount of data even in parallel together. The target PLINQ here is to minimize the computing time for the queries. In general, the parallel with all types of queries work. PLINQ can be used via the interface IParallelEnumerable. Internally, PLINQ uses the TPL for parallelization.

Task Parallel Library

The Task Parallel Library (TPL ) is the core component for parallelization within the. NET framework. The TPL detects possible parallel Tasks (tasks) by means of certain sections of the code (such as grinding as For or ForEach ). The TPL can be forced further for other tasks. The developers themselves have to worry neither about the management of individual threads or the number of processor cores, as this is completely managed by the TPL.

The TPL also makes it possible to mask certain areas as a task or futures. A task is a section of the ( thus in parallel ) can be performed from the rest of the program independently. The TPL created on this its own thread, which is managed by the TPL itself and thus no unnecessary overhead (as he is otherwise required) generated.

Future as a task is referred to, which returns a result which has been calculated in a parallel process. The result is then kept at completion until it is retrieved. If the result can be queried before completion, the requesting thread is suspended until the result has been calculated.

TPL may be used via the parallel class. This class provides three static methods:

Architecture

The concept of the Parallel Extensions to. NET is based on divide certain sections of code in a task. This task represents one of the other parts of the program as independent as possible task. Both PLINQ and the TPL API provide methods available to define appropriate tasks. Created PLINQ automated tasks from the queries, while the TPL from the above Grinding tasks generated.

633131
de