summaryrefslogtreecommitdiff
path: root/vp8
diff options
context:
space:
mode:
authorjinbo <jinbo-hf@loongson.cn>2020-08-15 17:20:36 +0800
committerjinbo <jinbo-hf@loongson.cn>2020-08-19 07:57:21 +0800
commitea6562f2fcd8ea6baa946eaad69cbb5aec5dd278 (patch)
tree64e1f0ad6c30e8f303e8beb7af9d5d13d092707d /vp8
parent529c29bb0f6511a9b3e25177cece0d843827458b (diff)
downloadlibvpx-ea6562f2fcd8ea6baa946eaad69cbb5aec5dd278.tar
libvpx-ea6562f2fcd8ea6baa946eaad69cbb5aec5dd278.tar.gz
libvpx-ea6562f2fcd8ea6baa946eaad69cbb5aec5dd278.tar.bz2
libvpx-ea6562f2fcd8ea6baa946eaad69cbb5aec5dd278.zip
Refine MMI & MSA detection for mips
1.Add compile check to probe the native ability of toolchain to decide whether a feature can be enabled. 2.Add runtime check to probe cpu supported features. MSA will be prefered if MSA and MMI are both supported. 3.You can configure and build as following commands: ./configure --cpu=loongson3a && make -j4 Change-Id: I057553216dbc79cfaba9c691d5f4cdab144e1123
Diffstat (limited to 'vp8')
-rw-r--r--vp8/common/generic/systemdependent.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/vp8/common/generic/systemdependent.c b/vp8/common/generic/systemdependent.c
index 75ce7ef35..cd1b02c9c 100644
--- a/vp8/common/generic/systemdependent.c
+++ b/vp8/common/generic/systemdependent.c
@@ -16,6 +16,8 @@
#include "vpx_ports/x86.h"
#elif VPX_ARCH_PPC
#include "vpx_ports/ppc.h"
+#elif VPX_ARCH_MIPS
+#include "vpx_ports/mips.h"
#endif
#include "vp8/common/onyxc_int.h"
#include "vp8/common/systemdependent.h"
@@ -96,6 +98,8 @@ void vp8_machine_specific_config(VP8_COMMON *ctx) {
ctx->cpu_caps = x86_simd_caps();
#elif VPX_ARCH_PPC
ctx->cpu_caps = ppc_simd_caps();
+#elif VPX_ARCH_MIPS
+ ctx->cpu_caps = mips_cpu_caps();
#else
// generic-gnu targets.
ctx->cpu_caps = 0;