All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Macros | Typedefs | Variables
Configuration

Macros

#define BLAZE_INTERNAL_ASSERTION   0
 Compilation switch for internal assertions.This compilation switch triggers internal assertions, which are used to verify the program itself. The internal assertions can also be deactivated by defining NDEBUG during the compilation. More...
 
#define BLAZE_USER_ASSERTION   0
 Compilation switch for user assertions.This compilation switch triggers user assertions, which are used to check user specified function parameters and values. The user assertions can also be deactivated by defining NDEBUG during the compilation. More...
 
#define BLAZE_USE_FUNCTION_TRACES   0
 Compilation switch for function traces.This compilation switch triggers the use of function traces. In case the switch is set to 1, function traces via the BLAZE_FUNCTION_TRACE are enabled. Note however, that enabling function traces creates a dependency to the compiled Blaze library, i.e. it will be necessary to link the Blaze library to the executable. This is also true in case only template functionality is used! More...
 
#define BLAZE_USE_RESTRICT   1
 Compilation switch for C99 restrict keyword.This compilation switch enables/disables the C99 restrict keyword. More...
 
#define BLAZE_USE_VECTORIZATION   1
 Compilation switch for (de-)activation of the Blaze vectorization.This compilation switch enables/disables vectorization of mathematical expressions via the SSE, AVX, and/or MIC instruction sets. In case the switch is set to 1 (i.e. in case vectorization is enabled) ,the Blaze library attempts to vectorize the linear algebra operations by SSE, AVX, and/or MIC intrinsics (depending on which instruction set is available on the target platform). In case the switch is set to 0 (i.e. vectorization is disabled), the Blaze library chooses default, non-vectorized functionality for the operations. Note that deactivating the vectorization may pose a severe performance limitation for a large number of operations! More...
 

Typedefs

typedef double blaze::real
 Floating point data type of the Blaze library.This type definition offers the possibility to switch the floating point precision of the Blaze library between float, double and long double. More...
 
typedef boost::mt19937 blaze::RNG
 Type of the random number generator of the Blaze library.This type definition represents the type of the random number generated used in the Blaze library. The default random number generator is the boost::mt19937 mersenne-twister pseudo random number generator. For more information see the class description of the boost library: More...
 

Variables

const size_t blaze::cacheSize = 3145728UL
 Cache size of the target architecture.This setting specifies the available cache size in Byte of the used target architecture. Several algorithms use this setting for an optimized evaluation. More...
 
const LogLevel blaze::logging::loglevel = info
 Setting of the logging level.This value specifies the logging level of the Blaze logging functionality. Depending on this setting, more or less informations will be written to the log file(s). The following logging levels can be selected: More...
 
const bool blaze::logging::spacing = false
 Adding an additional spacing line between two log messages.This setting gives the opportunity to add an additional spacing line between two log messages to improve readability of log files. If set to true, each log message will be appended with an additional empty line. If set to false, no line will be appended.
 
const size_t blaze::solvers::maxIterations = 25000
 Maximum number of iterations of the mathematical solvers.This value specifies the default maximum number of iteration steps the mathematical solvers are performing for a single LSE or LCP problem. The choice of the number of iteration steps is a consideration between the accuracy of the solution and the time to solution: for a large number of iteration steps, the solution will be more accurate, whereas a small number will be considerably faster to calculate. For instance, an important property of the PGS solver is that the convergence speed of the approximated solution is strongly decreasing with a larger number of time steps. In order to noticeably improve the solution, the maximum number of time steps has to be considerably increased. More...
 
const real blaze::solvers::threshold = 5E-7
 Residuum threshold for the LSE/LCP solution of the mathematical solvers.This value specifies the threshold for the residuum calculation during a solution of a single LSE or LCP problem. The calculation stops as soon as the approximated solution meets the specified threshold value. The choice of the threshold value is a consideration between the accuracy of the solution and the time to solution: for a small threshold value (e.g. $ 1e-9 $), the solution will be more accurate, whereas a large threshold value (e.g. $ 1e-5 $) will be considerable faster. For instance, an important property of the PGS solver is that the convergance speed of the approximated solution is strongly decreasing with a larger number of time steps. The time to solution for a LCP calculation using a smaller threshold value will be noticeably larger.
 
