From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id 1D6FA4AD98 for ; Tue, 21 May 2024 10:04:40 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 9085368D2B5; Tue, 21 May 2024 13:04:38 +0300 (EEST) Received: from mail-lf1-f47.google.com (mail-lf1-f47.google.com [209.85.167.47]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 736D068C620 for ; Tue, 21 May 2024 13:04:31 +0300 (EEST) Received: by mail-lf1-f47.google.com with SMTP id 2adb3069b0e04-523b20e2615so6050653e87.1 for ; Tue, 21 May 2024 03:04:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=martin-st.20230601.gappssmtp.com; s=20230601; t=1716285870; x=1716890670; darn=ffmpeg.org; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:from:to:cc:subject:date:message-id:reply-to; bh=NOtK5vhOYY/ZiQaG8dz19iApIQR/u8d6CqjYA9M4f+I=; b=adrfIDrglCXVg61aUN6YL22Z5IMZsZRHSsjNUvl80ttVIRo71vFwCEICmp7+dfjD41 nnbRjQwVODEJ1odwSxY1NDqC3vdBygoswzbrsMjkhHYldRR7zIhwkipCpnl4Op3S5MbK XOe7EbCbZTdPRXCXm3TdN/PBBeBayzHXoGBgEcDOEviZxOhzqdNN4/vqVSxBnlDjuGpc 8i/aTpENSpdrQ8Cs9sBfm3zaJkpU5dfXa91QdHG5py6VZ99Cz43IbvUFy+jIUsm81PBH KknsanV825iMaMsZX10a01+XpJw3UHKfPhRbRIAoDue53GxiasTAkEVgfiyj/hGnGN0y 1vHg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1716285870; x=1716890670; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=NOtK5vhOYY/ZiQaG8dz19iApIQR/u8d6CqjYA9M4f+I=; b=cRCqQpRQSMt9l0wFLokno19Y8rjk1A5Ell9gsOWlCNxPiqDv1yva8JvNrYR/7a8nYd E/HRHF5Bj0KniIqNYif/sQNajPxy5uRHbdk+kKjHQRmy5JiDwcNPh/u5XHzpluh875dU IPimutIUWrsf5+78xBDfysFRT756tRrOP0P9COPUHilXFVf+Q143Was7nQLr7z4m5snV c/bpyMQE29nZDVTPDHPrE0VzNWaLi+WBQwtmF730c5TNQH76sRtC2/L2Ysu9sraQWuiz tl+c5UvUvWFYIXUm2DOXTqoAj9gRMS3pTXbFIq+GutVXUJExSqPQKvd59lHmqoaj02fa luxw== X-Gm-Message-State: AOJu0YytEfte1cy+IUAGX3D+hIKYhHP/WgkoGQWDx7QisIa2Jp5DF7rV Z0+VXRsl1zC+w4893d95p5SxaGy3tYeJ+m7RyYmmdpHRmOzATR02+v6m78nkKUCJHtmfHttmdKp xIQ== X-Google-Smtp-Source: AGHT+IFqnX6jxvZcVo3xrldRNx7U1Dqcv2Ygm0qYbXFyglud1wOBELXdqCJyZeJEo9/MJ02eliZZrQ== X-Received: by 2002:a05:6512:b90:b0:51b:58c7:d04d with SMTP id 2adb3069b0e04-5220f6487damr23421038e87.0.1716285870255; Tue, 21 May 2024 03:04:30 -0700 (PDT) Received: from localhost (host-114-191.parnet.fi. [77.234.114.191]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-521f38d878fsm4633485e87.206.2024.05.21.03.04.29 for (version=TLS1 cipher=AES128-SHA bits=128/128); Tue, 21 May 2024 03:04:29 -0700 (PDT) From: =?UTF-8?q?Martin=20Storsj=C3=B6?= To: ffmpeg-devel@ffmpeg.org Date: Tue, 21 May 2024 13:04:29 +0300 Message-Id: <20240521100429.87090-1-martin@martin.st> X-Mailer: git-send-email 2.39.3 (Apple Git-146) MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH] checkasm: vvc_alf: Limit benchmarking to a reasonable subset of functions X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: Don't benchmark every single combination of widths and heights; only benchmark cases which are squares (like in vvc_mc.c). Contrary to vvc_mc, which increases sizes by doubling dimensions, vvc_alf tests all sizes in increments of 4. Limit benchmarking to the cases which are powers of two. This reduces the number of benchmarked cases from 3072 down to 18. --- tests/checkasm/vvc_alf.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/tests/checkasm/vvc_alf.c b/tests/checkasm/vvc_alf.c index 9526260598..6dd89bfafc 100644 --- a/tests/checkasm/vvc_alf.c +++ b/tests/checkasm/vvc_alf.c @@ -103,7 +103,9 @@ static void check_alf_filter(VVCDSPContext *c, const int bit_depth) if (memcmp(dst0 + i * dst_stride, dst1 + i * dst_stride, w * SIZEOF_PIXEL)) fail(); } - bench_new(dst1, dst_stride, src1 + offset, src_stride, w, h, filter, clip, vb_pos); + // Bench only square sizes, and ones with dimensions being a power of two. + if (w == h && (w & (w - 1)) == 0) + bench_new(dst1, dst_stride, src1 + offset, src_stride, w, h, filter, clip, vb_pos); } if (check_func(c->alf.filter[CHROMA], "vvc_alf_filter_chroma_%dx%d_%d", w, h, bit_depth)) { const int vb_pos = ctu_size - ALF_VB_POS_ABOVE_CHROMA; @@ -115,7 +117,8 @@ static void check_alf_filter(VVCDSPContext *c, const int bit_depth) if (memcmp(dst0 + i * dst_stride, dst1 + i * dst_stride, w * SIZEOF_PIXEL)) fail(); } - bench_new(dst1, dst_stride, src1 + offset, src_stride, w, h, filter, clip, vb_pos); + if (w == h && (w & (w - 1)) == 0) + bench_new(dst1, dst_stride, src1 + offset, src_stride, w, h, filter, clip, vb_pos); } } } @@ -156,7 +159,9 @@ static void check_alf_classify(VVCDSPContext *c, const int bit_depth) fail(); if (memcmp(transpose_idx0, transpose_idx1, id_size)) fail(); - bench_new(class_idx1, transpose_idx1, src1 + offset, stride, w, h, vb_pos, alf_gradient_tmp); + // Bench only square sizes, and ones with dimensions being a power of two. + if (w == h && (w & (w - 1)) == 0) + bench_new(class_idx1, transpose_idx1, src1 + offset, stride, w, h, vb_pos, alf_gradient_tmp); } } } -- 2.39.3 (Apple Git-146) _______________________________________________ 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".