Skip to content

Commit 73d13ad

Browse files
authored
ggml : expose SSE3 and SSSE3 for MSVC when AVX is available (#2128)
1 parent b6680fa commit 73d13ad

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

ggml-impl.h

+7
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,16 @@ extern "C" {
3737
#ifndef __F16C__
3838
#define __F16C__
3939
#endif
40+
#endif
41+
42+
// __SSE3__ and __SSSE3__ are not defined in MSVC, but SSE3/SSSE3 are present when AVX/AVX2/AVX512 are available
43+
#if defined(_MSC_VER) && (defined(__AVX__) || defined(__AVX2__) || defined(__AVX512F__))
4044
#ifndef __SSE3__
4145
#define __SSE3__
4246
#endif
47+
#ifndef __SSSE3__
48+
#define __SSSE3__
49+
#endif
4350
#endif
4451

4552
// 16-bit float

0 commit comments

Comments
 (0)