diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2012-10-09 13:06:04 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-10-09 13:06:04 +0200 |
commit | ef9fe5bedd1993700818a0ba1c195cd6f6668afe (patch) | |
tree | 3c70bf61e4bae16375575e3e6e8dac55fc1ba148 /libavcodec/ppc | |
parent | 238e904df3988ea0253ba08c8b2883e4740565b6 (diff) | |
parent | a75b9a1804769169456306f570b6716d977ebdc5 (diff) | |
download | ffmpeg-ef9fe5bedd1993700818a0ba1c195cd6f6668afe.tar.gz |
Merge remote-tracking branch 'qatar/master'
* qatar/master:
mingw/cygwin: Stop adding -fno-common to gcc CFLAGS
Restructure av_log_missing_feature message
rtp: Support packetization/depacketization of opus
file: Set the return value type for lseek to int64_t.
ppc: fix Altivec build with old compilers
build: add LTO support for PGI compiler
build: add -Mdse to PGI optimisation flags
rtpenc_vp8: Update the packetizer to the latest spec version
rtpdec_vp8: Make the depacketizer implement the latest spec draft
doc: allow building with old texi2html versions
avutil: skip old_pix_fmts.h since it is just a list
Conflicts:
libavcodec/aacdec.c
libavcodec/h264.c
libavcodec/ppc/fmtconvert_altivec.c
libavcodec/utils.c
libavformat/file.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/ppc')
-rw-r--r-- | libavcodec/ppc/fmtconvert_altivec.c | 30 |
1 files changed, 14 insertions, 16 deletions
diff --git a/libavcodec/ppc/fmtconvert_altivec.c b/libavcodec/ppc/fmtconvert_altivec.c index bad3b45b1b..d40ce07583 100644 --- a/libavcodec/ppc/fmtconvert_altivec.c +++ b/libavcodec/ppc/fmtconvert_altivec.c @@ -83,6 +83,12 @@ static void float_to_int16_altivec(int16_t *dst, const float *src, long len) } } +#define VSTE_INC(dst, v, elem, inc) do { \ + vector signed short s = vec_splat(v, elem); \ + vec_ste(s, 0, dst); \ + dst += inc; \ + } while (0) + static void float_to_int16_stride_altivec(int16_t *dst, const float *src, long len, int stride) { @@ -91,22 +97,14 @@ static void float_to_int16_stride_altivec(int16_t *dst, const float *src, for (i = 0; i < len - 7; i += 8) { d = float_to_int16_one_altivec(src + i); - -#define ASSIGN_S_VEC_SPLAT_D(j) \ - s = vec_splat(d, j); \ - vec_ste(s, 0, dst); \ - dst += stride - - ASSIGN_S_VEC_SPLAT_D(0); - ASSIGN_S_VEC_SPLAT_D(1); - ASSIGN_S_VEC_SPLAT_D(2); - ASSIGN_S_VEC_SPLAT_D(3); - ASSIGN_S_VEC_SPLAT_D(4); - ASSIGN_S_VEC_SPLAT_D(5); - ASSIGN_S_VEC_SPLAT_D(6); - ASSIGN_S_VEC_SPLAT_D(7); - -#undef ASSIGN_S_VEC_SPLAT_D + VSTE_INC(dst, d, 0, stride); + VSTE_INC(dst, d, 1, stride); + VSTE_INC(dst, d, 2, stride); + VSTE_INC(dst, d, 3, stride); + VSTE_INC(dst, d, 4, stride); + VSTE_INC(dst, d, 5, stride); + VSTE_INC(dst, d, 6, stride); + VSTE_INC(dst, d, 7, stride); } } |