[FFmpeg-devel] [PATCH 0/3] MIPS MSA & MMI Runtime detection support

Jiaxun Yang jiaxun.yang at flygoat.com
Tue May 26 12:48:19 EEST 2020


This series adds MIPS MSA & MMI runtime detection support.

It have been tested on Loongson-3A4000 (with both MSA & MMI),
Loongson-3B1500 (MMI only), MT7620A (no SIMD ASE).

There is a MMI checkasm test failure but looks irrelevant with my changes,
I have informed MIPS maintainer Shiyou Yin privately and he said he'll take
a look.

flygoat at maki:~/FFbuild/tests/checkasm$ ./checkasm
checkasm: using random seed 3369776568
MMI:
- blockdsp.blockdsp [OK]
- h264dsp.idct [OK]
- h264dsp.loop_filter [OK]
- h264dsp.loop_filter_intra [OK]
- h264pred.pred8x8 [OK]
- h264pred.pred16x16 [OK]
pred8x8l_top_dc_8_mmi (h264pred.c:222)
- h264pred.pred8x8l [FAILED]
- h264qpel.put [OK]
- h264qpel.avg [OK]
- pixblockdsp.get_pixels [OK]
- pixblockdsp.diff_pixels [OK]
- vp8dsp.idct [OK]
- vp8dsp.loopfilter [OK]
- vp9dsp.mc [OK]


Jiaxun Yang (3):
  ffbuild: Refine MIPS handling
  libavutil: Detect MMI and MSA flags for MIPS
  libavcodec: Enable runtime detection for MIPS MMI & MSA

 configure                                   | 179 ++++++++++++--------
 ffbuild/common.mak                          |  10 +-
 libavcodec/mips/Makefile                    |   3 +-
 libavcodec/mips/blockdsp_init_mips.c        |  22 ++-
 libavcodec/mips/cabac.h                     |   2 +-
 libavcodec/mips/h263dsp_init_mips.c         |  12 +-
 libavcodec/mips/h264chroma_init_mips.c      |  22 ++-
 libavcodec/mips/h264dsp_init_mips.c         |  25 ++-
 libavcodec/mips/h264pred_init_mips.c        |  25 ++-
 libavcodec/mips/h264qpel_init_mips.c        |  22 ++-
 libavcodec/mips/hevcdsp_init_mips.c         |  24 ++-
 libavcodec/mips/hevcpred_init_mips.c        |  12 +-
 libavcodec/mips/hpeldsp_init_mips.c         |  22 ++-
 libavcodec/mips/idctdsp_init_mips.c         |  24 ++-
 libavcodec/mips/me_cmp_init_mips.c          |  12 +-
 libavcodec/mips/mpegvideo_init_mips.c       |  22 ++-
 libavcodec/mips/mpegvideoencdsp_init_mips.c |  13 +-
 libavcodec/mips/pixblockdsp_init_mips.c     |  25 ++-
 libavcodec/mips/qpeldsp_init_mips.c         |  12 +-
 libavcodec/mips/vc1dsp_init_mips.c          |  22 ++-
 libavcodec/mips/videodsp_init.c             |  12 +-
 libavcodec/mips/vp3dsp_init_mips.c          |  22 ++-
 libavcodec/mips/vp8dsp_init_mips.c          |  22 ++-
 libavcodec/mips/vp9dsp_init_mips.c          |  22 ++-
 libavcodec/mips/wmv2dsp_init_mips.c         |  12 +-
 libavcodec/mips/xvididct_init_mips.c        |  13 +-
 libavutil/cpu.c                             |  10 ++
 libavutil/cpu.h                             |   3 +
 libavutil/cpu_internal.h                    |   2 +
 libavutil/mips/Makefile                     |   2 +-
 libavutil/mips/cpu.c                        |  78 +++++++++
 libavutil/mips/cpu.h                        |  28 +++
 libavutil/tests/cpu.c                       |   3 +
 tests/checkasm/checkasm.c                   |   3 +
 34 files changed, 557 insertions(+), 185 deletions(-)
 create mode 100644 libavutil/mips/cpu.c
 create mode 100644 libavutil/mips/cpu.h

-- 
2.26.2




More information about the ffmpeg-devel mailing list