[FFmpeg-cvslog] checkasm: motion: Make the benchmarks more stable

Martin Storsjö git at videolan.org
Sat Jul 16 17:33:50 EEST 2022


ffmpeg | branch: master | Martin Storsjö <martin at martin.st> | Tue Jul 12 23:44:42 2022 +0300| [237730f0e0422fd46ffaf7e724a68eb1e6459645] | committer: Martin Storsjö

checkasm: motion: Make the benchmarks more stable

Don't use the last random offset, but a static one.

Signed-off-by: Martin Storsjö <martin at martin.st>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=237730f0e0422fd46ffaf7e724a68eb1e6459645
---

 tests/checkasm/motion.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/tests/checkasm/motion.c b/tests/checkasm/motion.c
index 0112822174..631a9ed29f 100644
--- a/tests/checkasm/motion.c
+++ b/tests/checkasm/motion.c
@@ -79,7 +79,8 @@ static void test_motion(const char *name, me_cmp_func test_func)
                 break;
             }
         }
-        // benchmark with the final value of ptr
+        // Test with a fixed offset, for benchmark stability
+        ptr = img2 + 3 * WIDTH + 3;
         bench_new(NULL, img1, ptr, WIDTH, 8);
     }
 }



More information about the ffmpeg-cvslog mailing list