mirror of
https://github.com/tesseract-ocr/tesseract.git
synced 2025-01-24 03:23:04 +08:00
Add missing static attribute to local inline functions
Signed-off-by: Stefan Weil <sw@weilnetz.de>
This commit is contained in:
parent
b73370aac9
commit
048eb34934
@ -47,9 +47,9 @@ constexpr int kNumInputGroups = kNumInputsPerRegister / kNumInputsPerGroup;
|
|||||||
// weights and reps are scratch registers.
|
// weights and reps are scratch registers.
|
||||||
// This function must be inlined with references in order for the compiler to
|
// This function must be inlined with references in order for the compiler to
|
||||||
// correctly use the registers declared in the caller.
|
// correctly use the registers declared in the caller.
|
||||||
inline void MultiplyGroup(const __m256i& rep_input, const __m256i& ones,
|
static inline void MultiplyGroup(const __m256i& rep_input, const __m256i& ones,
|
||||||
const int8_t*& wi, __m256i& weights, __m256i& reps,
|
const int8_t*& wi, __m256i& weights,
|
||||||
__m256i& result) {
|
__m256i& reps, __m256i& result) {
|
||||||
// Load a 4x8 block of weights.
|
// Load a 4x8 block of weights.
|
||||||
weights = _mm256_loadu_si256(reinterpret_cast<const __m256i*>(wi));
|
weights = _mm256_loadu_si256(reinterpret_cast<const __m256i*>(wi));
|
||||||
wi += kNumInputsPerRegister;
|
wi += kNumInputsPerRegister;
|
||||||
@ -71,7 +71,7 @@ inline void MultiplyGroup(const __m256i& rep_input, const __m256i& ones,
|
|||||||
// Extracts and converts 8x32-bit results from result, adding the bias from wi
|
// Extracts and converts 8x32-bit results from result, adding the bias from wi
|
||||||
// and scaling by scales, before storing in *v. Note that wi, scales and v are
|
// and scaling by scales, before storing in *v. Note that wi, scales and v are
|
||||||
// expected to contain 8 consecutive elements or num_out if less.
|
// expected to contain 8 consecutive elements or num_out if less.
|
||||||
inline void ExtractResults(__m256i& result, __m256i& shift_id,
|
static inline void ExtractResults(__m256i& result, __m256i& shift_id,
|
||||||
const int8_t*& wi, const double*& scales,
|
const int8_t*& wi, const double*& scales,
|
||||||
int num_out, double*& v) {
|
int num_out, double*& v) {
|
||||||
for (int out = 0; out < num_out; ++out) {
|
for (int out = 0; out < num_out; ++out) {
|
||||||
|
Loading…
Reference in New Issue
Block a user