const bool blaze::defaultStorageOrder = rowMajor
 The default storage order for all matrices of the Blaze library.This value specifies the default storage order for all matrices of the Blaze library. In case no explicit storage order is specified with the according matrix type, this setting is used. More...
 
const bool blaze::useStreaming = true
 Configuration of the streaming behavior.For large vectors and matrices non-temporal stores can provide a significant performance advantage of about 20%. However, this advantage is only in effect in case the memory bandwidth of the target architecture is maxed out. If the target architecture's memory bandwidth cannot be exhausted the use of non-temporal stores can decrease performance instead of increasing it. More...
 
const size_t blaze::DMATDVECMULT_THRESHOLD = 10000UL
 Row-major dense matrix/dense vector multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the row-major dense matrix/dense vector multiplication. In case the number of elements in the dense matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the dense matrix is smaller, the Blaze kernels are used. More...
 
const size_t blaze::TDMATDVECMULT_THRESHOLD = 10000UL
 Column-major dense matrix/dense vector multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the column-major dense matrix/dense vector multiplication. In case the number of elements in the dense matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the dense matrix is smaller, the Blaze kernels are used. More...
 
const size_t blaze::TDVECDMATMULT_THRESHOLD = 10000UL
 Dense Vector/row-major dense matrix multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the dense vector/row-major dense matrix multiplication. In case the number of elements in the dense matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the dense matrix is smaller, the Blaze kernels are used. More...
 
const size_t blaze::TDVECTDMATMULT_THRESHOLD = 10000UL
 Dense Vector/column-major dense matrix multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the dense vector/column-major dense matrix multiplication. In case the number of elements in the dense matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the dense matrix is smaller, the Blaze kernels are used. More...
 
const size_t blaze::DMATDMATMULT_THRESHOLD = 10000UL
 Row-major dense matrix/row-major dense matrix multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the row-major dense matrix/row-major dense matrix multiplication. In case the number of elements of the target matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the target matrix is smaller, the Blaze kernels are used. More...
 
const size_t blaze::DMATTDMATMULT_THRESHOLD = 10000UL
 Row-major dense matrix/column-major dense matrix multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the row-major dense matrix/column-major dense matrix multiplication. In case the number of elements of the target matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the target matrix is smaller, the Blaze kernels are used. More...
 
const size_t blaze::TDMATDMATMULT_THRESHOLD = 10000UL
 Column-major dense matrix/row-major dense matrix multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the column-major dense matrix/row-major dense matrix multiplication. In case the number of elements of the target matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the target matrix is smaller, the Blaze kernels are used. More...
 
const size_t blaze::TDMATTDMATMULT_THRESHOLD = 10000UL
 Column-major dense matrix/column-major dense matrix multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the column-major dense matrix/column-major dense matrix multiplication. In case the number of elements of the target matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the target matrix is smaller, the Blaze kernels are used. More...
 
const bool blaze::defaultTransposeFlag = columnVector
 The default transpose flag for all vectors of the Blaze library.This value specifies the default transpose flag for all vector of the Blaze library. In case no explicit transpose flag is specified with the according vector type, this setting is used. More...
 

Detailed Description

The configuration module offers the possibility to tune the Blaze library to the individual needs and requirements.

Macro Definition Documentation

#define BLAZE_INTERNAL_ASSERTION   0

Compilation switch for internal assertions.This compilation switch triggers internal assertions, which are used to verify the program itself. The internal assertions can also be deactivated by defining NDEBUG during the compilation.

Possible settings for the internal assertion switch:

  • Deactivated: 0
  • Activated : 1
#define BLAZE_USE_FUNCTION_TRACES   0

Compilation switch for function traces.This compilation switch triggers the use of function traces. In case the switch is set to 1, function traces via the BLAZE_FUNCTION_TRACE are enabled. Note however, that enabling function traces creates a dependency to the compiled Blaze library, i.e. it will be necessary to link the Blaze library to the executable. This is also true in case only template functionality is used!

Possible settings for the function trace switch:

  • Deactivated: 0 (default)
  • Activated : 1
#define BLAZE_USE_RESTRICT   1

