aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/mips
diff options
context:
space:
mode:
authorShiyou Yin <yinshiyou-hf@loongson.cn>2018-12-17 18:03:30 +0800
committerMichael Niedermayer <michael@niedermayer.cc>2018-12-18 11:59:51 +0100
commit76952aa46163f92c8bb5180973e33ca36d583308 (patch)
tree7be7de731a5c9048cd32b290b6a9b5bdb77dbb94 /libavcodec/mips
parent978c935f2f659edf028b9219c7397efdcf4a1260 (diff)
downloadffmpeg-76952aa46163f92c8bb5180973e33ca36d583308.tar.gz
avcodec/mips: [loongson] enable MSA optimization for loongson platform.
Set initialization order of MSA after MMI to make it work on loongson platform(msa is supported by loongson2k、3a4000 etc.). Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavcodec/mips')
-rw-r--r--libavcodec/mips/blockdsp_init_mips.c6
-rw-r--r--libavcodec/mips/h264chroma_init_mips.c6
-rw-r--r--libavcodec/mips/h264dsp_init_mips.c6
-rw-r--r--libavcodec/mips/h264pred_init_mips.c6
-rw-r--r--libavcodec/mips/h264qpel_init_mips.c6
-rw-r--r--libavcodec/mips/hpeldsp_init_mips.c6
-rw-r--r--libavcodec/mips/idctdsp_init_mips.c6
-rw-r--r--libavcodec/mips/mpegvideo_init_mips.c6
-rw-r--r--libavcodec/mips/pixblockdsp_init_mips.c6
-rw-r--r--libavcodec/mips/vp8dsp_init_mips.c6
10 files changed, 30 insertions, 30 deletions
diff --git a/libavcodec/mips/blockdsp_init_mips.c b/libavcodec/mips/blockdsp_init_mips.c
index 30ae95fa10..55ac1c3e99 100644
--- a/libavcodec/mips/blockdsp_init_mips.c
+++ b/libavcodec/mips/blockdsp_init_mips.c
@@ -45,10 +45,10 @@ static av_cold void blockdsp_init_mmi(BlockDSPContext *c)
void ff_blockdsp_init_mips(BlockDSPContext *c)
{
-#if HAVE_MSA
- blockdsp_init_msa(c);
-#endif // #if HAVE_MSA
#if HAVE_MMI
blockdsp_init_mmi(c);
#endif /* HAVE_MMI */
+#if HAVE_MSA
+ blockdsp_init_msa(c);
+#endif // #if HAVE_MSA
}
diff --git a/libavcodec/mips/h264chroma_init_mips.c b/libavcodec/mips/h264chroma_init_mips.c
index 122148dc78..ae817e47ae 100644
--- a/libavcodec/mips/h264chroma_init_mips.c
+++ b/libavcodec/mips/h264chroma_init_mips.c
@@ -54,10 +54,10 @@ static av_cold void h264chroma_init_mmi(H264ChromaContext *c, int bit_depth)
av_cold void ff_h264chroma_init_mips(H264ChromaContext *c, int bit_depth)
{
-#if HAVE_MSA
- h264chroma_init_msa(c, bit_depth);
-#endif // #if HAVE_MSA
#if HAVE_MMI
h264chroma_init_mmi(c, bit_depth);
#endif /* HAVE_MMI */
+#if HAVE_MSA
+ h264chroma_init_msa(c, bit_depth);
+#endif // #if HAVE_MSA
}
diff --git a/libavcodec/mips/h264dsp_init_mips.c b/libavcodec/mips/h264dsp_init_mips.c
index 1fe7f8468c..dc08a25800 100644
--- a/libavcodec/mips/h264dsp_init_mips.c
+++ b/libavcodec/mips/h264dsp_init_mips.c
@@ -138,10 +138,10 @@ static av_cold void h264dsp_init_mmi(H264DSPContext * c, const int bit_depth,
av_cold void ff_h264dsp_init_mips(H264DSPContext *c, const int bit_depth,
const int chroma_format_idc)
{
-#if HAVE_MSA
- h264dsp_init_msa(c, bit_depth, chroma_format_idc);
-#endif // #if HAVE_MSA
#if HAVE_MMI
h264dsp_init_mmi(c, bit_depth, chroma_format_idc);
#endif /* HAVE_MMI */
+#if HAVE_MSA
+ h264dsp_init_msa(c, bit_depth, chroma_format_idc);
+#endif // #if HAVE_MSA
}
diff --git a/libavcodec/mips/h264pred_init_mips.c b/libavcodec/mips/h264pred_init_mips.c
index c33d8f7cdb..63637b8732 100644
--- a/libavcodec/mips/h264pred_init_mips.c
+++ b/libavcodec/mips/h264pred_init_mips.c
@@ -146,10 +146,10 @@ av_cold void ff_h264_pred_init_mips(H264PredContext *h, int codec_id,
int bit_depth,
const int chroma_format_idc)
{
-#if HAVE_MSA
- h264_pred_init_msa(h, codec_id, bit_depth, chroma_format_idc);
-#endif // #if HAVE_MSA
#if HAVE_MMI
h264_pred_init_mmi(h, codec_id, bit_depth, chroma_format_idc);
#endif /* HAVE_MMI */
+#if HAVE_MSA
+ h264_pred_init_msa(h, codec_id, bit_depth, chroma_format_idc);
+#endif // #if HAVE_MSA
}
diff --git a/libavcodec/mips/h264qpel_init_mips.c b/libavcodec/mips/h264qpel_init_mips.c
index 92219f8877..33bae3093a 100644
--- a/libavcodec/mips/h264qpel_init_mips.c
+++ b/libavcodec/mips/h264qpel_init_mips.c
@@ -240,10 +240,10 @@ static av_cold void h264qpel_init_mmi(H264QpelContext *c, int bit_depth)
av_cold void ff_h264qpel_init_mips(H264QpelContext *c, int bit_depth)
{
-#if HAVE_MSA
- h264qpel_init_msa(c, bit_depth);
-#endif // #if HAVE_MSA
#if HAVE_MMI
h264qpel_init_mmi(c, bit_depth);
#endif /* HAVE_MMI */
+#if HAVE_MSA
+ h264qpel_init_msa(c, bit_depth);
+#endif // #if HAVE_MSA
}
diff --git a/libavcodec/mips/hpeldsp_init_mips.c b/libavcodec/mips/hpeldsp_init_mips.c
index 363a04514f..d6f7a9793d 100644
--- a/libavcodec/mips/hpeldsp_init_mips.c
+++ b/libavcodec/mips/hpeldsp_init_mips.c
@@ -113,10 +113,10 @@ static void ff_hpeldsp_init_mmi(HpelDSPContext *c, int flags)
void ff_hpeldsp_init_mips(HpelDSPContext *c, int flags)
{
-#if HAVE_MSA
- ff_hpeldsp_init_msa(c, flags);
-#endif // #if HAVE_MSA
#if HAVE_MMI
ff_hpeldsp_init_mmi(c, flags);
#endif // #if HAVE_MMI
+#if HAVE_MSA
+ ff_hpeldsp_init_msa(c, flags);
+#endif // #if HAVE_MSA
}
diff --git a/libavcodec/mips/idctdsp_init_mips.c b/libavcodec/mips/idctdsp_init_mips.c
index bb33b55419..85b76ca478 100644
--- a/libavcodec/mips/idctdsp_init_mips.c
+++ b/libavcodec/mips/idctdsp_init_mips.c
@@ -65,10 +65,10 @@ static av_cold void idctdsp_init_mmi(IDCTDSPContext *c, AVCodecContext *avctx,
av_cold void ff_idctdsp_init_mips(IDCTDSPContext *c, AVCodecContext *avctx,
unsigned high_bit_depth)
{
-#if HAVE_MSA
- idctdsp_init_msa(c, avctx, high_bit_depth);
-#endif // #if HAVE_MSA
#if HAVE_MMI
idctdsp_init_mmi(c, avctx, high_bit_depth);
#endif /* HAVE_MMI */
+#if HAVE_MSA
+ idctdsp_init_msa(c, avctx, high_bit_depth);
+#endif // #if HAVE_MSA
}
diff --git a/libavcodec/mips/mpegvideo_init_mips.c b/libavcodec/mips/mpegvideo_init_mips.c
index 1918da5f46..be77308140 100644
--- a/libavcodec/mips/mpegvideo_init_mips.c
+++ b/libavcodec/mips/mpegvideo_init_mips.c
@@ -49,10 +49,10 @@ static av_cold void dct_unquantize_init_mmi(MpegEncContext *s)
av_cold void ff_mpv_common_init_mips(MpegEncContext *s)
{
-#if HAVE_MSA
- dct_unquantize_init_msa(s);
-#endif // #if HAVE_MSA
#if HAVE_MMI
dct_unquantize_init_mmi(s);
#endif /* HAVE_MMI */
+#if HAVE_MSA
+ dct_unquantize_init_msa(s);
+#endif // #if HAVE_MSA
}
diff --git a/libavcodec/mips/pixblockdsp_init_mips.c b/libavcodec/mips/pixblockdsp_init_mips.c
index 1b3741ea76..fd0238d79b 100644
--- a/libavcodec/mips/pixblockdsp_init_mips.c
+++ b/libavcodec/mips/pixblockdsp_init_mips.c
@@ -60,10 +60,10 @@ static av_cold void pixblockdsp_init_mmi(PixblockDSPContext *c,
void ff_pixblockdsp_init_mips(PixblockDSPContext *c, AVCodecContext *avctx,
unsigned high_bit_depth)
{
-#if HAVE_MSA
- pixblockdsp_init_msa(c, avctx, high_bit_depth);
-#endif // #if HAVE_MSA
#if HAVE_MMI
pixblockdsp_init_mmi(c, avctx, high_bit_depth);
#endif /* HAVE_MMI */
+#if HAVE_MSA
+ pixblockdsp_init_msa(c, avctx, high_bit_depth);
+#endif // #if HAVE_MSA
}
diff --git a/libavcodec/mips/vp8dsp_init_mips.c b/libavcodec/mips/vp8dsp_init_mips.c
index 3fc5f8e0af..7fd8fb0d32 100644
--- a/libavcodec/mips/vp8dsp_init_mips.c
+++ b/libavcodec/mips/vp8dsp_init_mips.c
@@ -193,10 +193,10 @@ static av_cold void vp8dsp_init_mmi(VP8DSPContext *dsp)
av_cold void ff_vp8dsp_init_mips(VP8DSPContext *dsp)
{
-#if HAVE_MSA
- vp8dsp_init_msa(dsp);
-#endif // #if HAVE_MSA
#if HAVE_MMI
vp8dsp_init_mmi(dsp);
#endif /* HAVE_MMI */
+#if HAVE_MSA
+ vp8dsp_init_msa(dsp);
+#endif // #if HAVE_MSA
}