From patchwork Mon Aug 12 01:14:55 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Rheinhardt X-Patchwork-Id: 14431 Return-Path: X-Original-To: patchwork@ffaux-bg.ffmpeg.org Delivered-To: patchwork@ffaux-bg.ffmpeg.org Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by ffaux.localdomain (Postfix) with ESMTP id 61F04449558 for ; Mon, 12 Aug 2019 04:22:17 +0300 (EEST) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id 41C4868AB0B; Mon, 12 Aug 2019 04:22:17 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-wr1-f66.google.com (mail-wr1-f66.google.com [209.85.221.66]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 64D4B68A89E for ; Mon, 12 Aug 2019 04:22:10 +0300 (EEST) Received: by mail-wr1-f66.google.com with SMTP id b16so6471160wrq.9 for ; Sun, 11 Aug 2019 18:22:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=iJv94occ692pnz2TeoOnMZ0o0erDrVRTKLKTcDH0o3A=; b=lH04V1RcRN50Y7H+LyNBBPH1xQuJxFMNhy2r5uuWOKzHklQugsoU4MRVzjetFpi+CT Mq0EqPBKd//2ne8IcpeFKzY/IlCPw25hURV1YmUFfDbmHDYOMYEhYnRgxGJz2I5CYbmu Z9BnAt9PCYa9uGXteiGSuGBz3/yGiZjNXv4FsbDGy7sGofnbS9BIe124RcXxdYIsuHJr itbb1+yOq+rcOwj72Xfb/kN0n43oNWm3woLXpkv2cFWaLAIIyCF487bkEIVIGhPtPu94 CCn05hjXQCuyG12XW4g2TrhBn2hmLnTm2KRARm26kqPnouSGC9T4YLOwTyZ4H8DGgX/O FVjw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=iJv94occ692pnz2TeoOnMZ0o0erDrVRTKLKTcDH0o3A=; b=gLOQoIPjIF+6iYVhurj0g1xOKUy6G1gOvXKd8gSibdZ3d9EPqk3QyxcEXd7DWP6VFQ MDMy7UXHbWvJGiBC3FYn2KkfjOoplPjSvwc/nHuwq/t8t9PIIgqgwBUnf4GxA14hZT00 T6H0r9Swe9dXTzPfGacxfBQ5R9wXlaAbC35OIjLfHydAd808pqutUzYyfwndO7ki2Lce RxP/HCLEkBItNVAjNpG6KJiH6z3nwZcod7bXyrVXCdU1HfnoC08iosSf2/uj/BgdN+jk uwP+hUYX4U7ieZaya/JRsAbRFL1KClExh3fe9vD+iMXM1rXT15829NdDLKPCM93wMkpQ nrtQ== X-Gm-Message-State: APjAAAUw9UJ5pXJzTy5LxVv0p8P6e6jb+Qeyjtwn7liDBkgedls6YIPv QM/tFilDGqoyqD4WyCyGdXHPd8w6 X-Google-Smtp-Source: APXvYqw8RvBUVEphSMbhJ7NdZFKI+XGJ7b/dgpMLUmo0KBRUUNDc+Kuonu5r4i5Z727jO1+rj4B0Sw== X-Received: by 2002:adf:dcd2:: with SMTP id x18mr100192wrm.340.1565572531406; Sun, 11 Aug 2019 18:15:31 -0700 (PDT) Received: from localhost.localdomain (ipbcc06ceb.dynamic.kabel-deutschland.de. [188.192.108.235]) by smtp.gmail.com with ESMTPSA id d207sm1728311wmd.0.2019.08.11.18.15.29 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Sun, 11 Aug 2019 18:15:30 -0700 (PDT) From: Andreas Rheinhardt To: ffmpeg-devel@ffmpeg.org Date: Mon, 12 Aug 2019 03:14:55 +0200 Message-Id: <20190812011455.57668-1-andreas.rheinhardt@gmail.com> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 Subject: [FFmpeg-devel] [PATCH] avfilter/vf_convolution: Fix build failures X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 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: Andreas Rheinhardt Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" 98e419cb added SIMD for the convolution filter for x64 systems. As usual, it used a check of the form if (ARCH_X86_64) ff_convolution_init_x86(s); and thereby relied on the compiler eliminating this pseudo-runtime check at compiletime for non x64 systems (for which ff_convolution_init_x86 isn't defined) to compile. But vf_convolution.c contains more than one filter and if the convolution filter is disabled, but one of the other filters (prewitt, sobel, roberts) is enabled, the build will fail on x64, because ff_convolution_init_x86 isn't defined in this case. Signed-off-by: Andreas Rheinhardt --- Found via ubitux2's random FATE box: http://fate.ffmpeg.org/history.cgi?slot=x86_64-archlinux-gcc-random libavfilter/vf_convolution.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/libavfilter/vf_convolution.c b/libavfilter/vf_convolution.c index e3bf1df79f..f29df38a20 100644 --- a/libavfilter/vf_convolution.c +++ b/libavfilter/vf_convolution.c @@ -588,8 +588,9 @@ static int config_input(AVFilterLink *inlink) s->filter[p] = filter16_7x7; } } - if (ARCH_X86_64) - ff_convolution_init_x86(s); +#if CONFIG_CONVOLUTION_FILTER && ARCH_X86_64 + ff_convolution_init_x86(s); +#endif } else if (!strcmp(ctx->filter->name, "prewitt")) { if (s->depth > 8) for (p = 0; p < s->nb_planes; p++)