Compilation switch for C99 restrict keyword.This compilation switch enables/disables the C99 restrict keyword.

Possible settings for the C99 restrict switch:

  • Deactivated: 0
  • Activated : 1
#define BLAZE_USE_VECTORIZATION   1

Compilation switch for (de-)activation of the Blaze vectorization.This compilation switch enables/disables vectorization of mathematical expressions via the SSE, AVX, and/or MIC instruction sets. In case the switch is set to 1 (i.e. in case vectorization is enabled) ,the Blaze library attempts to vectorize the linear algebra operations by SSE, AVX, and/or MIC intrinsics (depending on which instruction set is available on the target platform). In case the switch is set to 0 (i.e. vectorization is disabled), the Blaze library chooses default, non-vectorized functionality for the operations. Note that deactivating the vectorization may pose a severe performance limitation for a large number of operations!

Possible settings for the vectorization switch:

  • Deactivated: 0
  • Activated : 1 (default)
#define BLAZE_USER_ASSERTION   0

Compilation switch for user assertions.This compilation switch triggers user assertions, which are used to check user specified function parameters and values. The user assertions can also be deactivated by defining NDEBUG during the compilation.

Possible settings for the user assertion switch:

  • Deactivated: 0
  • Activated : 1

Typedef Documentation

typedef double blaze::real

Floating point data type of the Blaze library.This type definition offers the possibility to switch the floating point precision of the Blaze library between float, double and long double.

Valid types for the real floating point type: float, double, long double

typedef boost::mt19937 blaze::RNG

Type of the random number generator of the Blaze library.This type definition represents the type of the random number generated used in the Blaze library. The default random number generator is the boost::mt19937 mersenne-twister pseudo random number generator. For more information see the class description of the boost library:

http://www.boost.org/doc/libs/1_35_0/libs/random/random-generators.html#mersenne_twister
http://www.boost.org/doc/libs/1_35_0/boost/random/mersenne_twister.hpp

Variable Documentation

const size_t blaze::cacheSize = 3145728UL

Cache size of the target architecture.This setting specifies the available cache size in Byte of the used target architecture. Several algorithms use this setting for an optimized evaluation.

The size of the cache is specified in Byte. For instance, a cache of 3 MiByte must therefore be specified as 3145728.

const bool blaze::defaultStorageOrder = rowMajor

The default storage order for all matrices of the Blaze library.This value specifies the default storage order for all matrices of the Blaze library. In case no explicit storage order is specified with the according matrix type, this setting is used.

// Explicit specification of the storage order => row-major matrix
StaticMatrix<double,3UL,3UL,rowMajor> A;
// No explicit specification of the storage order => use of the defaultStorageOrder
StaticMatrix<double,3UL,3UL> B;

Valid settings for the defaultStorageOrder are blaze::rowMajor and blaze::columnMajor.

const bool blaze::defaultTransposeFlag = columnVector

The default transpose flag for all vectors of the Blaze library.This value specifies the default transpose flag for all vector of the Blaze library. In case no explicit transpose flag is specified with the according vector type, this setting is used.

// Explicit specification of the transpose flag => column vector
StaticVector<double,3UL,columnMajor> a;
// No explicit specification of the transpose flag => use of the defaultTransposeFlag
StaticVector<double,3UL> b;

Valid settings for the defaultTransposeFlag are blaze::rowVector and blaze::columnVector.

const size_t blaze::DMATDMATMULT_THRESHOLD = 10000UL

Row-major dense matrix/row-major dense matrix multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the row-major dense matrix/row-major dense matrix multiplication. In case the number of elements of the target matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the target matrix is smaller, the Blaze kernels are used.

The default setting for this threshold is 10000 (which for instance corresponds to a matrix size of $ 100 \times 100 $).

const size_t blaze::DMATDVECMULT_THRESHOLD = 10000UL

Row-major dense matrix/dense vector multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the row-major dense matrix/dense vector multiplication. In case the number of elements in the dense matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the dense matrix is smaller, the Blaze kernels are used.

The default setting for this threshold is 10000 (which for instance corresponds to a matrix size of $ 100 \times 100 $).

const size_t blaze::DMATTDMATMULT_THRESHOLD = 10000UL

