From patchwork Fri Aug 27 04:51:42 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wu Jianhua X-Patchwork-Id: 29798 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6602:2a4a:0:0:0:0 with SMTP id k10csp1118996iov; Thu, 26 Aug 2021 21:52:13 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwEd9bANn1v6SDwUQq1UzMkUnkzLSrW/8dMMRkT5NCZiLS+6R/5EL8AFEPIC6cqmrzK5zF1 X-Received: by 2002:a17:906:aada:: with SMTP id kt26mr7993220ejb.199.1630039933036; Thu, 26 Aug 2021 21:52:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1630039933; cv=none; d=google.com; s=arc-20160816; b=mM4wxx7kKxHQClCLPDqKNHpYF8NwZ7H6NFxUM7rbyuydLtzwjXFM4UFeBjzqHEbRbG v2+HbBL3l4ZwdlamgVSrWIJIVszMl8gFJOKUUAkr6DWB9trmgQmWGn3h9/oJfPM9WYVR x1zlvQecKcZtPDrZZarBnf4ft4RqgztusFYNJdhQbXL1pEyLY5IDaD3qimWm6LbJKLy8 CcpM03E1X8CoVabYFyKltD4z5wos0cxkF6jjVvHsOt/m2YCEld8rQhzfWwoBBZKkTxuV 3tbMRKTf2rXaUsbqk9z9ECMTcq9ds1zYMd6ZIx0NHh1cKBGLaFmL1h3WPL1k8f/ZBPTr /rbA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version:cc:reply-to :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:delivered-to; bh=AwpNjNqkICCFv8Bf8mPhOg2y8pAgiqTboxmm6UxKLtU=; b=hUT/XalxZlLrvLnZ4urznprEcMyFF5t7eRpjVw47WCxsyQ9HRij9ZsCVOrMfM9sYh2 XJLvWjtQ8yUltOds4Of6KdU9bVW8/anXZ1Di6wEsVrYU0pwUlscDmlMVJ0CxNbs1DDqf hh16e/V5xb03xpFt3nlKZ8Wzlew58oB7Y++w81FTEnAZZBy2WpnD1BoiEUlp08SssxT4 RuPdd7BWCt8f/fmACF02dHC3PwkgGUwdXBGs9m9yjQJ9JrXXEC6bgOLjkFnw9miP32+P jJumEJawPIQ1PJ4M2VBVOw0mwq8xXhJgRxmF+Tgj4vRrkcV5mHbk129BUfwtkY0HqiCj qU/A== ARC-Authentication-Results: i=1; mx.google.com; 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=NONE dis=NONE) header.from=intel.com Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id h10si5461156edk.552.2021.08.26.21.52.12; Thu, 26 Aug 2021 21:52:13 -0700 (PDT) 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; 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=NONE dis=NONE) header.from=intel.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id ACF0A68A306; Fri, 27 Aug 2021 07:52:01 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id E093268834D for ; Fri, 27 Aug 2021 07:51:53 +0300 (EEST) X-IronPort-AV: E=McAfee;i="6200,9189,10088"; a="281613550" X-IronPort-AV: E=Sophos;i="5.84,355,1620716400"; d="scan'208";a="281613550" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 26 Aug 2021 21:51:51 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.84,355,1620716400"; d="scan'208";a="495523691" Received: from otc-skl-e5-server.sh.intel.com ([10.239.43.106]) by fmsmga008.fm.intel.com with ESMTP; 26 Aug 2021 21:51:50 -0700 From: Wu Jianhua To: ffmpeg-devel@ffmpeg.org Date: Fri, 27 Aug 2021 12:51:42 +0800 Message-Id: <20210827045144.73794-2-jianhua.wu@intel.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20210827045144.73794-1-jianhua.wu@intel.com> References: <20210827045144.73794-1-jianhua.wu@intel.com> Subject: [FFmpeg-devel] [PATCH 2/4] libavfilter/x86/vf_threshold_init: remove condition s->depth == 16 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: Wu Jianhua MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: CD2zUe7nvecZ As we all know the 10bit samples would also be stored as a 16bits type, the condition judgment will lead the SIMD optimizations to be uninitialized when the depth is 10. Signed-off-by: Wu Jianhua --- libavfilter/x86/vf_threshold_init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavfilter/x86/vf_threshold_init.c b/libavfilter/x86/vf_threshold_init.c index 8e42296791..71bde15097 100644 --- a/libavfilter/x86/vf_threshold_init.c +++ b/libavfilter/x86/vf_threshold_init.c @@ -48,7 +48,7 @@ av_cold void ff_threshold_init_x86(ThresholdContext *s) if (EXTERNAL_AVX2_FAST(cpu_flags)) { s->threshold = ff_threshold8_avx2; } - } else if (s->depth == 16) { + } else { if (EXTERNAL_SSE4(cpu_flags)) { s->threshold = ff_threshold16_sse4; }