Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
From: James Almer <jamrial@gmail.com>
To: ffmpeg-devel@ffmpeg.org
Subject: Re: [FFmpeg-devel] [PATCH] x86/tx_float: do not build tx_float_init.c if x86 assembly is disabled
Date: Wed, 26 Jan 2022 19:50:27 -0300
Message-ID: <fbf4c44e-63e3-d16c-7883-e28db0da7648@gmail.com> (raw)
In-Reply-To: <MuNYwVw--3-2@lynne.ee>



On 1/26/2022 7:44 PM, Lynne wrote:
> This broke builds with --disable-mmx, which also disabled assembly
> entirely, but ARCH_X86 was still true, so the init file tried to find
> assembly that didn't exist.
> Instead of checking for architecture, check if x86 assembly is enabled.
> 
> Patch attached.


> From 97e91aea87876a542a0f075e7093708f38f38a8c Mon Sep 17 00:00:00 2001
> From: Lynne <dev@lynne.ee>
> Date: Wed, 26 Jan 2022 23:40:35 +0100
> Subject: [PATCH] x86/tx_float: do not build tx_float_init.c if x86 assembly is
>  disabled
> 
> This broke builds with --disable-mmx, which also disabled assembly
> entirely, but ARCH_X86 was still true, so the init file tried to find
> assembly that didn't exist.
> Instead of checking for architecture, check if x86 assembly is enabled.
> ---
>  libavutil/tx.c         | 2 +-
>  libavutil/x86/Makefile | 3 ++-
>  2 files changed, 3 insertions(+), 2 deletions(-)
> 
> diff --git a/libavutil/tx.c b/libavutil/tx.c
> index cac7815231..5c1ac20c92 100644
> --- a/libavutil/tx.c
> +++ b/libavutil/tx.c
> @@ -439,7 +439,7 @@ av_cold int ff_tx_init_subtx(AVTXContext *s, enum AVTXType type,
>          ff_tx_codelet_list_double_c,
>          ff_tx_codelet_list_int32_c,
>          ff_tx_null_list,
> -#if ARCH_X86
> +#if HAVE_X86ASM
>          ff_tx_codelet_list_float_x86,
>  #endif
>      };
> diff --git a/libavutil/x86/Makefile b/libavutil/x86/Makefile
> index d747c37049..d66839e35d 100644
> --- a/libavutil/x86/Makefile
> +++ b/libavutil/x86/Makefile
> @@ -3,7 +3,8 @@ OBJS += x86/cpu.o                                                       \
>          x86/float_dsp_init.o                                            \
>          x86/imgutils_init.o                                             \
>          x86/lls_init.o                                                  \
> -        x86/tx_float_init.o                                             \
> +
> +OBJS-$(HAVE_X86ASM) += x86/tx_float_init.o                              \

This is not how we normally handle things. Init files for a given target 
arch should compile regardless of what is enabled at configure time. DCE 
with all the EXTERNAL_ checks should take care of not referencing 
symbols that nasm will not assemble.

>  
>  OBJS-$(CONFIG_PIXELUTILS) += x86/pixelutils_init.o                      \
>  
> -- 
> 2.34.1
> 
_______________________________________________
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".

      reply	other threads:[~2022-01-26 22:50 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-26 22:44 Lynne
2022-01-26 22:50 ` James Almer [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=fbf4c44e-63e3-d16c-7883-e28db0da7648@gmail.com \
    --to=jamrial@gmail.com \
    --cc=ffmpeg-devel@ffmpeg.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
		ffmpegdev@gitmailbox.com
	public-inbox-index ffmpegdev

Example config snippet for mirrors.


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git