Row-major dense matrix/column-major dense matrix multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the row-major dense matrix/column-major dense matrix multiplication. In case the number of elements of the target matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the target matrix is smaller, the Blaze kernels are used.

The default setting for this threshold is 10000 (which for instance corresponds to a matrix size of $ 100 \times 100 $).

const LogLevel blaze::logging::loglevel = info

Setting of the logging level.This value specifies the logging level of the Blaze logging functionality. Depending on this setting, more or less informations will be written to the log file(s). The following logging levels can be selected:

  • inactive: Completely deactives the logging functionality, i.e., no log file(s) will be written. Since this setting can immensely complicate error correction, it is not recommended to use this setting!
  • error : Only (severe) errors are written to the log file(s).
  • warning : Extends the error setting by warning messages.
  • info : Extends the warning setting by additional informative messages (default).
  • progress: Extends the info setting by progress informations.
  • debug : Extends the progress setting by debug information.
  • detail : Extends the debug setting by very fine grained detail information.
const size_t blaze::solvers::maxIterations = 25000

Maximum number of iterations of the mathematical solvers.This value specifies the default maximum number of iteration steps the mathematical solvers are performing for a single LSE or LCP problem. The choice of the number of iteration steps is a consideration between the accuracy of the solution and the time to solution: for a large number of iteration steps, the solution will be more accurate, whereas a small number will be considerably faster to calculate. For instance, an important property of the PGS solver is that the convergence speed of the approximated solution is strongly decreasing with a larger number of time steps. In order to noticeably improve the solution, the maximum number of time steps has to be considerably increased.

Possible settings for the maxIterations variable: $ [1..\infty) $

const size_t blaze::TDMATDMATMULT_THRESHOLD = 10000UL

Column-major dense matrix/row-major dense matrix multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the column-major dense matrix/row-major dense matrix multiplication. In case the number of elements of the target matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the target matrix is smaller, the Blaze kernels are used.

The default setting for this threshold is 10000 (which for instance corresponds to a matrix size of $ 100 \times 100 $).

const size_t blaze::TDMATDVECMULT_THRESHOLD = 10000UL

Column-major dense matrix/dense vector multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the column-major dense matrix/dense vector multiplication. In case the number of elements in the dense matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the dense matrix is smaller, the Blaze kernels are used.

The default setting for this threshold is 10000 (which for instance corresponds to a matrix size of $ 100 \times 100 $).

const size_t blaze::TDMATTDMATMULT_THRESHOLD = 10000UL

Column-major dense matrix/column-major dense matrix multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the column-major dense matrix/column-major dense matrix multiplication. In case the number of elements of the target matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the target matrix is smaller, the Blaze kernels are used.

The default setting for this threshold is 10000 (which for instance corresponds to a matrix size of $ 100 \times 100 $).

const size_t blaze::TDVECDMATMULT_THRESHOLD = 10000UL

Dense Vector/row-major dense matrix multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the dense vector/row-major dense matrix multiplication. In case the number of elements in the dense matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the dense matrix is smaller, the Blaze kernels are used.

The default setting for this threshold is 10000 (which for instance corresponds to a matrix size of $ 100 \times 100 $).

const size_t blaze::TDVECTDMATMULT_THRESHOLD = 10000UL

Dense Vector/column-major dense matrix multiplication threshold.This setting specifies the threshold between the application of the custom Blaze kernels and the BLAS kernels for the dense vector/column-major dense matrix multiplication. In case the number of elements in the dense matrix is equal or higher than this value, the BLAS kernels are prefered over the custom Blaze kernels. In case the number of elements in the dense matrix is smaller, the Blaze kernels are used.

The default setting for this threshold is 10000 (which for instance corresponds to a matrix size of $ 100 \times 100 $).

const bool blaze::useStreaming = true

Configuration of the streaming behavior.For large vectors and matrices non-temporal stores can provide a significant performance advantage of about 20%. However, this advantage is only in effect in case the memory bandwidth of the target architecture is maxed out. If the target architecture's memory bandwidth cannot be exhausted the use of non-temporal stores can decrease performance instead of increasing it.

Via this compilation switch streaming (i.e. non-temporal stores) can be (de-)activated. If set to true streaming is enabled, if set to false streaming is disabled.