ILOG CPLEX 11.0 Parameters Reference Manual > > Alphabetic List of Parameters > Parallel mode switch

C Name

CPX_PARAM_PARALLELMODE

C++ Name

ParallelMode

Java Name

ParallelMode

.NET Name

ParallelMode

InteractiveOptimizer

parallel

Identifier

1109

Description

Sets the parallel optimization mode. Possible modes are automatic, deterministic, and opportunistic.

In this context, deterministic means that multiple runs with the same model at the same parameter settings on the same platform will reproduce the same solution path and results. In contrast, opportunisitc implies that even slight differences in timing among threads or in the order in which tasks are executed in different threads may produce a different solution path and consequently different timings or different solution vectors during optimization executed in parallel threads. In multithreaded applications, the opportunistic setting entails less synchronization between threads and consequently may provide better performance.

By default, CPLEX applies as much parallelism as possible while still achieving deterministic results. That is, when you run the same model twice on the same platform with the same parameter settings, you will see the same solution and optimization run. This condition is referred to as the deterministic mode.

More opportunities to exploit parallelism are available if you do not require determinism. In other words, CPLEX can find more possibilities for parallelism if you do not require an invariant, repeatable solution path and precisely the same solution vector. To use all available parallelism, you need to select the opportunistic parallel mode. In this mode, CPLEX will utilize all opportunities for parallelism in order to achieve best performance.

However, in opportunistic mode, the actual optimization may differ from run to run, including the solution time itself and the path traveled in the search.

Deterministic and Sequential Optimization

A truly parallel deterministic algorithm is available only for MIP optimization.

Only opportunistic parallel algorithms (barrier and concurrent optimizers) are available for continuous models. (Each of the simplex algorithms runs sequentially on a continuous model.)

Consequently, when parallel mode is set to deterministic, both barrier and concurrent optimizers are restricted to run only sequentially, not in parallel.

Interaction with Threads Parameter

Settings of this parallel mode parameter interact with settings of the thread parameter (Threads, CPX_PARAM_THREADS) as summarized in Table 1, Table 2, and Table 3.

The default (automatic) setting of the parallel mode parameter allows CPLEX to choose between deterministic and opportunistic mode depending on the threads parameter. If the threads parameter is set to its automatic setting (the default), CPLEX chooses deterministic mode.

If the threads parameter is set to one, CPLEX runs sequentially in deterministic mode in a single thread.

Otherwise, if the threads parameter is set to a value greater than one, CPLEX chooses opportunistic mode.

Callbacks and MIP Optimization

If callbacks other than informational callbacks are used for solving a MIP, the order in which the callbacks are called cannot be guaranteed to remain deterministic, not even in deterministic mode. Thus, to make sure of deterministic runs when the parallel mode parameter is at its default setting, CPLEX will revert to sequential solving of the MIP in the presence of query callbacks, diagnostic callbacks, or control callbacks.

Consequently, if your application invokes query, diagnostic, or control callbacks, and you still prefer deterministic search, you can choose value 1 (one), overriding the automatic setting and turning on deterministic search. It is then your responsibility to make sure that your callbacks do not perform operations that could lead to opportunistic behavior and are implemented in a thread-safe way. To meet these conditions, your application must not store and must not update any information in the callbacks.

Determinism vs Opportunism

This parameter also allows you to turn off this default setting by choosing value -1 (minus one). Cases where you might wish to turn off deterministic search include situations where you want to take advantage of possibly faster performance of opportunistic parallel MIP optimization in multiple threads after you have confirmed that deterministic parallel MIP optimization produced the results you expected.

Values

Value 
Symbolic Constant 
Callable Library 
Symbolic Constant 
Concert Technology 
Meaning 
-1 
CPX_PARALLEL_OPPORTUNISTIC 
Opportunistic 
Enable opportunistic parallel search mode 
CPX_PARALLEL_AUTO 
AutoParallel 
Automatic: let CPLEX decide whether to invoke deterministic or opportunistic search, depending on the threads parameter; default 
CPX_PARALLEL_DETERMINISTIC 
Deterministic 
Enable deterministic parallel search mode 

See Also

CPX_PARAM_THREADS, Threads