PR #22309 opened by Martin Storsjö (mstorsjo) URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/22309 Patch URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/22309.patch
This uses the new mechanisms introduced in cf7e2b67735d500768b06c6f411826bfef923b0f, as used by the crc test in 0629ebb5ffda39add5f1fbce524bbc989ba5d6c6. From 489ff8126a03fdaddf139f8bc582c28eada431ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Storsj=C3=B6?= <[email protected]> Date: Wed, 25 Feb 2026 15:45:23 +0200 Subject: [PATCH] tests/checkasm/sw_ops: Switch to opaques for deciding when to test This uses the new mechanisms introduced in cf7e2b67735d500768b06c6f411826bfef923b0f, as used by the crc test in 0629ebb5ffda39add5f1fbce524bbc989ba5d6c6. --- tests/checkasm/sw_ops.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/tests/checkasm/sw_ops.c b/tests/checkasm/sw_ops.c index bd70adc212..6615f63354 100644 --- a/tests/checkasm/sw_ops.c +++ b/tests/checkasm/sw_ops.c @@ -190,18 +190,14 @@ static void check_ops(const char *report, const unsigned ranges[NB_PLANES], uintptr_t id = (uintptr_t) backend_new; id ^= (id << 6) + (id >> 2) + 0x9e3779b97f4a7c15 + comp_new.cpu_flags; - checkasm_save_context(); - if (checkasm_check_func((void *) id, "%s", report)) { - func_new = comp_new.func; - func_ref = comp_ref.func; - + if (check_key((void*) id, "%s", report)) { exec.block_size_in = comp_ref.block_size * rw_pixel_bits(read_op) >> 3; exec.block_size_out = comp_ref.block_size * rw_pixel_bits(write_op) >> 3; for (int i = 0; i < NB_PLANES; i++) { exec.in[i] = (void *) src0[i]; exec.out[i] = (void *) dst0[i]; } - call_ref(&exec, comp_ref.priv, 0, 0, PIXELS / comp_ref.block_size, LINES); + checkasm_call(comp_ref.func, &exec, comp_ref.priv, 0, 0, PIXELS / comp_ref.block_size, LINES); exec.block_size_in = comp_new.block_size * rw_pixel_bits(read_op) >> 3; exec.block_size_out = comp_new.block_size * rw_pixel_bits(write_op) >> 3; @@ -209,7 +205,7 @@ static void check_ops(const char *report, const unsigned ranges[NB_PLANES], exec.in[i] = (void *) src1[i]; exec.out[i] = (void *) dst1[i]; } - call_new(&exec, comp_new.priv, 0, 0, PIXELS / comp_new.block_size, LINES); + checkasm_call_checked(comp_new.func, &exec, comp_new.priv, 0, 0, PIXELS / comp_new.block_size, LINES); for (int i = 0; i < NB_PLANES; i++) { const char *name = FMT("%s[%d]", report, i); @@ -242,7 +238,7 @@ static void check_ops(const char *report, const unsigned ranges[NB_PLANES], break; } - bench_new(&exec, comp_new.priv, 0, 0, PIXELS / comp_new.block_size, LINES); + bench(comp_new.func, &exec, comp_new.priv, 0, 0, PIXELS / comp_new.block_size, LINES); } if (comp_new.func != comp_ref.func && comp_new.free) -- 2.52.0 _______________________________________________ ffmpeg-devel mailing list -- [email protected] To unsubscribe send an email to [email protected]
