From: flow gg <hlefthleft@gmail.com> To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org> Subject: Re: [FFmpeg-devel] [PATCH 2/3] lavc/vp8dsp: R-V V vp8_idct_dc_add4y Date: Tue, 13 Feb 2024 10:34:19 +0800 Message-ID: <CAEa-L+s1LFsEqgvPnY2MAjTVPcw89PnWu1vVpXWY6xx+JAVGsQ@mail.gmail.com> (raw) In-Reply-To: <7058222.aiPjh0dJkU@basile.remlab.net> [-- Attachment #1: Type: text/plain, Size: 636 bytes --] Okay, updated it in the reply Rémi Denis-Courmont <remi@remlab.net> 于2024年2月13日周二 03:54写道: > Hi, > > To avoid repeating the code, you can either use .repr or .irp. You can > even > use assembler conditionals to elide the redundant code on the last > iteration. > > -- > レミ・デニ-クールモン > http://www.remlab.net/ > _______________________________________________ > ffmpeg-devel mailing list > ffmpeg-devel@ffmpeg.org > https://ffmpeg.org/mailman/listinfo/ffmpeg-devel > > To unsubscribe, visit link above, or email > ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe". > [-- Attachment #2: 0002-lavc-vp8dsp-R-V-V-vp8_idct_dc_add4y.patch --] [-- Type: text/x-patch, Size: 1855 bytes --] From d44e7ec0950ddb431aa75992cfa12d7687d39514 Mon Sep 17 00:00:00 2001 From: sunyuechi <sunyuechi@iscas.ac.cn> Date: Fri, 2 Feb 2024 12:50:07 +0800 Subject: [PATCH 2/3] lavc/vp8dsp: R-V V vp8_idct_dc_add4y c908: vp8_idct_dc_add4y_c: 368.5 vp8_idct_dc_add4y_rvv_i32: 134.5 --- libavcodec/riscv/vp8dsp_init.c | 2 ++ libavcodec/riscv/vp8dsp_rvv.S | 16 ++++++++++++++++ 2 files changed, 18 insertions(+) diff --git a/libavcodec/riscv/vp8dsp_init.c b/libavcodec/riscv/vp8dsp_init.c index ab020070eb..6615d3d440 100644 --- a/libavcodec/riscv/vp8dsp_init.c +++ b/libavcodec/riscv/vp8dsp_init.c @@ -26,6 +26,7 @@ #include "libavcodec/vp8dsp.h" void ff_vp8_idct_dc_add_rvv(uint8_t *dst, int16_t block[16], ptrdiff_t stride); +void ff_vp8_idct_dc_add4y_rvv(uint8_t *dst, int16_t block[4][16], ptrdiff_t stride); av_cold void ff_vp8dsp_init_riscv(VP8DSPContext *c) { @@ -34,6 +35,7 @@ av_cold void ff_vp8dsp_init_riscv(VP8DSPContext *c) if (flags & AV_CPU_FLAG_RVV_I32 && ff_get_rv_vlenb() >= 16) { c->vp8_idct_dc_add = ff_vp8_idct_dc_add_rvv; + c->vp8_idct_dc_add4y = ff_vp8_idct_dc_add4y_rvv; } #endif } diff --git a/libavcodec/riscv/vp8dsp_rvv.S b/libavcodec/riscv/vp8dsp_rvv.S index 8609b79937..a5a22188c1 100644 --- a/libavcodec/riscv/vp8dsp_rvv.S +++ b/libavcodec/riscv/vp8dsp_rvv.S @@ -36,9 +36,25 @@ vsse32.v v0, (a0), a2 .endm +.macro vp8_idct_dc_addy + vp8_idct_dc_add + addi a0, a0, 4 + addi a1, a1, 32 +.endm + func ff_vp8_idct_dc_add_rvv, zve32x vsetivli zero, 4, e8, mf4, ta, ma vp8_idct_dc_add ret endfunc + +func ff_vp8_idct_dc_add4y_rvv, zve32x + vsetivli zero, 4, e8, mf4, ta, ma + .rept 3 + vp8_idct_dc_addy + .endr + vp8_idct_dc_add + + ret +endfunc -- 2.43.1 [-- Attachment #3: Type: text/plain, Size: 251 bytes --] _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
prev parent reply other threads:[~2024-02-13 2:34 UTC|newest] Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top 2024-02-02 5:03 flow gg 2024-02-12 19:54 ` Rémi Denis-Courmont 2024-02-13 2:34 ` flow gg [this message]
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=CAEa-L+s1LFsEqgvPnY2MAjTVPcw89PnWu1vVpXWY6xx+JAVGsQ@mail.gmail.com \ --to=hlefthleft@gmail.com \ --cc=ffmpeg-devel@ffmpeg.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel This inbox may be cloned and mirrored by anyone: git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \ ffmpegdev@gitmailbox.com public-inbox-index ffmpegdev Example config snippet for mirrors. AGPL code for this site: git clone https://public-inbox.org/public-inbox.git