Caffe2 - C++ API
A deep learning, cross platform ML framework
common_avx2.cc
1 // This file is here merely to check that the flags are not mixed up: for
2 // example, if your compiler did not specify -mavx2, you should not provide
3 // the CAFFE2_PERF_WITH_AVX2 macro.
4 
5 #include "caffe2/core/common.h"
6 
7 #ifdef CAFFE2_PERF_WITH_AVX2
8 #ifndef __AVX2__
9 #error( \
10  "You found a build system error: CAFFE2_PERF_WITH_AVX2 is defined" \
11  "but __AVX2__ is not defined (via e.g. -mavx2).");
12 #endif // __AVX2__
13 #endif // CAFFE2_PERF_WITH_AVX2
14 
15 #ifdef __AVX2__
16 #ifndef CAFFE2_PERF_WITH_AVX2
17 #error( \
18  "You found a build system error: __AVX2__ is defined (via e.g. -mavx2) " \
19  "but CAFFE2_PERF_WITH_AVX2 is not defined.");
20 #endif // CAFFE2_PERF_WITH_AVX2
21 #endif