1
0
Fork 0

x86/hevc: use DECLARE_ALIGNED for on-stack tmp arrays to avoid crashes

This commit is contained in:
Hendrik Leppkes 2014-09-16 22:45:33 +02:00
parent 032ad87c13
commit fa18201c75
Signed by: hendrik
GPG Key ID: 846079A4B0A7C1B5
1 changed files with 5 additions and 5 deletions

View File

@ -578,7 +578,7 @@ void ff_hevc_transform_4x4_ ## D ## _sse2 (int16_t *_coeffs, int col_limit) { \
}
#define TRANSFORM_8x8(D) \
void ff_hevc_transform_8x8_ ## D ## _sse2 (int16_t *coeffs, int col_limit) { \
int16_t tmp[8*8]; \
DECLARE_ALIGNED(16, int16_t, tmp[8*8]); \
int16_t *src = coeffs; \
int16_t *p_dst1 = tmp; \
int16_t *p_dst; \
@ -641,8 +641,8 @@ TRANSFORM_8x8(12)
#define TR_32(dst, dst_stride, in, sstep) \
{ \
int i; \
int e32[16*16]; \
int o32[16*16]; \
DECLARE_ALIGNED(16, int, e32[16*16]); \
DECLARE_ALIGNED(16, int, o32[16*16]); \
LOAD16x16_O(e, in, sstep); \
for (i = 0; i < 16; i++) { \
src0 = _mm_setzero_si128(); \
@ -675,8 +675,8 @@ void ff_hevc_transform_ ## H ## x ## H ## _ ## D ## _sse2 ( \
int i, j, k, add; \
int shift = 7; \
int16_t *src = coeffs; \
int16_t tmp[H*H]; \
int16_t tmp_2[H*H]; \
DECLARE_ALIGNED(16, int16_t, tmp[H*H]); \
DECLARE_ALIGNED(16, int16_t, tmp_2[H*H]); \
int16_t *p_dst, *p_tra = tmp_2; \
__m128i src0, src1, src2, src3; \
__m128i tmp0, tmp1, tmp2, tmp3, tmp4; \