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 97C7345A71 for ; Thu, 13 Apr 2023 12:16:18 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id D67A968BB41; Thu, 13 Apr 2023 15:16:16 +0300 (EEST) Received: from mail8.parnet.fi (mail8.parnet.fi [77.234.108.134]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 6438D68B6D3 for ; Thu, 13 Apr 2023 15:16:10 +0300 (EEST) Received: from mail9.parnet.fi (mail9.parnet.fi [77.234.108.21]) by mail8.parnet.fi with ESMTP id 33DCG9VX023188-33DCG9VY023188; Thu, 13 Apr 2023 15:16:09 +0300 Received: from foo.martin.st (host-97-187.parnet.fi [77.234.97.187]) by mail9.parnet.fi (Postfix) with ESMTPS id BA76BA1435; Thu, 13 Apr 2023 15:16:08 +0300 (EEST) Date: Thu, 13 Apr 2023 15:16:08 +0300 (EEST) From: =?ISO-8859-15?Q?Martin_Storsj=F6?= To: FFmpeg development discussions and patches In-Reply-To: Message-ID: <14ff3ac3-57d4-c359-5837-a68ecd9fbec9@martin.st> References: MIME-Version: 1.0 X-FE-Policy-ID: 3:14:2:SYSTEM Subject: Re: [FFmpeg-devel] [PATCH] checkasm/hevc: add transform_luma test 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 Cc: xufuji456 <839789740@qq.com> Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: On Thu, 13 Apr 2023, xufuji456 wrote: > Signed-off-by: xufuji456 <839789740@qq.com> > --- > tests/checkasm/hevc_idct.c | 29 +++++++++++++++++++++++++++++ > 1 file changed, 29 insertions(+) > > diff --git a/tests/checkasm/hevc_idct.c b/tests/checkasm/hevc_idct.c > index 338b8a23e4..446d69f931 100644 > --- a/tests/checkasm/hevc_idct.c > +++ b/tests/checkasm/hevc_idct.c > @@ -84,6 +84,27 @@ static void check_idct_dc(HEVCDSPContext h, int bit_depth) > } > } > > +static void check_transform_luma(HEVCDSPContext *h, int bit_depth) > +{ > + LOCAL_ALIGNED(32, int16_t, coeffs0, [32 * 32]); > + LOCAL_ALIGNED(32, int16_t, coeffs1, [32 * 32]); > + > + int block_size = 4; > + int size = block_size * block_size; > + declare_func_emms(AV_CPU_FLAG_MMXEXT, void, int16_t *coeffs); > + > + randomize_buffers(coeffs0, size); > + memcpy(coeffs1, coeffs0, sizeof(*coeffs0) * size); > + > + if (check_func(h->transform_4x4_luma, "hevc_transform_luma_4x4_%d", bit_depth)) { > + call_ref(coeffs0); > + call_new(coeffs1); > + if (memcmp(coeffs0, coeffs1, sizeof(*coeffs0) * size)) > + fail(); > + bench_new(coeffs1); > + } > +} > + > void checkasm_check_hevc_idct(void) > { > int bit_depth; > @@ -103,4 +124,12 @@ void checkasm_check_hevc_idct(void) > check_idct(h, bit_depth); > } > report("idct"); > + > + for (bit_depth = 8; bit_depth <= 12; bit_depth += 2) { > + HEVCDSPContext h; > + > + ff_hevc_dsp_init(&h, bit_depth); > + check_transform_luma(&h, bit_depth); > + } > + report("transform_luma"); > } > -- > 2.32.0 (Apple Git-132) LGTM, thanks, will push in a moment. // Martin _______________________________________________ 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".