summaryrefslogtreecommitdiff
path: root/sgemm.cpp
diff options
context:
space:
mode:
authorIwan Kawrakow <iwan.kawrakow@gmail.com>2024-06-11 09:12:22 +0200
committerIwan Kawrakow <iwan.kawrakow@gmail.com>2024-06-22 12:02:50 +0300
commitad53eabf87816705f49501a54c7555c337bb47ce (patch)
treed5500fa26360272673c599eb6bbec4046023d806 /sgemm.cpp
parent3593891f390b376f7127efe3bd7eda9baffe6609 (diff)
iqk_mul_mat: be independent of llamafile_sgemm (WIP)
* Remove iqk_mul_mat from llamafile_sgemm * Pass tensor types and strides to iqk_mul_mat It is marked WIP because only tested on __aarch64__
Diffstat (limited to 'sgemm.cpp')
-rw-r--r--sgemm.cpp23
1 files changed, 0 insertions, 23 deletions
diff --git a/sgemm.cpp b/sgemm.cpp
index 409a9a67..c7189c61 100644
--- a/sgemm.cpp
+++ b/sgemm.cpp
@@ -51,9 +51,6 @@
#include "sgemm.h"
#include "ggml-impl.h"
#include "ggml-quants.h"
-#if GGML_USE_IQK_MULMAT
-#include "iqk_mul_mat.h"
-#endif
#ifdef _MSC_VER
#define NOINLINE __declspec(noinline)
@@ -868,26 +865,6 @@ bool llamafile_sgemm(int64_t m, int64_t n, int64_t k, const void *A, int64_t lda
if (Ctype != GGML_TYPE_F32)
return false;
-#if GGML_USE_IQK_MULMAT
-#if defined __AVX2__ && defined __FMA__
- bool is_accepted_float_type = k >= 32 &&
- ((Atype == GGML_TYPE_F16 && Btype == GGML_TYPE_F32) || (Atype == GGML_TYPE_F32 && Btype == GGML_TYPE_F16));
-#elif defined __ARM_FEATURE_FP16_VECTOR_ARITHMETIC && defined __ARM_FEATURE_FMA
- bool is_accepted_float_type = k >= 32 && Atype == GGML_TYPE_F16 && Btype == GGML_TYPE_F16;
-#else
- bool is_accepted_float_type = false;
-#endif
- if (task == GGML_TASK_TYPE_INIT && is_accepted_float_type) {
- return true;
- }
-
- if (task == GGML_TASK_TYPE_COMPUTE && is_accepted_float_type) {
- if (iqk_mul_mat(m, n, k, Atype, A, B, (float *)C, ldc, ith, nth)) {
- return true;
- }
- }
-#endif
-
switch (Atype) {
case GGML_TYPE_F32: {