1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00
Go to file
Mans Rullgard 90540c2d5a x86: swscale: fix fragile memory accesses
To access data at multiple fixed offsets from a base address, this
code uses a single "m" operand and code of the form "32%0", relying on
the memory operand instantiation having no displacement, giving a final
result of the form "32(%rax)".  If the compiler uses a register and
displacement, e.g. "64(%rax)", the end result becomes "3264(%rax)",
which obviously does not work.

Replacing the "m" operands with "r" operands allows safe addition of a
displacement.  In theory, multiple memory operands could use a shared
base register with different index registers, "(%rax,%rbx)", potentially
making more efficient use of registers.  In the cases at hand, no such
sharing is possible since the addresses involved are entirely unrelated.

After this change, the code somewhat rudely accesses memory without
using a corresponding memory operand, which in some cases can lead to
unwanted "optimisations" of surrounding code.  However, the original
code also accesses memory not covered by a memory operand, so this is
not adding any defect not already present.  It is also hightly unlikely
that any such optimisations could be performed here since the memory
locations in questions are not accessed elsewhere in the same functions.

This fixes crashes with suncc.

Signed-off-by: Mans Rullgard <mans@mansr.com>
2012-08-13 14:51:52 +01:00
compat dct/fft-test: use a replacement getopt() if the system has none present. 2012-07-11 21:24:37 +02:00
doc lavc: fix mixing CODEC_ID/AV_CODEC_ID in C++ code. 2012-08-10 18:48:40 +02:00
libavcodec x86: cabac: allow building with suncc 2012-08-13 14:51:52 +01:00
libavdevice Replace all CODEC_ID_* with AV_CODEC_ID_* 2012-08-07 16:00:24 +02:00
libavfilter x86: yadif: fix asm with suncc 2012-08-13 14:51:52 +01:00
libavformat lavf: Detect discontinuities in timestamps for framerate/analyzeduration calculation 2012-08-12 12:39:49 +03:00
libavresample avresample: De-doxygenize some comments where Doxygen is not appropriate 2012-08-11 20:22:01 +02:00
libavutil ARM: intmath: use native-size return types for clipping functions 2012-08-13 14:51:52 +01:00
libswscale x86: swscale: fix fragile memory accesses 2012-08-13 14:51:52 +01:00
presets presets: spelling error in libvpx 1080p50_60 2011-10-22 00:28:56 +02:00
tests fate: Only test enabled filters 2012-08-11 20:26:31 +02:00
tools Replace all CODEC_ID_* with AV_CODEC_ID_* 2012-08-07 16:00:24 +02:00
.gitignore build: change checkheaders to use regular build rules 2012-08-07 21:36:51 +01:00
arch.mak build: Consistently handle conditional compilation for all optimization OBJS. 2012-04-12 09:00:49 +02:00
avconv_filter.c avconv: split configuring filter configuration to a separate file. 2012-08-08 11:11:52 +02:00
avconv_opt.c avconv: split option parsing into a separate file. 2012-08-08 11:10:06 +02:00
avconv.c avconv: allow no input files. 2012-08-08 21:56:26 +02:00
avconv.h avconv: rename OutputStream.is_past_recording_time to finished. 2012-08-08 21:55:45 +02:00
avplay.c avplay: fix build with lavfi disabled. 2012-08-08 11:14:10 +02:00
avprobe.c Replace all CODEC_ID_* with AV_CODEC_ID_* 2012-08-07 16:00:24 +02:00
avserver.c Replace all CODEC_ID_* with AV_CODEC_ID_* 2012-08-07 16:00:24 +02:00
Changelog Canopus Lossless decoder 2012-08-01 22:06:16 -04:00
cmdutils_common_opts.h avtools: add -v as alias for -loglevel 2011-10-09 16:53:06 +01:00
cmdutils.c Replace all CODEC_ID_* with AV_CODEC_ID_* 2012-08-07 16:00:24 +02:00
cmdutils.h Replace all CODEC_ID_* with AV_CODEC_ID_* 2012-08-07 16:00:24 +02:00
common.mak build: change checkheaders to use regular build rules 2012-08-07 21:36:51 +01:00
configure configure: Rename check_asm() to more fitting check_inline_asm() 2012-08-11 20:26:31 +02:00
COPYING.GPLv2 Rename COPYING.GPL --> COPYING.GPLv2 and COPYING.LGPL --> COPYING.LGPLv2.1. 2009-06-05 09:51:31 +00:00
COPYING.GPLv3 Add configure option to upgrade (L)GPL to version 3. 2009-06-05 11:04:03 +00:00
COPYING.LGPLv2.1 cosmetics: Delete empty lines at end of file. 2012-02-09 12:26:45 +01:00
COPYING.LGPLv3 Add configure option to upgrade (L)GPL to version 3. 2009-06-05 11:04:03 +00:00
CREDITS partially rename FFmpeg to Libav 2011-03-16 21:54:39 +01:00
Doxyfile x86: build: replace mmx2 by mmxext 2012-08-03 22:51:05 +02:00
INSTALL doc: clarify configure features 2011-04-07 02:54:12 +02:00
library.mak build: Remove all installed headers and header directories on uninstall 2012-08-07 22:54:43 +02:00
LICENSE doc: Clarify licensing issues arising from external libraries 2012-08-12 13:28:58 +02:00
Makefile build: add HOSTOBJS to SUBDIR_VARS list 2012-08-09 03:49:19 +02:00
README cosmetics: fix dashed line length after 070c5d0 2011-03-28 09:53:40 +02:00
RELEASE Prepare for 0.8 Release 2012-01-21 14:54:31 +01:00
version.sh Drop git- prefix from version labels 2011-06-19 19:41:23 +01:00

Libav README
------------

1) Documentation
----------------

* Read the documentation in the doc/ directory.

2) Licensing
------------

* See the LICENSE file.