Skip to content

Commit 048eb34

Browse files
committed
Add missing static attribute to local inline functions
Signed-off-by: Stefan Weil <sw@weilnetz.de>
1 parent b73370a commit 048eb34

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/arch/intsimdmatrixavx2.cpp

+6-6
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,9 @@ constexpr int kNumInputGroups = kNumInputsPerRegister / kNumInputsPerGroup;
4747
// weights and reps are scratch registers.
4848
// This function must be inlined with references in order for the compiler to
4949
// correctly use the registers declared in the caller.
50-
inline void MultiplyGroup(const __m256i& rep_input, const __m256i& ones,
51-
const int8_t*& wi, __m256i& weights, __m256i& reps,
52-
__m256i& result) {
50+
static inline void MultiplyGroup(const __m256i& rep_input, const __m256i& ones,
51+
const int8_t*& wi, __m256i& weights,
52+
__m256i& reps, __m256i& result) {
5353
// Load a 4x8 block of weights.
5454
weights = _mm256_loadu_si256(reinterpret_cast<const __m256i*>(wi));
5555
wi += kNumInputsPerRegister;
@@ -71,9 +71,9 @@ inline void MultiplyGroup(const __m256i& rep_input, const __m256i& ones,
7171
// Extracts and converts 8x32-bit results from result, adding the bias from wi
7272
// and scaling by scales, before storing in *v. Note that wi, scales and v are
7373
// expected to contain 8 consecutive elements or num_out if less.
74-
inline void ExtractResults(__m256i& result, __m256i& shift_id,
75-
const int8_t*& wi, const double*& scales,
76-
int num_out, double*& v) {
74+
static inline void ExtractResults(__m256i& result, __m256i& shift_id,
75+
const int8_t*& wi, const double*& scales,
76+
int num_out, double*& v) {
7777
for (int out = 0; out < num_out; ++out) {
7878
int32_t res =
7979
#ifndef _MSC_VER

0 commit comments

Comments
 (0)