From 9a8a4dcb5e410bca1d9cf1082ea7c71c36edab63 Mon Sep 17 00:00:00 2001 From: Stefan Weil Date: Tue, 13 Jul 2021 22:29:17 +0200 Subject: [PATCH] Remove test code for fast float dotproduct Signed-off-by: Stefan Weil --- src/arch/intsimdmatrixavx2.cpp | 46 ---------------------------------- 1 file changed, 46 deletions(-) diff --git a/src/arch/intsimdmatrixavx2.cpp b/src/arch/intsimdmatrixavx2.cpp index c87ef414a7..c782ebb38c 100644 --- a/src/arch/intsimdmatrixavx2.cpp +++ b/src/arch/intsimdmatrixavx2.cpp @@ -21,52 +21,6 @@ # if defined(__i686__) || defined(__x86_64__) # error Implementation only for AVX2 capable architectures # endif -#elif defined(FAST_FLOAT) -namespace tesseract { - -static void matrixDotVector(int dim1, int dim2, const int8_t *wi, const float *scales, - const int8_t *u, float *v) { - const int num_out = dim1; - const int num_in = dim2 - 1; - for (int i = 0; i < num_out; ++i) { - for (int j = 0; j < num_in; ++j) { - } - } -} - -#if 0 -void IntSimdMatrix::MatrixDotVector(const GENERIC_2D_ARRAY &w, - const std::vector &scales, const int8_t *u, TFloat *v) { - int num_out = w.dim1(); - int num_in = w.dim2() - 1; - // Base implementation. - for (int i = 0; i < num_out; ++i) { - const int8_t *wi = w[i]; - int total = 0; - for (int j = 0; j < num_in; ++j) { - total += wi[j] * u[j]; - } - // Add in the bias and correct for integer values. - v[i] = (total + wi[num_in] * INT8_MAX) * scales[i]; - } -} -#endif - -static const IntSimdMatrix simdMatrix = { - // Function. - matrixDotVector, - // Number of 32 bit outputs held in each register. - 1, - // Maximum number of registers that we will use to hold outputs. - 1, - // Number of 8 bit inputs in the inputs register. - 1, - // Number of inputs in each weight group. - 1 -}; - -const IntSimdMatrix *IntSimdMatrix::intSimdMatrixAVX2 = &simdMatrix; -} #else # include # include