Linly
Linly copied to clipboard
llama 编译错误
I llama.cpp build info:
I UNAME_S: Linux
I UNAME_P: x86_64
I UNAME_M: x86_64
I CFLAGS: -I. -O3 -std=c11 -fPIC -DNDEBUG -Wall -Wextra -Wpedantic -Wcast-qual -Wdouble-promotion -Wshadow -Wstrict-prototypes -Wpointer-arith -pthread -march=native -mtune=native
I CXXFLAGS: -I. -I./examples -O3 -std=c++11 -fPIC -DNDEBUG -Wall -Wextra -Wpedantic -Wcast-qual -Wno-unused-function -Wno-multichar -pthread -march=native -mtune=native
I LDFLAGS:
I CC: cc (GCC) 7.3.0
I CXX: g++ (GCC) 7.3.0
cc -I. -O3 -std=c11 -fPIC -DNDEBUG -Wall -Wextra -Wpedantic -Wcast-qual -Wdouble-promotion -Wshadow -Wstrict-prototypes -Wpointer-arith -pthread -march=native -mtune=native -c ggml.c -o ggml.o
ggml.c: 在函数‘ggml_vec_dot_q4_2_q8_0’中:
ggml.c:3253:40: 警告:implicit declaration of function ‘_mm256_set_m128’; did you mean ‘_mm256_set_epi8’? [-Wimplicit-function-declaration]
const __m256 d = _mm256_mul_ps(_mm256_set_m128(d1, d0), _mm256_broadcast_ss(&y[i].d));
^~~~~~~~~~~~~~~
_mm256_set_epi8
ggml.c:3253:40: 错误:‘_mm256_mul_ps’的第 1 个实参类型不兼容
In file included from /usr/lib/gcc/x86_64-linux-gnu/7.3.0/include/immintrin.h:41:0,
from ggml.c:189:
/usr/lib/gcc/x86_64-linux-gnu/7.3.0/include/avxintrin.h:317:1: 附注:需要类型‘__m256 {或称 __vector(8) float}’,但实参的类型为‘int’
_mm256_mul_ps (__m256 __A, __m256 __B)
^~~~~~~~~~~~~
ggml.c:3257:22: 警告:implicit declaration of function ‘_mm256_set_m128i’; did you mean ‘_mm256_set_epi8’? [-Wimplicit-function-declaration]
__m256i bx = _mm256_set_m128i(bx1, bx0);
^~~~~~~~~~~~~~~~
_mm256_set_epi8
ggml.c:3257:22: 错误:用‘int’初始化‘__m256i {或称 __vector(4) long long int}’时类型不兼容
make: *** [Makefile:185:ggml.o] 错误 1
本地环境是 Kylin10.x86_64环境。 请问编译不了是有什么方法可以解决?