Utilize program counter-relative offsets to simplify X86_32_PICASM code. In order for this to work with nasm, data constants are placed in the text segment. Extend support for X86_32_PICASM to all routines and enable disabled routines.
Showing the changes to test/encoder/EncUT_EncoderMbAux.cpp (1 of 4 files). Show all
Unified · Split
| @@ -222,7 +222,6 @@ TEST (EncodeMbAuxTest, WelsDctFourT4_avx2) { · 221 unmodified lines | |||
| 222 | } | 222 | } |
| 223 | #endif //HAVE_AVX2 | 223 | #endif //HAVE_AVX2 |
| 224 | 224 | ||
| 225 | #ifndef X86_32_PICASM | ||
| 226 | TEST (EncodeMbAuxTest, WelsCalculateSingleCtr4x4_sse2) { | 225 | TEST (EncodeMbAuxTest, WelsCalculateSingleCtr4x4_sse2) { |
| 227 | CMemoryAlign cMemoryAlign (0); | 226 | CMemoryAlign cMemoryAlign (0); |
| 228 | ALLOC_MEMORY (int16_t, iDctC, 16); | 227 | ALLOC_MEMORY (int16_t, iDctC, 16); |
| @@ -236,7 +235,6 @@ TEST (EncodeMbAuxTest, WelsCalculateSingleCtr4x4_sse2) { · 7 unmodified lines | |||
| 236 | FREE_MEMORY (iDctC); | 235 | FREE_MEMORY (iDctC); |
| 237 | FREE_MEMORY (iDctS); | 236 | FREE_MEMORY (iDctS); |
| 238 | } | 237 | } |
| 239 | #endif //#ifndef X86_32_PICASM | ||
| 240 | #endif | 238 | #endif |
| 241 | 239 | ||
| 242 | void copy (uint8_t* pDst, int32_t iDStride, uint8_t* pSrc, int32_t iSStride, int32_t iWidth, int32_t iHeight) { | 240 | void copy (uint8_t* pDst, int32_t iDStride, uint8_t* pSrc, int32_t iSStride, int32_t iWidth, int32_t iHeight) { |
| @@ -304,11 +302,9 @@ TEST (EncodeMbAuxTest, WelsGetNoneZeroCount_c) { · 61 unmodified lines | |||
| 304 | TestGetNoneZeroCount (WelsGetNoneZeroCount_c); | 302 | TestGetNoneZeroCount (WelsGetNoneZeroCount_c); |
| 305 | } | 303 | } |
| 306 | #ifdef X86_ASM | 304 | #ifdef X86_ASM |
| 307 | #ifndef X86_32_PICASM | ||
| 308 | TEST (EncodeMbAuxTest, WelsGetNoneZeroCount_sse2) { | 305 | TEST (EncodeMbAuxTest, WelsGetNoneZeroCount_sse2) { |
| 309 | TestGetNoneZeroCount (WelsGetNoneZeroCount_sse2); | 306 | TestGetNoneZeroCount (WelsGetNoneZeroCount_sse2); |
| 310 | } | 307 | } |
| 311 | #endif | ||
| 312 | TEST (EncodeMbAuxTest, WelsGetNoneZeroCount_sse42) { | 308 | TEST (EncodeMbAuxTest, WelsGetNoneZeroCount_sse42) { |
| 313 | if (WelsCPUFeatureDetect (0) & WELS_CPU_SSE42) | 309 | if (WelsCPUFeatureDetect (0) & WELS_CPU_SSE42) |
| 314 | TestGetNoneZeroCount (WelsGetNoneZeroCount_sse42); | 310 | TestGetNoneZeroCount (WelsGetNoneZeroCount_sse42); |