-
Notifications
You must be signed in to change notification settings - Fork 2.8k
CMakeOptionsForCustomCompilation
Ilya Lavrenov edited this page Dec 3, 2021
·
29 revisions
This document provides description and default values for CMake options that can be used to build a custom OpenVINO runtime using the open source version. For instructions on how to create a custom runtime from the prebuilt OpenVINO release package, refer to the deployment manager documentation. To understand all the dependencies when creating a custom runtime from the open source repository, refer to the Inference Engine Introduction.
- Disable / enable plugins build and other components
- Options affecting binary size
- Test capabilities
- Other options
- Inference backends:
-
ENABLE_MKL_DNNenables CPU plugin compilation:-
ONis default for x86 platforms;OFF, otherwise.
-
-
ENABLE_INTEL_GPUenables Intel GPU plugin compilation:-
ONis default for x86 platforms; not available, otherwise.
-
-
ENABLE_GNAenables GNA plugin compilation:-
ONis default for x86 platforms; not available, otherwise.
-
-
ENABLE_VPUenables VPU (Myriad and HDDL only) components build:-
ONis default.
-
-
ENABLE_MYRIADenables MYRIAD plugin build:-
ONis default.
-
-
ENABLE_HETEROenables HETERO plugin build:-
ONis default.
-
-
ENABLE_MULTIenables AUTO / MULTI plugin build:-
ONis default.
-
-
ENABLE_TEMPLATEenables TEMPLATE plugin build:-
ONis default.
-
-
- Frontends to work with models from frameworks:
-
NGRAPH_ONNX_FRONTEND_ENABLEenables ONNX frontend plugin for OpenVINO Runtime:-
ONis default.
-
-
NGRAPH_PDPD_FRONTEND_ENABLEenables PDPD frontend plugin for OpenVINO Runtime:-
ONis default.
-
-
NGRAPH_TF_FRONTEND_ENABLEenables TensorFlow frontend plugin for OpenVINO Runtime:-
ONis default.
-
-
NGRAPH_IR_FRONTEND_ENABLEenables OpenVINO Intermediate Representation frontend plugin for OpenVINO Runtime:-
ONis default.
-
-
-
ENABLE_GAPI_PREPROCESSINGenables G-API preprocessing:-
ONis default.
-
-
IE_EXTRA_MODULESspecifies path to add extra OpenVINO modules to the build.- See OpenVINO Contrib to add extra modules from.
-
ENABLE_SAMPLESenables Inference Engine samples build:-
ONis default.
-
-
ENABLE_PYTHONenables Python API build:-
OFFis default.
-
-
ENABLE_TESTSenables tests compilation:-
OFFis default.
-
-
ENABLE_IR_V7_READERenables IR v7 reader:-
ONis default. Note: must be turnedOFFwhen building OpenVINO runtime as static
-
-
NGRAPH_UNIT_TEST_ENABLEenables ngraph unit tests:- The value is the same as for the
ENABLE_TESTSoption.
- The value is the same as for the
-
ENABLE_DOCSenables building the OpenVINO documentation:-
OFFis default.
-
-
ENABLE_SYSTEM_PUGIXMLbuilds with system version of pugixml if it is available on the system.-
OFFis default. - Inference Engine thirdparty pugixml is used by default.
-
-
NGRAPH_USE_SYSTEM_PROTOBUFuse protobuf installed on the system:-
OFFis default. - Affects ONNX importer component only.
-
-
ENABLE_LTOboolean option to enable Link Time Optimizations:-
OFFis default, because it takes longer time to link binaries. -
ONis enabled for OpenVINO release binaries. - Available on Unix* compilers only like GCC or CLANG.
- Gives 30% decrease in binary size together with other optimization options used to build OpenVINO.
-
-
THREADINGpoints to the OpenVINO threading interface:-
TBBis the default option, which enables build with Intel TBB andtbb::static_partitioner. -
TBB_AUTOenables building with Intel TBB. -
OMPenables building with Intel OpenMP. -
SEQdisables threading optimizations. Can be used in cases when TBB binaries are absent. -
Note: because TBB is a template library, it increases binary size because of multiple instantiations of
tbb::parallel_for
-
-
ENABLE_TBBBIND_2_5enables prebuilt static TBBBind 2.5 usage:-
ONis default, because OpenVINO Runtime should be generic out of box.
-
Note: TBBBind 2.5 is needed when OpenVINO inference targets CPUs with:
- NUMA support (Non-Unified Memory Architecture), e.g. to detect a number of NUMA nodes
- Hybrid architecture to separate Performance/Efficiency cores and schedule tasks in the optimal way.
Note: if you build OpenVINO runtime with oneTBB support where TBBBind 2.5 is automatically loaded by TBB in runtime, then set
ENABLE_TBBBIND_2_5toOFF
-
ENABLE_SSE42enables SSE4.2 optimizations:-
ONis default for x86 platforms; not available for other platforms. - Affects only Inference Engine common part and preprocessing plugin, does not affect the mkldnn library
-
-
ENABLE_AVX2enables AVX2 optimizations:-
ONis default for x86 platforms, not available for other platforms. - Affects only Inference Engine common part and preprocessing plugin, does not affect the mkldnn library
-
-
ENABLE_AVX512Fenables AVX512 optimizations:-
ONis default for x86 platforms, not available for other platforms. - Affects only Inference Engine common part and preprocessing plugin, does not affect the mkldnn library
-
-
ENABLE_PROFILING_ITTenables profiling with Intel ITT and VTune.-
OFFis default, because it increases binary size.
-
-
SELECTIVE_BUILDenables Conditional compilation feature.-
OFFis default.
-
-
ENABLE_SANITIZERbuilds with clang address sanitizer support:-
OFFis default.
-
-
ENABLE_THREAD_SANITIZERbuilds with clang thread-sanitizer support:-
OFFis default.
-
-
ENABLE_COVERAGEadds option to enable coverage. See dedicated guide how to measure test coverage:-
OFFis default.
-
-
ENABLE_FUZZINGenables instrumentation of code for fuzzing:-
OFFis default.
-
-
ENABLE_CPPLINTenables code style check using cpplint static code checker:-
ONis default.
-
-
ENABLE_CLANG_FORMATenables Clang format code style check:-
ONis default. - Used only for ngraph component.
-
-
TREAT_WARNING_AS_ERRORtreats all warnings as an error:-
OFFis default.
-
-
ENABLE_FASTER_BUILDenables precompiled headers and unity build using CMake:-
OFFis default.
-
-
ENABLE_INTEGRITYCHECKbuilds DLLs with /INTEGRITYCHECK flag:-
OFFis default. - Available on MSVC compiler only.
-
© Copyright 2018-2024, OpenVINO team
- Home
- General resources
- How to build
-
Developer documentation
- Inference Engine architecture
- CPU plugin
- GPU plugin
- HETERO plugin architecture
- Snippets
- Sample for IE C++/C/Python API
- Proxy plugin (Concept)
- Tests