From: "Martin Storsjö" <martin@martin.st>
To: ffmpeg-devel@ffmpeg.org
Subject: [FFmpeg-devel] [PATCH 4/4] checkasm: vp8dsp: Use checkasm_check_padded in check_mc
Date: Wed, 26 Mar 2025 12:30:15 +0200
Message-ID: <20250326103015.44296-4-martin@martin.st> (raw)
In-Reply-To: <20250326103015.44296-1-martin@martin.st>
---
This is mostly a small example for using the versions of the
helpers that don't rely on a "bit_depth" local variable.
---
tests/checkasm/vp8dsp.c | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
diff --git a/tests/checkasm/vp8dsp.c b/tests/checkasm/vp8dsp.c
index e448fe89fc..a12c295a2a 100644
--- a/tests/checkasm/vp8dsp.c
+++ b/tests/checkasm/vp8dsp.c
@@ -259,8 +259,8 @@ static void check_luma_dc_wht(VP8DSPContext *d, bool is_vp7)
static void check_mc(VP8DSPContext *d)
{
LOCAL_ALIGNED_16(uint8_t, buf, [32 * 32]);
- LOCAL_ALIGNED_16(uint8_t, dst0, [16 * 16]);
- LOCAL_ALIGNED_16(uint8_t, dst1, [16 * 16]);
+ BUF_RECT(uint8_t, dst0, 16, 16);
+ BUF_RECT(uint8_t, dst1, 16, 16);
int type, k, dx, dy;
declare_func_emms(AV_CPU_FLAG_MMX, void, uint8_t *, ptrdiff_t,
const uint8_t *, ptrdiff_t, int, int, int);
@@ -305,10 +305,11 @@ static void check_mc(VP8DSPContext *d)
src[i ] = val;
src[i * SRC_BUF_STRIDE] = val;
}
- call_ref(dst0, size, src, SRC_BUF_STRIDE, height, mx, my);
- call_new(dst1, size, src, SRC_BUF_STRIDE, height, mx, my);
- if (memcmp(dst0, dst1, size * height))
- fail();
+ CLEAR_BUF_RECT(dst0);
+ CLEAR_BUF_RECT(dst1);
+ call_ref(dst0, dst0_stride, src, SRC_BUF_STRIDE, height, mx, my);
+ call_new(dst1, dst1_stride, src, SRC_BUF_STRIDE, height, mx, my);
+ checkasm_check_padded(uint8_t, dst0, dst0_stride, dst1, dst1_stride, size, height, "dst");
bench_new(dst1, size, src, SRC_BUF_STRIDE, height, mx, my);
}
}
--
2.39.5 (Apple Git-154)
_______________________________________________
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:[~2025-03-26 10:31 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-03-26 10:30 [FFmpeg-devel] [PATCH 1/4] checkasm: Make checkasm_fail_func return whether we should print verbosely Martin Storsjö
2025-03-26 10:30 ` [FFmpeg-devel] [PATCH 2/4] checkasm: Implement helpers for defining and checking padded rects Martin Storsjö
2025-03-29 0:15 ` Michael Niedermayer
2025-03-31 13:05 ` Martin Storsjö
2025-04-01 0:28 ` Michael Niedermayer
2025-04-01 9:38 ` Martin Storsjö
2025-04-01 15:38 ` Martin Storsjö
2025-03-26 10:30 ` [FFmpeg-devel] [PATCH 3/4] checkasm: hevc_pel: Use helpers for checking for writes out of bounds Martin Storsjö
2025-04-01 9:35 ` Martin Storsjö
2025-04-01 12:54 ` yinshiyou-hf
2025-04-10 10:36 ` Martin Storsjö
2025-03-26 10:30 ` Martin Storsjö [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=20250326103015.44296-4-martin@martin.st \
--to=martin@martin.st \
--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