1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495 |
- #if !defined(X86CPU_H)
- # define X86CPU_H
- # if defined(OPUS_X86_MAY_HAVE_SSE)
- # define MAY_HAVE_SSE(name) name ## _sse
- # else
- # define MAY_HAVE_SSE(name) name ## _c
- # endif
- # if defined(OPUS_X86_MAY_HAVE_SSE2)
- # define MAY_HAVE_SSE2(name) name ## _sse2
- # else
- # define MAY_HAVE_SSE2(name) name ## _c
- # endif
- # if defined(OPUS_X86_MAY_HAVE_SSE4_1)
- # define MAY_HAVE_SSE4_1(name) name ## _sse4_1
- # else
- # define MAY_HAVE_SSE4_1(name) name ## _c
- # endif
- # if defined(OPUS_X86_MAY_HAVE_AVX)
- # define MAY_HAVE_AVX(name) name ## _avx
- # else
- # define MAY_HAVE_AVX(name) name ## _c
- # endif
- # if defined(OPUS_HAVE_RTCD)
- int opus_select_arch(void)
- # endif
- # if defined(__clang__) || !defined(__OPTIMIZE__)
- # define OP_CVTEPI8_EPI32_M32(x) \
- (_mm_cvtepi8_epi32(_mm_cvtsi32_si128(*(int *)(x))))
- # else
- # define OP_CVTEPI8_EPI32_M32(x) \
- (_mm_cvtepi8_epi32(*(__m128i *)(x)))
- #endif
- # if defined(__clang__) || !defined(__OPTIMIZE__)
- # define OP_CVTEPI16_EPI32_M64(x) \
- (_mm_cvtepi16_epi32(_mm_loadl_epi64((__m128i *)(x))))
- # else
- # define OP_CVTEPI16_EPI32_M64(x) \
- (_mm_cvtepi16_epi32(*(__m128i *)(x)))
- # endif
- #endif
|