From: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> To: ffmpeg-devel@ffmpeg.org Cc: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> Subject: [FFmpeg-devel] [PATCH] avutil/x86/emms: Don't unnecessarily include lavu/cpu.h Date: Mon, 14 Feb 2022 19:41:44 +0100 Message-ID: <PR3PR03MB6665D6B3862F43ABB2A9B0158F339@PR3PR03MB6665.eurprd03.prod.outlook.com> (raw) Only include it if it is needed, namely if __MMX__ is undefined. X86 is currently the only arch where lavu/cpu.h is basically automatically included (for internal development): #if ARCH_X86 is true, lavu/internal.h (which is basically included everywhere) includes lavu/x86/emms.h which can mask missing inclusions of lavu/cpu.h if the developer works on x86/x64. This has happened in 8e825ec3ab09d877f12dcf05d76902a8bb9c8b11 and also earlier (see 6d2365882f281f9452b31b91edb2e6a2d4f5ff08). By including said header only if necessary ordinary developer machines will behave like non-x86 arches, so that missing inclusions of cpu.h won't go unnoticed any more. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> --- libavutil/x86/emms.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libavutil/x86/emms.h b/libavutil/x86/emms.h index c21e34b451..8ceec110cf 100644 --- a/libavutil/x86/emms.h +++ b/libavutil/x86/emms.h @@ -21,11 +21,14 @@ #include "config.h" #include "libavutil/attributes.h" -#include "libavutil/cpu.h" void avpriv_emms_asm(void); #if HAVE_MMX_INLINE +#ifndef __MMX__ +#include "libavutil/cpu.h" +#endif + # define emms_c emms_c /** * Empty mmx state. -- 2.32.0 _______________________________________________ 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".
next reply other threads:[~2022-02-14 18:42 UTC|newest] Thread overview: 36+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-02-14 18:41 Andreas Rheinhardt [this message] 2022-02-15 17:42 ` [FFmpeg-devel] [PATCH 02/19] avdevice/decklink_(common_c|dec|enc).h: Fix checkheaders Andreas Rheinhardt 2022-02-15 17:42 ` [FFmpeg-devel] [PATCH 03/19] avcodec/cabac_functions: Add missing headers Andreas Rheinhardt 2022-02-15 17:42 ` [FFmpeg-devel] [PATCH 04/19] avcodec/aarch64/idct: Add missing stddef Andreas Rheinhardt 2022-02-15 17:42 ` [FFmpeg-devel] [PATCH 05/19] avcodec/mips: Fix checkheaders Andreas Rheinhardt 2022-02-15 17:42 ` [FFmpeg-devel] [PATCH 06/19] avformat/avio: Don't include common.h Andreas Rheinhardt 2022-02-23 14:46 ` Martin Storsjö 2022-02-23 16:07 ` Andreas Rheinhardt 2022-02-15 17:42 ` [FFmpeg-devel] [PATCH 07/19] avutil/log: Don't include avutil.h Andreas Rheinhardt 2022-02-23 14:47 ` Martin Storsjö 2022-02-15 17:42 ` [FFmpeg-devel] [PATCH 08/19] avutil/audio_fifo: Avoid avutil.h inclusion Andreas Rheinhardt 2022-02-23 14:48 ` Martin Storsjö 2022-02-15 17:42 ` [FFmpeg-devel] [PATCH 09/19] avutil/fifo: Don't include avutil.h Andreas Rheinhardt 2022-02-23 14:49 ` Martin Storsjö 2022-02-15 17:42 ` [FFmpeg-devel] [PATCH 10/19] avutil/file: " Andreas Rheinhardt 2022-02-23 14:49 ` Martin Storsjö 2022-02-15 17:42 ` [FFmpeg-devel] [PATCH 11/19] avutil/eval: " Andreas Rheinhardt 2022-02-23 14:50 ` Martin Storsjö 2022-02-15 17:43 ` [FFmpeg-devel] [PATCH 12/19] avutil/imgutils: " Andreas Rheinhardt 2022-02-23 14:50 ` Martin Storsjö 2022-02-15 17:43 ` [FFmpeg-devel] [PATCH 13/19] avutil/samplefmt: Don't include attributes.h, avutil.h Andreas Rheinhardt 2022-02-23 14:51 ` Martin Storsjö 2022-02-15 17:43 ` [FFmpeg-devel] [PATCH 14/19] avutil/pixelutils: Don't include common.h Andreas Rheinhardt 2022-02-23 14:51 ` Martin Storsjö 2022-02-15 17:43 ` [FFmpeg-devel] [PATCH 15/19] avutil/integer: " Andreas Rheinhardt 2022-02-23 14:51 ` Martin Storsjö 2022-02-15 17:43 ` [FFmpeg-devel] [PATCH 16/19] avutil/display: Don't include avutil.h Andreas Rheinhardt 2022-02-23 14:52 ` Martin Storsjö 2022-02-15 17:43 ` [FFmpeg-devel] [PATCH 17/19] Remove obsolete version.h inclusions Andreas Rheinhardt 2022-02-23 14:54 ` Martin Storsjö 2022-02-23 15:15 ` Andreas Rheinhardt 2022-02-23 19:44 ` Martin Storsjö 2022-02-15 17:43 ` [FFmpeg-devel] [PATCH 18/19] avutil/avassert: Don't include avutil.h Andreas Rheinhardt 2022-02-23 14:58 ` Martin Storsjö 2022-02-15 17:43 ` [FFmpeg-devel] [PATCH 19/19] Remove unnecessary libavutil/(avutil|common|internal).h inclusions Andreas Rheinhardt 2022-02-23 15:02 ` Martin Storsjö
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=PR3PR03MB6665D6B3862F43ABB2A9B0158F339@PR3PR03MB6665.eurprd03.prod.outlook.com \ --to=andreas.rheinhardt@outlook.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