[FFmpeg-devel] [PATCH 1/3] aarch64: vp9mc: Load only 12 pixels in the 4 pixel wide horizontal filter
Martin Storsjö
martin at martin.st
Thu Dec 26 00:34:27 EET 2024
On Thu, 19 Dec 2024, Janne Grunau wrote:
> This reduces the amount the horizontal filters read beyond the filter
> width to a consistent 1 pixel. The data is not used so this is usually
> not noticeable. It becomes a problem when the application allocates
> frame buffers only for the aligned picture size and the end of it is at
> a page boundary. This happens for picture sizes which are a multiple of
> the page size like 1280x640. The frame buffer allocation is based on
> its most likely done via mmap + MAP_ANONYMOUS so start and end of the
> buffer are page aligned and the previous and next page are not
> necessarily mapped.
> Under these conditions like seen by Firefox a read beyond the end of the
> buffer results in a segfault.
> After the over-read is reduced to a single pixel it's reasonable to use
> VP9's emulated edge motion compensation for this.
>
> Fixes: https://bugzilla.mozilla.org/show_bug.cgi?id=1881185
> Signed-off-by: Janne Grunau <janne-ffmpeg at jannau.net>
> ---
> libavcodec/aarch64/vp9mc_neon.S | 10 +++++++++-
> 1 file changed, 9 insertions(+), 1 deletion(-)
Thanks; the assembly changes here and in 2/3 are ok with me; I have no
opinion on how 3/3 is one though. Do you still have push access (once 3/3
is sorted out with Ronald), or do you need someone to push the patches for
you at that point?
I guess these fixes should be backported to all maintained releases too,
once we've settled on the final form of the fix.
// Martin
More information about the ffmpeg-devel
mailing list