From 3334cbec0aa1aa3814b8eb91f964c7da5e8053f5 Mon Sep 17 00:00:00 2001 From: Diego Biurrun Date: Tue, 7 May 2013 01:34:53 +0200 Subject: [PATCH 1/2] x86: dsputil: Remove unused MOVQ_BONE macro --- libavcodec/x86/constants.c | 1 - libavcodec/x86/dsputil_mmx.h | 8 -------- 2 files changed, 9 deletions(-) diff --git a/libavcodec/x86/constants.c b/libavcodec/x86/constants.c index f4d04729ae..cd36de6dad 100644 --- a/libavcodec/x86/constants.c +++ b/libavcodec/x86/constants.c @@ -21,7 +21,6 @@ #include "libavutil/mem.h" #include "libavutil/x86/asm.h" // for xmm_reg -DECLARE_ALIGNED(8, const uint64_t, ff_bone) = 0x0101010101010101ULL; DECLARE_ALIGNED(8, const uint64_t, ff_wtwo) = 0x0002000200020002ULL; DECLARE_ALIGNED(16, const xmm_reg, ff_pw_1) = { 0x0001000100010001ULL, 0x0001000100010001ULL }; diff --git a/libavcodec/x86/dsputil_mmx.h b/libavcodec/x86/dsputil_mmx.h index 2977bfe419..26a1926a12 100644 --- a/libavcodec/x86/dsputil_mmx.h +++ b/libavcodec/x86/dsputil_mmx.h @@ -28,7 +28,6 @@ #include "libavcodec/dsputil.h" #include "libavutil/x86/asm.h" -extern const uint64_t ff_bone; extern const uint64_t ff_wtwo; extern const xmm_reg ff_pw_3; @@ -81,17 +80,10 @@ extern const double ff_pd_2[2]; "paddb %%"#regd", %%"#regd" \n\t" ::) #ifndef PIC -#define MOVQ_BONE(regd) __asm__ volatile ("movq %0, %%"#regd" \n\t" :: "m"(ff_bone)) #define MOVQ_WTWO(regd) __asm__ volatile ("movq %0, %%"#regd" \n\t" :: "m"(ff_wtwo)) #else // for shared library it's better to use this way for accessing constants // pcmpeqd -> -1 -#define MOVQ_BONE(regd) \ - __asm__ volatile ( \ - "pcmpeqd %%"#regd", %%"#regd" \n\t" \ - "psrlw $15, %%"#regd" \n\t" \ - "packuswb %%"#regd", %%"#regd" \n\t" ::) - #define MOVQ_WTWO(regd) \ __asm__ volatile ( \ "pcmpeqd %%"#regd", %%"#regd" \n\t" \ From 1b343cedd7cd68e7865aa5280d1568c7e5d79917 Mon Sep 17 00:00:00 2001 From: Diego Biurrun Date: Tue, 7 May 2013 01:37:03 +0200 Subject: [PATCH 2/2] x86: dsputil: Remove unused ff_pb_3F constant --- libavcodec/x86/dsputil_mmx.c | 1 - libavcodec/x86/dsputil_mmx.h | 1 - 2 files changed, 2 deletions(-) diff --git a/libavcodec/x86/dsputil_mmx.c b/libavcodec/x86/dsputil_mmx.c index 807c8364af..ea3aed8820 100644 --- a/libavcodec/x86/dsputil_mmx.c +++ b/libavcodec/x86/dsputil_mmx.c @@ -47,7 +47,6 @@ DECLARE_ALIGNED(8, const uint64_t, ff_pw_255) = 0x00ff00ff00ff00ffULL; DECLARE_ALIGNED(16, const xmm_reg, ff_pw_512) = { 0x0200020002000200ULL, 0x0200020002000200ULL }; DECLARE_ALIGNED(16, const xmm_reg, ff_pw_1019) = { 0x03FB03FB03FB03FBULL, 0x03FB03FB03FB03FBULL }; -DECLARE_ALIGNED(8, const uint64_t, ff_pb_3F) = 0x3F3F3F3F3F3F3F3FULL; DECLARE_ALIGNED(8, const uint64_t, ff_pb_FC) = 0xFCFCFCFCFCFCFCFCULL; DECLARE_ALIGNED(16, const double, ff_pd_1)[2] = { 1.0, 1.0 }; diff --git a/libavcodec/x86/dsputil_mmx.h b/libavcodec/x86/dsputil_mmx.h index 26a1926a12..7f331b60f6 100644 --- a/libavcodec/x86/dsputil_mmx.h +++ b/libavcodec/x86/dsputil_mmx.h @@ -48,7 +48,6 @@ extern const uint64_t ff_pw_255; extern const xmm_reg ff_pb_1; extern const xmm_reg ff_pb_3; -extern const uint64_t ff_pb_3F; extern const xmm_reg ff_pb_F8; extern const uint64_t ff_pb_FC;