Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/marian-nmt/intgemm.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMateusz Chudyk <mateuszchudyk@gmail.com>2019-05-28 21:00:14 +0300
committerMateusz Chudyk <mateuszchudyk@gmail.com>2019-05-28 21:07:00 +0300
commiteef4b641f37f0c2208ac63edde191bacf9d3e4f6 (patch)
treec3a3ef2aa5c409cd098728cd6e704a7d91a4ac79 /ssse3_gemm.h
parent93785f4292c002a5bb4bbdfd7358785562166500 (diff)
Outline quantize function
Diffstat (limited to 'ssse3_gemm.h')
-rw-r--r--ssse3_gemm.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/ssse3_gemm.h b/ssse3_gemm.h
index cf5d2c1..f7abbda 100644
--- a/ssse3_gemm.h
+++ b/ssse3_gemm.h
@@ -1,4 +1,5 @@
#pragma once
+
#include "types.h"
#include <cstdint>
#include <stdint.h>
@@ -11,10 +12,9 @@
namespace intgemm {
namespace ssse3 {
-// Same implementation as AVX512, just width. Grabs 4 32-bit values.
-//TODO duplicated function requires the removal of the annonymous namespace
+
INTGEMM_SSSE3 inline __m128i QuantizerGrab(const float *input, const __m128 quant_mult_reg) {
- return _mm_cvtps_epi32(_mm_mul_ps(*reinterpret_cast<const __m128*>(input), quant_mult_reg));
+ return quantize(*reinterpret_cast<const __m128*>(input), quant_mult_reg);
}
INTGEMM_SELECT_COL_B(INTGEMM_SSSE3, __m128i)