From patchwork Wed Nov 24 21:15:20 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Reid X-Patchwork-Id: 31633 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a6b:d206:0:0:0:0:0 with SMTP id q6csp11121575iob; Wed, 24 Nov 2021 13:15:49 -0800 (PST) X-Google-Smtp-Source: ABdhPJwg3/+DgXY4ItHfA0E/BMonlycWFzvZG0EnzhnDj+953SgYK9QobfkkWcHjrXbIP3U6r2ol X-Received: by 2002:aa7:c2c6:: with SMTP id m6mr29043888edp.42.1637788548898; Wed, 24 Nov 2021 13:15:48 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1637788548; cv=none; d=google.com; s=arc-20160816; b=m8iRgnPyMkkZeTKtJBFE2JX3prskNlKMkP3WjSSMCTQXiS/Z/szD2caAVTMc4ohp1O M+86S7kxmYL5EEqBflpAz0K+yr51HyuHv5S348ENkCU+MBJ078Ar5CnTHI5JqIealKIX 66rfZWuKuxS7hmdP71bPT6MHTvBlLw02lFg39HjEUGOQitWi1cjNWVJYhamG19mxmiKl xVrckOdosItwBa4TLX9MNawV05K9+2bNKwMU0qbOZSSV/jfYiXNTId+SxLY/QD+t5jsj E+25t73ZS36yTnoRCPhlIJDRcZ+WWxVytvrq4okjKkXpO1+PU7zjHsHecQotMTeAC5Di 1qrQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:cc:reply-to :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:mime-version:message-id:date:to:from :dkim-signature:delivered-to; bh=LqGxBgRH9USvCfbz+XFPsSqsX2steBjwcFxLYL3BdqA=; b=FgEvfShs84gcKBKtg/9aZsSDVDmH/xfWEx3A+nSPu4YsuO+BFJ//dMmK1OvfZqE6f4 L1BFDrSlhn1ApstD1SfOvHC2b5rU6VydemgYYSIH3HzxaRCWBYSLzRZI3ZKsBDs1A5E3 lwi/SbfhpaZrJOpl3nXu7fcL03uPGtJKV8DE2Snv/RInfjnbm0/iNw1l+ychfcl3frVT fZgAFruFVvvzcGkd+zpnjhaGz1HT6BMwWSkmmehwFZTUDG3U6167010PCe/PuBGXILJJ VxugFahuWeBWgnn4tLEq/Jv4mWSD5fCGie6fana0KEOwvuGcRnOXHiyH7BS6c82VLuje 9m9Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20210112 header.b=EeETguTX; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id c12si2578358edx.280.2021.11.24.13.15.47; Wed, 24 Nov 2021 13:15:48 -0800 (PST) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20210112 header.b=EeETguTX; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 0FF0068A93E; Wed, 24 Nov 2021 23:15:43 +0200 (EET) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-pj1-f51.google.com (mail-pj1-f51.google.com [209.85.216.51]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 19F6968A43D for ; Wed, 24 Nov 2021 23:15:37 +0200 (EET) Received: by mail-pj1-f51.google.com with SMTP id gb13-20020a17090b060d00b001a674e2c4a8so3865490pjb.4 for ; Wed, 24 Nov 2021 13:15:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=e4LaAySUpHvpK1WeH3A2LGiLqCglg2yA5xtqnF+NKJk=; b=EeETguTXCrdiSt+xXqBFJL3gxswTd7TIOtc7Wrp/l3+pC2O2+vMAOxjI9WXo9V7yPm IqbB1HsCnNzr8Zh4TUbzQH2gfVk8Ce2ct69KhxgLfafNnaVnveecSGuhyeahYT4BXYCS 5IZ362w5ecqHUDdqa1ZWWZxom09xCqg0TByxYTrZOF6MDPn7d1bPlFXXEngccRIqTB/9 vCHn4FDy2GqpIAkmVVqSqqXv/wgTHTuxPt5gj3T6OSUPVWSJ7MMNHLPE6XHxioO2fB/P LM38qaqfWJtmLRlGlpltcj/Li7qainrakll6mZu53KGUwmCx3v1VPtGrf3EoQk41p5Fs 9sBg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=e4LaAySUpHvpK1WeH3A2LGiLqCglg2yA5xtqnF+NKJk=; b=HDbENNFpciWYMMj0iL32j2Fyncp5hKWCF2eHGCS/L2DQPnmuqAQFPQwbDGdmm4hP/h Poe/ZdeHA9iFXe3I+SBFezqdhnHtTAU+kCteUCp9R6z5R3yU4xsm3A8NsshVkMJpV8VS L6Tw9gpuVlEWZnfUZJRrCW9PSdt6CZ+sip+p0nBEQ/Ah5UxgpAGOYNFLT3EkFROG5ins 0pDKxBkIrSSkhgTrGHHSoZAUioGNrng6YHvWRdo+ve48nRaxseMA2aZQMN9WAfyOByx9 rurUe2vt5h29hRK+htxWTbXa3n0BZtYp0HDmFNmYGqPquBT0+EJEwBqtRKGwiGInrbky 8jJA== X-Gm-Message-State: AOAM533Lu+uxtZiXdOub52t5R1GudSO/CZgk0L9TCQ3vW5ezmwZ5seXK OMdmI77zyU7rMhh2MkWSHTxFgtXcpS0= X-Received: by 2002:a17:90b:1a88:: with SMTP id ng8mr88301pjb.180.1637788534271; Wed, 24 Nov 2021 13:15:34 -0800 (PST) Received: from localhost.localdomain (S0106bc4dfba470f3.vc.shawcable.net. [174.7.244.175]) by smtp.gmail.com with ESMTPSA id j13sm444971pgm.35.2021.11.24.13.15.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 24 Nov 2021 13:15:33 -0800 (PST) From: mindmark@gmail.com To: ffmpeg-devel@ffmpeg.org Date: Wed, 24 Nov 2021 13:15:20 -0800 Message-Id: <20211124211521.1509-1-mindmark@gmail.com> X-Mailer: git-send-email 2.31.1.windows.1 MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH v3 1/2] swscale/x86/output.asm: add x86-optimized planer gbr yuv2anyX 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 Cc: Mark Reid Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: I5AHRMSeWqYj From: Mark Reid changes since v2: * fixed label changes since v1: * remove vex intruction on sse4 path * some load/pack marcos use less intructions * fixed some typos yuv2gbrp_full_X_4_512_c: 12757.6 yuv2gbrp_full_X_4_512_sse2: 8946.6 yuv2gbrp_full_X_4_512_sse4: 5138.6 yuv2gbrp_full_X_4_512_avx2: 3889.6 yuv2gbrap_full_X_4_512_c: 15368.6 yuv2gbrap_full_X_4_512_sse2: 11916.1 yuv2gbrap_full_X_4_512_sse4: 6294.6 yuv2gbrap_full_X_4_512_avx2: 3477.1 yuv2gbrp9be_full_X_4_512_c: 14381.6 yuv2gbrp9be_full_X_4_512_sse2: 9139.1 yuv2gbrp9be_full_X_4_512_sse4: 5150.1 yuv2gbrp9be_full_X_4_512_avx2: 2834.6 yuv2gbrp9le_full_X_4_512_c: 12990.1 yuv2gbrp9le_full_X_4_512_sse2: 9118.1 yuv2gbrp9le_full_X_4_512_sse4: 5132.1 yuv2gbrp9le_full_X_4_512_avx2: 2833.1 yuv2gbrp10be_full_X_4_512_c: 14401.6 yuv2gbrp10be_full_X_4_512_sse2: 9133.1 yuv2gbrp10be_full_X_4_512_sse4: 5126.1 yuv2gbrp10be_full_X_4_512_avx2: 2837.6 yuv2gbrp10le_full_X_4_512_c: 12718.1 yuv2gbrp10le_full_X_4_512_sse2: 9106.1 yuv2gbrp10le_full_X_4_512_sse4: 5120.1 yuv2gbrp10le_full_X_4_512_avx2: 2826.1 yuv2gbrap10be_full_X_4_512_c: 18535.6 yuv2gbrap10be_full_X_4_512_sse2: 33617.6 yuv2gbrap10be_full_X_4_512_sse4: 6264.1 yuv2gbrap10be_full_X_4_512_avx2: 3422.1 yuv2gbrap10le_full_X_4_512_c: 16724.1 yuv2gbrap10le_full_X_4_512_sse2: 11787.1 yuv2gbrap10le_full_X_4_512_sse4: 6282.1 yuv2gbrap10le_full_X_4_512_avx2: 3441.6 yuv2gbrp12be_full_X_4_512_c: 13723.6 yuv2gbrp12be_full_X_4_512_sse2: 9128.1 yuv2gbrp12be_full_X_4_512_sse4: 7997.6 yuv2gbrp12be_full_X_4_512_avx2: 2844.1 yuv2gbrp12le_full_X_4_512_c: 12257.1 yuv2gbrp12le_full_X_4_512_sse2: 9107.6 yuv2gbrp12le_full_X_4_512_sse4: 5142.6 yuv2gbrp12le_full_X_4_512_avx2: 2837.6 yuv2gbrap12be_full_X_4_512_c: 18511.1 yuv2gbrap12be_full_X_4_512_sse2: 12156.6 yuv2gbrap12be_full_X_4_512_sse4: 6251.1 yuv2gbrap12be_full_X_4_512_avx2: 3444.6 yuv2gbrap12le_full_X_4_512_c: 16687.1 yuv2gbrap12le_full_X_4_512_sse2: 11785.1 yuv2gbrap12le_full_X_4_512_sse4: 6243.6 yuv2gbrap12le_full_X_4_512_avx2: 3446.1 yuv2gbrp14be_full_X_4_512_c: 13690.6 yuv2gbrp14be_full_X_4_512_sse2: 9120.6 yuv2gbrp14be_full_X_4_512_sse4: 5138.1 yuv2gbrp14be_full_X_4_512_avx2: 2843.1 yuv2gbrp14le_full_X_4_512_c: 14995.6 yuv2gbrp14le_full_X_4_512_sse2: 9119.1 yuv2gbrp14le_full_X_4_512_sse4: 5126.1 yuv2gbrp14le_full_X_4_512_avx2: 2843.1 yuv2gbrp16be_full_X_4_512_c: 12367.1 yuv2gbrp16be_full_X_4_512_sse2: 8233.6 yuv2gbrp16be_full_X_4_512_sse4: 4820.1 yuv2gbrp16be_full_X_4_512_avx2: 2666.6 yuv2gbrp16le_full_X_4_512_c: 10904.1 yuv2gbrp16le_full_X_4_512_sse2: 8214.1 yuv2gbrp16le_full_X_4_512_sse4: 4824.1 yuv2gbrp16le_full_X_4_512_avx2: 2629.1 yuv2gbrap16be_full_X_4_512_c: 26569.6 yuv2gbrap16be_full_X_4_512_sse2: 10884.1 yuv2gbrap16be_full_X_4_512_sse4: 5488.1 yuv2gbrap16be_full_X_4_512_avx2: 3272.1 yuv2gbrap16le_full_X_4_512_c: 14010.1 yuv2gbrap16le_full_X_4_512_sse2: 10562.1 yuv2gbrap16le_full_X_4_512_sse4: 5463.6 yuv2gbrap16le_full_X_4_512_avx2: 3255.1 yuv2gbrpf32be_full_X_4_512_c: 14524.1 yuv2gbrpf32be_full_X_4_512_sse2: 8552.6 yuv2gbrpf32be_full_X_4_512_sse4: 4636.1 yuv2gbrpf32be_full_X_4_512_avx2: 2474.6 yuv2gbrpf32le_full_X_4_512_c: 13060.6 yuv2gbrpf32le_full_X_4_512_sse2: 9682.6 yuv2gbrpf32le_full_X_4_512_sse4: 4298.1 yuv2gbrpf32le_full_X_4_512_avx2: 2453.1 yuv2gbrapf32be_full_X_4_512_c: 18629.6 yuv2gbrapf32be_full_X_4_512_sse2: 11363.1 yuv2gbrapf32be_full_X_4_512_sse4: 15201.6 yuv2gbrapf32be_full_X_4_512_avx2: 3727.1 yuv2gbrapf32le_full_X_4_512_c: 16677.6 yuv2gbrapf32le_full_X_4_512_sse2: 10221.6 yuv2gbrapf32le_full_X_4_512_sse4: 5693.6 yuv2gbrapf32le_full_X_4_512_avx2: 3656.6 --- libswscale/x86/output.asm | 434 +++++++++++++++++++++++++++++++++++++- libswscale/x86/swscale.c | 98 +++++++++ tests/checkasm/Makefile | 2 +- tests/checkasm/checkasm.c | 1 + tests/checkasm/checkasm.h | 1 + tests/checkasm/sw_gbrp.c | 198 +++++++++++++++++ tests/fate/checkasm.mak | 1 + 7 files changed, 733 insertions(+), 2 deletions(-) create mode 100644 tests/checkasm/sw_gbrp.c -- 2.31.1.windows.1 diff --git a/libswscale/x86/output.asm b/libswscale/x86/output.asm index 52cf9f2c2e..e277a61449 100644 --- a/libswscale/x86/output.asm +++ b/libswscale/x86/output.asm @@ -38,7 +38,49 @@ pw_32: times 8 dw 32 pd_255: times 8 dd 255 pw_512: times 8 dw 512 pw_1024: times 8 dw 1024 - +pd_65535_invf: times 8 dd 0x37800080 ;1.0/65535.0 +pd_yuv2gbrp16_start: times 8 dd -0x40000000 +pd_yuv2gbrp_y_start: times 8 dd (1 << 9) +pd_yuv2gbrp_uv_start: times 8 dd ((1 << 9) - (128 << 19)) +pd_yuv2gbrp_a_start: times 8 dd (1 << 18) +pd_yuv2gbrp16_offset: times 8 dd 0x10000 ;(1 << 16) +pd_yuv2gbrp16_round13: times 8 dd 0x02000 ;(1 << 13) +pd_yuv2gbrp16_a_offset: times 8 dd 0x20002000 +pd_yuv2gbrp16_upper30: times 8 dd 0x3FFFFFFF ;(1<<30) - 1 +pd_yuv2gbrp16_upper27: times 8 dd 0x07FFFFFF ;(1<<27) - 1 +pd_yuv2gbrp16_upperC: times 8 dd 0xC0000000 +pb_pack_shuffle8: db 0, 4, 8, 12, \ + -1, -1, -1, -1, \ + -1, -1, -1, -1, \ + -1, -1, -1, -1, \ + -1, -1, -1, -1, \ + 0, 4, 8, 12, \ + -1, -1, -1, -1, \ + -1, -1, -1, -1 +pb_pack_shuffle16le: db 0, 1, 4, 5, \ + 8, 9, 12, 13, \ + -1, -1, -1, -1, \ + -1, -1, -1, -1, \ + -1, -1, -1, -1, \ + -1, -1, -1, -1, \ + 0, 1, 4, 5, \ + 8, 9, 12, 13 +pb_pack_shuffle16be: db 1, 0, 5, 4, \ + 9, 8, 13, 12, \ + -1, -1, -1, -1, \ + -1, -1, -1, -1, \ + -1, -1, -1, -1, \ + -1, -1, -1, -1, \ + 1, 0, 5, 4, \ + 9, 8, 13, 12 +pb_shuffle32be: db 3, 2, 1, 0, \ + 7, 6, 5, 4, \ + 11, 10, 9, 8, \ + 15, 14, 13, 12, \ + 3, 2, 1, 0, \ + 7, 6, 5, 4, \ + 11, 10, 9, 8, \ + 15, 14, 13, 12 yuv2nv12_shuffle_mask: times 2 db 0, 4, 8, 12, \ -1, -1, -1, -1, \ -1, -1, -1, -1, \ @@ -549,3 +591,393 @@ yuv2nv12cX_fn yuv2nv12 yuv2nv12cX_fn yuv2nv21 %endif %endif ; ARCH_X86_64 + +;----------------------------------------------------------------------------- +; planar grb yuv2anyX functions +; void ff_yuv2_full_X_(SwsContext *c, const int16_t *lumFilter, +; const int16_t **lumSrcx, int lumFilterSize, +; const int16_t *chrFilter, const int16_t **chrUSrcx, +; const int16_t **chrVSrcx, int chrFilterSize, +; const int16_t **alpSrcx, uint8_t **dest, +; int dstW, int y) +;----------------------------------------------------------------------------- + +%if ARCH_X86_64 +struc SwsContext + .padding: resb 40292 ; offsetof(SwsContext, yuv2rgb_y_offset) + .yuv2rgb_y_offset: resd 1 + .yuv2rgb_y_coeff: resd 1 + .yuv2rgb_v2r_coeff: resd 1 + .yuv2rgb_v2g_coeff: resd 1 + .yuv2rgb_u2g_coeff: resd 1 + .yuv2rgb_u2b_coeff: resd 1 +endstruc + +%define R m0 +%define G m1 +%define B m2 +%define A m3 + +%define Y m4 +%define U m5 +%define V m6 + +; Clip a signed integer to an unsigned power of two range. +; av_clip_uintp2 +; 1 - dest +; 2 - bit position to clip at +%macro CLIPP2 2 + ; (~a) >> 31 & ((1<= 16 + movu m%1, [ptrq + xq*4] +%else + LOAD16 %1, [ptrq + xq*2] +%endif +%endmacro + +; 1 - dest +; 2 - source +%macro STORE8 2 + mov ptrq, %1 + %if mmsize > 16 + pshufb m%2, [pb_pack_shuffle8] + vextractf128 xm4, m%2, 1 + por xm%2, xm4 + movq [ptrq + xq], xm%2 + %else + %if cpuflag(sse4) + pshufb m%2, [pb_pack_shuffle8] + %else + psrldq m4, m%2, 3 + por m%2, m4 + psrldq m4, m%2, 6 + por m%2, m4 + %endif + movd [ptrq + xq], m%2 + %endif +%endmacro + +; 1 - dest +; 2 - source +; 3 - is big endian +%macro STORE16 3 + mov ptrq, %1 + %if mmsize > 16 + %if %3 ; bigendian + pshufb m%2, [pb_pack_shuffle16be] + %else + pshufb m%2, [pb_pack_shuffle16le] + %endif + vpermq m%2, m%2, (3 << 6 | 0 << 4 | 3 << 2 | 0 << 0) + movu [ptrq + xq*2], xm%2 + %else + %if cpuflag(sse4) && %3 ; bigendian + pshufb m%2, [pb_pack_shuffle16be] + %elif cpuflag(sse4) + pshufb m%2, [pb_pack_shuffle16le] + %else + pshuflw m%2, m%2, (1 << 6 | 1 << 4 | 2 << 2 | 0 << 0) + pshufhw m%2, m%2, (1 << 6 | 1 << 4 | 2 << 2 | 0 << 0) + pshufd m%2, m%2, (3 << 6 | 3 << 4 | 2 << 2 | 0 << 0) + %if %3 ; bigendian + psrlw m4, m%2, 8 + psllw m%2, 8 + por m%2, m4 + %endif + %endif + movq [ptrq + xq*2], m%2 + %endif +%endmacro + +%macro SWAP32 1 +%if mmsize > 16 || cpuflag(sse4) + pshufb m%1, [pb_shuffle32be] +%else + psrlw m4, m%1, 8 + psllw m%1, 8 + por m%1, m4 + pshuflw m%1, m%1, (2 << 6 | 3 << 4 | 0 << 2 | 1 << 0) + pshufhw m%1, m%1, (2 << 6 | 3 << 4 | 0 << 2 | 1 << 0) +%endif +%endmacro + +; 1 - dest +; 2 - source +; 3 - depth +; 4 - is big endian +%macro STORE_PIXELS 4 +%if %3 > 16 + %if %4 + SWAP32 %2 + %endif + mov ptrq, %1 + movu [ptrq + xq*4], m%2 +%elif %3 > 8 + STORE16 %1, %2, %4 +%else + STORE8 %1, %2 +%endif +%endmacro + +%macro PMULLO 3 +%if cpuflag(sse4) || mmsize > 16 + pmulld %1, %2, %3 +%else + %ifidni %1, %2 + %else + mova %1, %2 + %endif + pshufd m7, %1, (2 << 6 | 3 << 4 | 0 << 2 | 1 << 0) ; 0xb1 + pshufd m8, %3, (2 << 6 | 3 << 4 | 0 << 2 | 1 << 0) ; 0xb1 + pmuludq m7, m8 + pshufd m7, m7, (3 << 6 | 1 << 4 | 2 << 2 | 0 << 0) ; 0xd8 + pmuludq %1, %3 + pshufd %1, %1, (3 << 6 | 1 << 4 | 2 << 2 | 0 << 0) ; 0xd8 + punpckldq %1, m7 +%endif +%endmacro + +; 1 - name +; 2 - depth +; 3 - has alpha +; 3 - is big endian +; 5 - is float +%macro yuv2gbrp_fn 5 +%define DEPTH %2 +%define HAS_ALPHA %3 +%define IS_BE %4 +%define FLOAT %5 +%define SH (22 + 8 - DEPTH) + +%if DEPTH >= 16 + %define RGB_SHIFT 14 + %define A_SHIFT 14 +%elif 22 != SH + %define RGB_SHIFT SH + %define A_SHIFT (SH-3) +%else + %define RGB_SHIFT 22 + %define A_SHIFT 19 +%endif + +%if DEPTH >= 16 + %define YUV_SHIFT 14 + %define Y_START m9 + %define Y_ROUND [pd_yuv2gbrp16_round13] + %define UV_START m9 + %define A_START m9 + %define A_CLIP2P 30 +%else + %define YUV_SHIFT 10 + %define Y_START [pd_yuv2gbrp_y_start] + %define Y_ROUND m9 + %define UV_START [pd_yuv2gbrp_uv_start] + %define A_START [pd_yuv2gbrp_a_start] + %define A_CLIP2P 27 +%endif + +cglobal yuv2%1_full_X, 12, 14, 16, ptr, lumFilter, lumSrcx, lumFilterSize, chrFilter, chrUSrcx, chrVSrcx, chrFilterSize, alpSrcx, dest, dstW, y, x, j + VBROADCASTSS m10, dword [ptrq + SwsContext.yuv2rgb_y_offset] + VBROADCASTSS m11, dword [ptrq + SwsContext.yuv2rgb_y_coeff] + VBROADCASTSS m12, dword [ptrq + SwsContext.yuv2rgb_v2r_coeff] + VBROADCASTSS m13, dword [ptrq + SwsContext.yuv2rgb_v2g_coeff] + VBROADCASTSS m14, dword [ptrq + SwsContext.yuv2rgb_u2g_coeff] + VBROADCASTSS m15, dword [ptrq + SwsContext.yuv2rgb_u2b_coeff] + +%if DEPTH >= 16 + movu m9, [pd_yuv2gbrp16_start] +%else + mov xq, (1 << (SH-1)) + movq xm9, xq + VBROADCASTSS m9, xm9 +%endif + xor xq, xq + + %%loop_x: + movu Y, Y_START + movu U, UV_START + movu V, UV_START + + xor jq, jq + %%loop_luma: + movsx ptrd, word [lumFilterq + jq*2] + movd xm0, ptrd + VBROADCASTSS m0, xm0 + LOAD_PIXELS 1, lumSrcxq, DEPTH + PMULLO m1, m1, m0 + paddd Y, m1 + inc jd + cmp jd, lumFilterSized + jl %%loop_luma + +%if HAS_ALPHA + cmp alpSrcxq, 0 + je %%skip_alpha_load + xor jq, jq + movu A, A_START + %%loop_alpha: + movsx ptrd, word [lumFilterq + jq*2] + movd xm0, ptrd + VBROADCASTSS m0, xm0 + LOAD_PIXELS 1, alpSrcxq, DEPTH + PMULLO m1, m1, m0 + paddd A, m1 + inc jd + cmp jd, lumFilterSized + jl %%loop_alpha +%if DEPTH >= 16 + psrad A, 1 + paddd A, [pd_yuv2gbrp16_a_offset] +%endif + %%skip_alpha_load: +%endif + xor jq, jq + %%loop_chr: + movsx ptrd, word [chrFilterq + jq*2] + movd xm0, ptrd + VBROADCASTSS m0, xm0 + LOAD_PIXELS 1, chrUSrcxq, DEPTH + LOAD_PIXELS 2, chrVSrcxq, DEPTH + PMULLO m1, m1, m0 + PMULLO m2, m2, m0 + paddd U, m1 + paddd V, m2 + inc jd + cmp jd, chrFilterSized + jl %%loop_chr + + psrad Y, YUV_SHIFT +%if DEPTH >= 16 + paddd Y, [pd_yuv2gbrp16_offset] +%endif + psrad U, YUV_SHIFT + psrad V, YUV_SHIFT + + psubd Y, m10 ; yuv2rgb_y_offset + PMULLO Y, Y, m11 ; yuv2rgb_y_coeff + paddd Y, Y_ROUND + + PMULLO R, V, m12 ; yuv2rgb_v2r_coeff + PMULLO B, U, m15 ; yuv2rgb_u2b_coeff + + PMULLO U, U, m14 ; yuv2rgb_u2g_coeff + PMULLO V, V, m13 ; yuv2rgb_v2g_coeff + paddd G, U, V + paddd R, Y + paddd G, Y + paddd B, Y + + CLIPP2 R, 30 + CLIPP2 G, 30 + CLIPP2 B, 30 + + psrad R, RGB_SHIFT + psrad G, RGB_SHIFT + psrad B, RGB_SHIFT + +%if FLOAT + cvtdq2ps R, R + cvtdq2ps G, G + cvtdq2ps B, B + mulps R, [pd_65535_invf] + mulps G, [pd_65535_invf] + mulps B, [pd_65535_invf] +%endif + STORE_PIXELS [destq + 0], 1, DEPTH, IS_BE ; G + STORE_PIXELS [destq + 8], 2, DEPTH, IS_BE ; B + STORE_PIXELS [destq + 16], 0, DEPTH, IS_BE ; R + +%if HAS_ALPHA + cmp alpSrcxq, 0 + je %%skip_alpha_store + CLIPP2 A, A_CLIP2P + psrad A, A_SHIFT +%if FLOAT + cvtdq2ps A, A + mulps A, [pd_65535_invf] +%endif + STORE_PIXELS [destq + 24], 3, DEPTH, IS_BE + %%skip_alpha_store: +%endif + add xq, mmsize/4 + cmp xd, dstWd + jl %%loop_x + + RET +%endmacro + +%macro yuv2gbrp_fn_decl 2 +INIT_%1 %2 +yuv2gbrp_fn gbrp, 8, 0, 0, 0 +yuv2gbrp_fn gbrap, 8, 1, 0, 0 +yuv2gbrp_fn gbrp9le, 9, 0, 0, 0 +yuv2gbrp_fn gbrp10le, 10, 0, 0, 0 +yuv2gbrp_fn gbrap10le, 10, 1, 0, 0 +yuv2gbrp_fn gbrp12le, 12, 0, 0, 0 +yuv2gbrp_fn gbrap12le, 12, 1, 0, 0 +yuv2gbrp_fn gbrp14le, 14, 0, 0, 0 +yuv2gbrp_fn gbrp16le, 16, 0, 0, 0 +yuv2gbrp_fn gbrap16le, 16, 1, 0, 0 +yuv2gbrp_fn gbrpf32le, 32, 0, 0, 1 +yuv2gbrp_fn gbrapf32le, 32, 1, 0, 1 + +yuv2gbrp_fn gbrp9be, 9, 0, 1, 0 +yuv2gbrp_fn gbrp10be, 10, 0, 1, 0 +yuv2gbrp_fn gbrap10be, 10, 1, 1, 0 +yuv2gbrp_fn gbrp12be, 12, 0, 1, 0 +yuv2gbrp_fn gbrap12be, 12, 1, 1, 0 +yuv2gbrp_fn gbrp14be, 14, 0, 1, 0 +yuv2gbrp_fn gbrp16be, 16, 0, 1, 0 +yuv2gbrp_fn gbrap16be, 16, 1, 1, 0 +yuv2gbrp_fn gbrpf32be, 32, 0, 1, 1 +yuv2gbrp_fn gbrapf32be, 32, 1, 1, 1 +%endmacro + +yuv2gbrp_fn_decl XMM, sse2 +yuv2gbrp_fn_decl XMM, sse4 + +%if HAVE_AVX2_EXTERNAL +yuv2gbrp_fn_decl YMM, avx2 +%endif + +%endif ; ARCH_X86_64 \ No newline at end of file diff --git a/libswscale/x86/swscale.c b/libswscale/x86/swscale.c index 0848a31461..e8bc15b6ee 100644 --- a/libswscale/x86/swscale.c +++ b/libswscale/x86/swscale.c @@ -350,6 +350,43 @@ void ff_yuv2 ## fmt ## cX_ ## opt(enum AVPixelFormat format, const uint8_t *dith YUV2NV_DECL(nv12, avx2); YUV2NV_DECL(nv21, avx2); + +#define YUV2GBRP_FN_DECL(fmt, opt) \ +void ff_yuv2##fmt##_full_X_ ##opt(SwsContext *c, const int16_t *lumFilter, \ + const int16_t **lumSrcx, int lumFilterSize, \ + const int16_t *chrFilter, const int16_t **chrUSrcx, \ + const int16_t **chrVSrcx, int chrFilterSize, \ + const int16_t **alpSrcx, uint8_t **dest, \ + int dstW, int y) + +#define YUV2GBRP_DECL(opt) \ +YUV2GBRP_FN_DECL(gbrp, opt); \ +YUV2GBRP_FN_DECL(gbrap, opt); \ +YUV2GBRP_FN_DECL(gbrp9le, opt); \ +YUV2GBRP_FN_DECL(gbrp10le, opt); \ +YUV2GBRP_FN_DECL(gbrap10le, opt); \ +YUV2GBRP_FN_DECL(gbrp12le, opt); \ +YUV2GBRP_FN_DECL(gbrap12le, opt); \ +YUV2GBRP_FN_DECL(gbrp14le, opt); \ +YUV2GBRP_FN_DECL(gbrp16le, opt); \ +YUV2GBRP_FN_DECL(gbrap16le, opt); \ +YUV2GBRP_FN_DECL(gbrpf32le, opt); \ +YUV2GBRP_FN_DECL(gbrapf32le, opt); \ +YUV2GBRP_FN_DECL(gbrp9be, opt); \ +YUV2GBRP_FN_DECL(gbrp10be, opt); \ +YUV2GBRP_FN_DECL(gbrap10be, opt); \ +YUV2GBRP_FN_DECL(gbrp12be, opt); \ +YUV2GBRP_FN_DECL(gbrap12be, opt); \ +YUV2GBRP_FN_DECL(gbrp14be, opt); \ +YUV2GBRP_FN_DECL(gbrp16be, opt); \ +YUV2GBRP_FN_DECL(gbrap16be, opt); \ +YUV2GBRP_FN_DECL(gbrpf32be, opt); \ +YUV2GBRP_FN_DECL(gbrapf32be, opt); + +YUV2GBRP_DECL(sse2); +YUV2GBRP_DECL(sse4); +YUV2GBRP_DECL(avx2); + #endif av_cold void ff_sws_init_swscale_x86(SwsContext *c) @@ -582,5 +619,66 @@ switch(c->dstBpc){ \ break; } } + + if(c->flags & SWS_FULL_CHR_H_INT) { + + /* yuv2gbrp uses the SwsContext for yuv coefficients + if struct offsets change the asm needs to be updated too */ + av_assert0(offsetof(SwsContext, yuv2rgb_y_offset) == 40292); + +#define YUV2ANYX_FUNC_CASE(fmt, name, opt) \ + case fmt: \ + c->yuv2anyX = ff_yuv2##name##_full_X_##opt; \ + break; + +#define YUV2ANYX_GBRAP_CASES(opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRP, gbrp, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRAP, gbrap, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRP9LE, gbrp9le, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRP10LE, gbrp10le, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRAP10LE, gbrap10le, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRP12LE, gbrp12le, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRAP12LE, gbrap12le, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRP14LE, gbrp14le, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRP16LE, gbrp16le, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRAP16LE, gbrap16le, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRPF32LE, gbrpf32le, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRAPF32LE, gbrapf32le, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRP9BE, gbrp9be, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRP10BE, gbrp10be, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRAP10BE, gbrap10be, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRP12BE, gbrp12be, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRAP12BE, gbrap12be, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRP14BE, gbrp14be, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRP16BE, gbrp16be, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRAP16BE, gbrap16be, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRPF32BE, gbrpf32be, opt) \ + YUV2ANYX_FUNC_CASE(AV_PIX_FMT_GBRAPF32BE, gbrapf32be, opt) + + if (EXTERNAL_SSE2(cpu_flags)) { + switch (c->dstFormat) { + YUV2ANYX_GBRAP_CASES(sse2) + default: + break; + } + } + + if (EXTERNAL_SSE4(cpu_flags)) { + switch (c->dstFormat) { + YUV2ANYX_GBRAP_CASES(sse4) + default: + break; + } + } + + if (EXTERNAL_AVX2_FAST(cpu_flags)) { + switch (c->dstFormat) { + YUV2ANYX_GBRAP_CASES(avx2) + default: + break; + } + } + } + #endif } diff --git a/tests/checkasm/Makefile b/tests/checkasm/Makefile index 4ef5fa87da..f768b1144e 100644 --- a/tests/checkasm/Makefile +++ b/tests/checkasm/Makefile @@ -45,7 +45,7 @@ AVFILTEROBJS-$(CONFIG_NLMEANS_FILTER) += vf_nlmeans.o CHECKASMOBJS-$(CONFIG_AVFILTER) += $(AVFILTEROBJS-yes) # swscale tests -SWSCALEOBJS += sw_rgb.o sw_scale.o +SWSCALEOBJS += sw_gbrp.o sw_rgb.o sw_scale.o CHECKASMOBJS-$(CONFIG_SWSCALE) += $(SWSCALEOBJS) diff --git a/tests/checkasm/checkasm.c b/tests/checkasm/checkasm.c index b1353f7cbe..5fa8ac7bcc 100644 --- a/tests/checkasm/checkasm.c +++ b/tests/checkasm/checkasm.c @@ -183,6 +183,7 @@ static const struct { #endif #endif #if CONFIG_SWSCALE + { "sw_gbrp", checkasm_check_sw_gbrp }, { "sw_rgb", checkasm_check_sw_rgb }, { "sw_scale", checkasm_check_sw_scale }, #endif diff --git a/tests/checkasm/checkasm.h b/tests/checkasm/checkasm.h index 68b0697d3e..c3192d8c23 100644 --- a/tests/checkasm/checkasm.h +++ b/tests/checkasm/checkasm.h @@ -72,6 +72,7 @@ void checkasm_check_opusdsp(void); void checkasm_check_pixblockdsp(void); void checkasm_check_sbrdsp(void); void checkasm_check_synth_filter(void); +void checkasm_check_sw_gbrp(void); void checkasm_check_sw_rgb(void); void checkasm_check_sw_scale(void); void checkasm_check_utvideodsp(void); diff --git a/tests/checkasm/sw_gbrp.c b/tests/checkasm/sw_gbrp.c new file mode 100644 index 0000000000..61b2b9d6a1 --- /dev/null +++ b/tests/checkasm/sw_gbrp.c @@ -0,0 +1,198 @@ +/* + * + * This file is part of FFmpeg. + * + * FFmpeg is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * FFmpeg is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with FFmpeg; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + */ + +#include + +#include "libavutil/common.h" +#include "libavutil/intreadwrite.h" +#include "libavutil/mem_internal.h" +#include "libavutil/pixdesc.h" + +#include "libswscale/swscale.h" +#include "libswscale/swscale_internal.h" + +#include "checkasm.h" + +#define randomize_buffers(buf, size) \ + do { \ + int j; \ + for (j = 0; j < size; j+=4) \ + AV_WN32(buf + j, rnd()); \ + } while (0) + +static const int planar_fmts[] = { + AV_PIX_FMT_GBRP, + AV_PIX_FMT_GBRP9BE, + AV_PIX_FMT_GBRP9LE, + AV_PIX_FMT_GBRP10BE, + AV_PIX_FMT_GBRP10LE, + AV_PIX_FMT_GBRP12BE, + AV_PIX_FMT_GBRP12LE, + AV_PIX_FMT_GBRP14BE, + AV_PIX_FMT_GBRP14LE, + AV_PIX_FMT_GBRAP, + AV_PIX_FMT_GBRAP10BE, + AV_PIX_FMT_GBRAP10LE, + AV_PIX_FMT_GBRAP12BE, + AV_PIX_FMT_GBRAP12LE, + AV_PIX_FMT_GBRP16BE, + AV_PIX_FMT_GBRP16LE, + AV_PIX_FMT_GBRAP16BE, + AV_PIX_FMT_GBRAP16LE, + AV_PIX_FMT_GBRPF32BE, + AV_PIX_FMT_GBRPF32LE, + AV_PIX_FMT_GBRAPF32BE, + AV_PIX_FMT_GBRAPF32LE +}; + +static void check_output_yuv2gbrp(void) +{ + struct SwsContext *ctx; + const AVPixFmtDescriptor *desc; + int fmi, fsi, isi, i; + int dstW, byte_size, luma_filter_size, chr_filter_size; +#define LARGEST_FILTER 16 +#define FILTER_SIZES 4 + static const int filter_sizes[] = {1, 4, 8, 16}; +#define LARGEST_INPUT_SIZE 512 +#define INPUT_SIZES 6 + static const int input_sizes[] = {8, 24, 128, 144, 256, 512}; + uint8_t *dst0[4]; + uint8_t *dst1[4]; + + declare_func(void, void *c, const int16_t *lumFilter, + const int16_t **lumSrcx, int lumFilterSize, + const int16_t *chrFilter, const int16_t **chrUSrcx, + const int16_t **chrVSrcx, int chrFilterSize, + const int16_t **alpSrcx, uint8_t **dest, + int dstW, int y); + + const int16_t *luma[LARGEST_FILTER]; + const int16_t *chru[LARGEST_FILTER]; + const int16_t *chrv[LARGEST_FILTER]; + const int16_t *alpha[LARGEST_FILTER]; + + LOCAL_ALIGNED_8(int16_t, luma_filter, [LARGEST_FILTER]); + LOCAL_ALIGNED_8(int16_t, chr_filter, [LARGEST_FILTER]); + + LOCAL_ALIGNED_8(int32_t, src_y, [LARGEST_FILTER * LARGEST_INPUT_SIZE]); + LOCAL_ALIGNED_8(int32_t, src_u, [LARGEST_FILTER * LARGEST_INPUT_SIZE]); + LOCAL_ALIGNED_8(int32_t, src_v, [LARGEST_FILTER * LARGEST_INPUT_SIZE]); + LOCAL_ALIGNED_8(int32_t, src_a, [LARGEST_FILTER * LARGEST_INPUT_SIZE]); + + LOCAL_ALIGNED_8(uint8_t, dst0_r, [LARGEST_INPUT_SIZE * sizeof(int32_t)]); + LOCAL_ALIGNED_8(uint8_t, dst0_g, [LARGEST_INPUT_SIZE * sizeof(int32_t)]); + LOCAL_ALIGNED_8(uint8_t, dst0_b, [LARGEST_INPUT_SIZE * sizeof(int32_t)]); + LOCAL_ALIGNED_8(uint8_t, dst0_a, [LARGEST_INPUT_SIZE * sizeof(int32_t)]); + + LOCAL_ALIGNED_8(uint8_t, dst1_r, [LARGEST_INPUT_SIZE * sizeof(int32_t)]); + LOCAL_ALIGNED_8(uint8_t, dst1_g, [LARGEST_INPUT_SIZE * sizeof(int32_t)]); + LOCAL_ALIGNED_8(uint8_t, dst1_b, [LARGEST_INPUT_SIZE * sizeof(int32_t)]); + LOCAL_ALIGNED_8(uint8_t, dst1_a, [LARGEST_INPUT_SIZE * sizeof(int32_t)]); + + randomize_buffers((uint8_t*)src_y, LARGEST_FILTER * LARGEST_INPUT_SIZE * sizeof(int32_t)); + randomize_buffers((uint8_t*)src_u, LARGEST_FILTER * LARGEST_INPUT_SIZE * sizeof(int32_t)); + randomize_buffers((uint8_t*)src_v, LARGEST_FILTER * LARGEST_INPUT_SIZE * sizeof(int32_t)); + randomize_buffers((uint8_t*)src_a, LARGEST_FILTER * LARGEST_INPUT_SIZE * sizeof(int32_t)); + randomize_buffers((uint8_t*)luma_filter, LARGEST_FILTER * sizeof(int16_t)); + randomize_buffers((uint8_t*)chr_filter, LARGEST_FILTER * sizeof(int16_t)); + + dst0[0] = (uint8_t*)dst0_g; + dst0[1] = (uint8_t*)dst0_b; + dst0[2] = (uint8_t*)dst0_r; + dst0[3] = (uint8_t*)dst0_a; + + dst1[0] = (uint8_t*)dst1_g; + dst1[1] = (uint8_t*)dst1_b; + dst1[2] = (uint8_t*)dst1_r; + dst1[3] = (uint8_t*)dst1_a; + + for (i = 0; i < LARGEST_FILTER; i++) { + luma[i] = (int16_t *)(src_y + i*LARGEST_INPUT_SIZE); + chru[i] = (int16_t *)(src_u + i*LARGEST_INPUT_SIZE); + chrv[i] = (int16_t *)(src_v + i*LARGEST_INPUT_SIZE); + alpha[i] = (int16_t *)(src_a + i*LARGEST_INPUT_SIZE); + } + + ctx = sws_alloc_context(); + if (sws_init_context(ctx, NULL, NULL) < 0) + fail(); + + ctx->flags |= SWS_FULL_CHR_H_INT; + ctx->yuv2rgb_y_offset = rnd(); + ctx->yuv2rgb_y_coeff = rnd(); + ctx->yuv2rgb_v2r_coeff = rnd(); + ctx->yuv2rgb_v2g_coeff = rnd(); + ctx->yuv2rgb_u2g_coeff = rnd(); + ctx->yuv2rgb_u2b_coeff = rnd(); + + for (fmi = 0; fmi < FF_ARRAY_ELEMS(planar_fmts); fmi++) { + for (fsi = 0; fsi < FILTER_SIZES; fsi++) { + for (isi = 0; isi < INPUT_SIZES; isi++ ) { + desc = av_pix_fmt_desc_get(planar_fmts[fmi]); + ctx->dstFormat = planar_fmts[fmi]; + + dstW = input_sizes[isi]; + luma_filter_size = filter_sizes[fsi]; + chr_filter_size = filter_sizes[fsi]; + + if (desc->comp[0].depth > 16) { + byte_size = 4; + } else if (desc->comp[0].depth > 8) { + byte_size = 2; + } else { + byte_size = 1; + } + + ff_sws_init_scale(ctx); + if (check_func(ctx->yuv2anyX, "yuv2%s_full_X_%d_%d", desc->name, luma_filter_size, dstW)) { + for (i = 0; i < 4; i ++) { + memset(dst0[i], 0xFF, LARGEST_INPUT_SIZE * sizeof(int32_t)); + memset(dst1[i], 0xFF, LARGEST_INPUT_SIZE * sizeof(int32_t)); + } + + call_ref(ctx, luma_filter, luma, luma_filter_size, + chr_filter, chru, chrv, chr_filter_size, + alpha, dst0, dstW, 0); + call_new(ctx, luma_filter, luma, luma_filter_size, + chr_filter, chru, chrv, chr_filter_size, + alpha, dst1, dstW, 0); + + if (memcmp(dst0[0], dst1[0], dstW * byte_size) || + memcmp(dst0[1], dst1[1], dstW * byte_size) || + memcmp(dst0[2], dst1[2], dstW * byte_size) || + memcmp(dst0[3], dst1[3], dstW * byte_size) ) + fail(); + + bench_new(ctx, luma_filter, luma, luma_filter_size, + chr_filter, chru, chrv, chr_filter_size, + alpha, dst1, dstW, 0); + } + } + } + } + sws_freeContext(ctx); +} + + +void checkasm_check_sw_gbrp(void) +{ + check_output_yuv2gbrp(); + report("output_yuv2gbrp"); +} diff --git a/tests/fate/checkasm.mak b/tests/fate/checkasm.mak index 6e7edbe655..6db8f09d12 100644 --- a/tests/fate/checkasm.mak +++ b/tests/fate/checkasm.mak @@ -26,6 +26,7 @@ FATE_CHECKASM = fate-checkasm-aacpsdsp \ fate-checkasm-pixblockdsp \ fate-checkasm-sbrdsp \ fate-checkasm-synth_filter \ + fate-checkasm-sw_gbrp \ fate-checkasm-sw_rgb \ fate-checkasm-sw_scale \ fate-checkasm-utvideodsp \