1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-28 20:53:54 +02:00
Go to file
Andreas Rheinhardt 894191e7e1 avcodec/svq1enc: Workaround GCC bug 102513
GCC 11 has a bug: When it creates clones of recursive functions
(to inline some parameters), it clones a recursive function
eight times by default, even when this exceeds the recursion
depth. This happens with encode_block() in libavcodec/svq1enc.c
where a parameter level is always in the range 0..5;
but GCC 11 also creates functions corresponding to level UINT_MAX
and UINT_MAX - 1 (on -O3; -O2 is fine).

Using such levels would produce undefined behaviour and because
of this GCC emits bogus -Warray-bounds warnings for these clones.

Since commit d08b2900a9, certain
symbols that are accessed like ff_svq1_inter_multistage_vlc[level]
are declared with hidden visibility, which allows compilers
to bake the offset implied by level into the instructions
if level is a compile-time constant as it is in the clones.
Yet this leads to insane offsets for level == UINT_MAX which
can be incompatible with the supported offset ranges of relocations.
This happens in the small code model (the default code model for
AArch64).

This commit therefore works around this bug by disabling cloning
recursive functions for GCC 10 and 11. GCC 10 is affected by the
underlying bug (see
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102513), so the workaround
also targets it, although it only produces three versions of
encode_block(), so it does not seem to trigger the actual issue here.

The issue has been mitigated in GCC 12.1 (it no longer creates clones
for impossible values; see also commit
1cb7fd317c), so the workaround
does not target it.

Reported-by: J. Dekker <jdek@itanimul.li>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Signed-off-by: J. Dekker <jdek@itanimul.li>
2022-10-25 14:55:51 +02:00
compat
doc doc/encoders: Add doc for av1_qsv 2022-10-24 13:30:22 +08:00
ffbuild configure: probe RISC-V Vector extension 2022-09-27 13:19:52 +02:00
fftools fftools/ffmpeg_demux: stop modifying OptionsContext 2022-10-25 11:13:03 +02:00
libavcodec avcodec/svq1enc: Workaround GCC bug 102513 2022-10-25 14:55:51 +02:00
libavdevice avdevice/avdevice: Fix mismatching argument name 2022-10-17 09:51:47 +02:00
libavfilter avfilter/vf_curves: add PCHIP interpolator and interp option 2022-10-22 19:35:44 +02:00
libavformat lavf: set internal thread names 2022-10-24 02:00:31 +02:00
libavutil avutil/integer: Use '|' instead of '+' where it is more natural 2022-10-24 20:11:20 +02:00
libpostproc
libswresample swresample: Fix Doxy reference to AVOptions 2022-10-17 09:55:19 +02:00
libswscale swscale: document some missing arguments 2022-10-17 09:56:47 +02:00
presets
tests ffmpeg: Add display_{rotation, hflip, vflip} options 2022-10-19 11:53:52 +02:00
tools tools/target_dec_fuzzer: Adjust threshold for FFV1 2022-10-20 21:42:21 +02:00
.gitattributes
.gitignore
.mailmap
.travis.yml
Changelog avcodec: ViewQuest VQC decoder 2022-10-18 13:20:37 +11:00
configure libavcodec/qsvenc_av1: add av1_qsv encoder 2022-10-24 13:30:22 +08:00
CONTRIBUTING.md
COPYING.GPLv2
COPYING.GPLv3
COPYING.LGPLv2.1
COPYING.LGPLv3
CREDITS
INSTALL.md
LICENSE.md
MAINTAINERS
Makefile configure: probe RISC-V Vector extension 2022-09-27 13:19:52 +02:00
README.md
RELEASE

FFmpeg README

FFmpeg is a collection of libraries and tools to process multimedia content such as audio, video, subtitles and related metadata.

Libraries

  • libavcodec provides implementation of a wider range of codecs.
  • libavformat implements streaming protocols, container formats and basic I/O access.
  • libavutil includes hashers, decompressors and miscellaneous utility functions.
  • libavfilter provides means to alter decoded audio and video through a directed graph of connected filters.
  • libavdevice provides an abstraction to access capture and playback devices.
  • libswresample implements audio mixing and resampling routines.
  • libswscale implements color conversion and scaling routines.

Tools

  • ffmpeg is a command line toolbox to manipulate, convert and stream multimedia content.
  • ffplay is a minimalistic multimedia player.
  • ffprobe is a simple analysis tool to inspect multimedia content.
  • Additional small tools such as aviocat, ismindex and qt-faststart.

Documentation

The offline documentation is available in the doc/ directory.

The online documentation is available in the main website and in the wiki.

Examples

Coding examples are available in the doc/examples directory.

License

FFmpeg codebase is mainly LGPL-licensed with optional components licensed under GPL. Please refer to the LICENSE file for detailed information.

Contributing

Patches should be submitted to the ffmpeg-devel mailing list using git format-patch or git send-email. Github pull requests should be avoided because they are not part of our review process and will be ignored.