Version Information¶
[configuration.version_information]
oneAPI Threading Building Blocks has macros, an environment variable, and a function that reveal version and run-time information.
// Defined in header <tbb/version.h>
#define TBB_VERSION_MAJOR /*implementation-defined*/
#define TBB_VERSION_MINOR /*implementation-defined*/
#define TBB_VERSION_STRING /*implementation-defined*/
#define TBB_INTERFACE_VERSION_MAJOR /*implementation-defined*/
#define TBB_INTERFACE_VERSION_MINOR /*implementation-defined*/
#define TBB_INTERFACE_VERSION /*implementation-defined*/
const char* TBB_runtime_version();
int TBB_runtime_interface_version();
Version Macros
oneTBB defines macros related to versioning, as described below.
TBB_VERSION_MAJORmacro defined to integral value that represents major library version.TBB_VERSION_MINORmacro defined to integral value that represents minor library version.TBB_VERSION_STRINGmacro defined to the string representation of the full library version.TBB_INTERFACE_VERSIONmacro defined to current interface version. The value is a decimal numeral of the formxyyzwherexis the major interface version number andyis the minor interface version number. This macro is increased in each release.TBB_INTERFACE_VERSION_MAJORmacro defined toTBB_INTERFACE_VERSION/1000that is, the major interface version number.TBB_INTERFACE_VERSION_MINORmacro defined toTBB_INTERFACE_VERSION%1000/10that is, the minor interface version number.
TBB_runtime_interface_version Function¶
Function that returns the interface version of the oneTBB library that was loaded at runtime.
The value returned by TBB_runtime_interface_version() may differ from the value of
TBB_INTERFACE_VERSION obtained at compile time. This can be used to identify whether an
application was compiled against a compatible version of the TBB headers.
In general, the run-time value TBB_runtime_interface_version() must be greater than
or equal to the compile-time value of TBB_INTERFACE_VERSION. Otherwise the application may fail to
resolve all symbols at run time.
TBB_runtime_version Function¶
Function that returns the version string of the oneTBB library that was loaded at runtime.
The value returned by TBB_runtime_version() may differ from the value of
TBB_VERSION_STRING obtained at compile time.
TBB_VERSION Environment Variable¶
Set the environment variable TBB_VERSION to 1 to cause the library to print information on
stderr. Each line is of the form “TBB: tag value”, where tag and value provides additional
library information below.
Caution
This output is implementation specific and may change at any time.