#include <simddetect.h>
Definition at line 31 of file simddetect.h.
◆ IsAVX2Available()
static bool tesseract::SIMDDetect::IsAVX2Available |
( |
| ) |
|
|
inlinestatic |
Definition at line 38 of file simddetect.h.
39 return detector.avx2_available_;
◆ IsAVX512BWAvailable()
static bool tesseract::SIMDDetect::IsAVX512BWAvailable |
( |
| ) |
|
|
inlinestatic |
Definition at line 46 of file simddetect.h.
47 return detector.avx512BW_available_;
◆ IsAVX512FAvailable()
static bool tesseract::SIMDDetect::IsAVX512FAvailable |
( |
| ) |
|
|
inlinestatic |
Definition at line 42 of file simddetect.h.
43 return detector.avx512F_available_;
◆ IsAVXAvailable()
static bool tesseract::SIMDDetect::IsAVXAvailable |
( |
| ) |
|
|
inlinestatic |
Definition at line 34 of file simddetect.h.
35 return detector.avx_available_;
◆ IsFMAAvailable()
static bool tesseract::SIMDDetect::IsFMAAvailable |
( |
| ) |
|
|
inlinestatic |
Definition at line 50 of file simddetect.h.
51 return detector.fma_available_;
◆ IsSSEAvailable()
static bool tesseract::SIMDDetect::IsSSEAvailable |
( |
| ) |
|
|
inlinestatic |
Definition at line 54 of file simddetect.h.
55 return detector.sse_available_;
◆ Update()
void tesseract::SIMDDetect::Update |
( |
| ) |
|
|
static |
Definition at line 174 of file simddetect.cpp.
177 const char* dotproduct_method =
"generic";
178 if (!strcmp(dotproduct.c_str(),
"auto")) {
180 }
else if (!strcmp(dotproduct.c_str(),
"generic")) {
182 SetDotProduct(DotProductGeneric);
183 dotproduct_method =
"generic";
184 }
else if (!strcmp(dotproduct.c_str(),
"native")) {
187 dotproduct_method =
"native";
188 #if defined(HAVE_AVX2)
189 }
else if (!strcmp(dotproduct.c_str(),
"avx2")) {
192 dotproduct_method =
"avx2";
194 #if defined(HAVE_AVX)
195 }
else if (!strcmp(dotproduct.c_str(),
"avx")) {
198 dotproduct_method =
"avx";
200 #if defined(HAVE_FMA)
201 }
else if (!strcmp(dotproduct.c_str(),
"fma")) {
204 dotproduct_method =
"fma";
206 #if defined(HAVE_SSE4_1)
207 }
else if (!strcmp(dotproduct.c_str(),
"sse")) {
210 dotproduct_method =
"sse";
212 }
else if (!strcmp(dotproduct.c_str(),
"std::inner_product")) {
214 SetDotProduct(DotProductStdInnerProduct);
215 dotproduct_method =
"std::inner_product";
218 tprintf(
"Warning, ignoring unsupported config variable value: dotproduct=%s\n",
220 tprintf(
"Support values for dotproduct: auto generic native"
221 #
if defined(HAVE_AVX)
224 #
if defined(HAVE_SSE4_1)
227 " std::inner_product.\n");
230 dotproduct.set_value(dotproduct_method);
The documentation for this class was generated from the following files: