This fixes some global out of array reads and wrong cliping. No speed difference meassurable under clang on i5 also all important code paths on all important platforms should use SIMD.
Unified · Split
| @@ -70,7 +70,7 @@ · 69 unmodified lines | ||
| 70 | 70 | # define pixel4 uint32_t |
| 71 | 71 | # define dctcoef int16_t |
| 72 | 72 | |
| 73 | −# define INIT_CLIP uint8_t *cm = ff_cropTbl + MAX_NEG_CROP; | |
| 73 | +# define INIT_CLIP ; | |
| 74 | 74 | # define no_rnd_avg_pixel4 no_rnd_avg32 |
| 75 | 75 | # define rnd_avg_pixel4 rnd_avg32 |
| 76 | 76 | # define AV_RN2P AV_RN16 |
| @@ -82,7 +82,7 @@ · 5 unmodified lines | ||
| 82 | 82 | # define PIXEL_SPLAT_X4(x) ((x)*0x01010101U) |
| 83 | 83 | |
| 84 | 84 | # define av_clip_pixel(a) av_clip_uint8(a) |
| 85 | −# define CLIP(a) cm[a] | |
| 85 | +# define CLIP(a) av_clip_uint8(a) | |
| 86 | 86 | #endif |
| 87 | 87 | |
| 88 | 88 | #define FUNC3(a, b, c) a ## _ ## b ## c |