summaryrefslogtreecommitdiff
path: root/libavutil/cpu.c
diff options
context:
space:
mode:
authorRĂ©mi Denis-Courmont <remi@remlab.net>2022-10-02 14:54:58 +0300
committerLynne <dev@lynne.ee>2022-10-05 08:26:19 +0200
commit37d5ddc317c35bded22fee8d79020653781d8230 (patch)
tree0e4162777730cfeea45976bda4fa350af573b5a5 /libavutil/cpu.c
parentb25c6a5704ac114e825577209a610f5e95abe6c0 (diff)
downloadffmpeg-37d5ddc317c35bded22fee8d79020653781d8230.tar.gz
lavu/riscv: CPU flag for the Zbb extension
Unfortunately, it is common, and will remain so, that the Bit manipulations are not enabled at compilation time. This is an official policy for Debian ports in general (though they do not support RISC-V officially as of yet) to stick to the minimal target baseline, which does not include the B extension or even its Zbb subset. For inline helpers (CPOP, REV8), compiler builtins (CTZ, CLZ) or even plain C code (MIN, MAX, MINU, MAXU), run-time detection seems impractical. But at least it can work for the byte-swap DSP functions.
Diffstat (limited to 'libavutil/cpu.c')
-rw-r--r--libavutil/cpu.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavutil/cpu.c b/libavutil/cpu.c
index 5818fd9c1c..2c5f7f4958 100644
--- a/libavutil/cpu.c
+++ b/libavutil/cpu.c
@@ -188,6 +188,7 @@ int av_parse_cpu_caps(unsigned *flags, const char *s)
{ "rvv-f32", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = AV_CPU_FLAG_RVV_F32 }, .unit = "flags" },
{ "rvv-i64", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = AV_CPU_FLAG_RVV_I64 }, .unit = "flags" },
{ "rvv", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = AV_CPU_FLAG_RVV_F64 }, .unit = "flags" },
+ { "rvb-basic",NULL, 0, AV_OPT_TYPE_CONST, { .i64 = AV_CPU_FLAG_RVB_BASIC }, .unit = "flags" },
#endif
{ NULL },
};