Opened 4 months ago

Closed 5 weeks ago

#6571 closed defect (fixed)

SIGBUS on ARM in h264idct_neon.S when compiled with binutils 2.29

Reported by: jcowgill Owned by:
Priority: normal Component: avcodec
Version: git-master Keywords: h264 arm
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Summary of the bug:
Binutils 2.29 changes the behavior of the ADR instruction when loading Thumb functions. This causes some of the optimizations to crash.

See:
https://bugs.debian.org/870622
https://sourceware.org/bugzilla/show_bug.cgi?id=21458

There is a suggestion on how to fix this in message 25 in the Debian bug report, while still allowing the code to work with old and new binutils. I don't know ARM assembly very well so I don't know how well it works. It looks reasonably sensible however.

How to reproduce:
Build ffmpeg 3.3.3 on ARMv7 using binutils 2.29

Run:

$ ffmpeg -f lavfi -i testsrc=s=32x32:d=0.1 -strict -2 -c:v libx264rgb -f avi libx264rgb.avi -y -hide_banner -nostdin
$ ffmpeg -strict -2 -i libx264rgb.avi -t 1 -c:v rawvideo -c:a pcm_s32le -f nut /dev/null -y -hide_banner -nostdin

The second command will crash with SIGBUS.

Change History (2)

comment:1 Changed 4 months ago by cehoyos

  • Keywords h264 arm added
  • Version changed from unspecified to git-master

Did you send the patch to the FFmpeg development mailing list?

Regarding sparc64: I can reproduce the build failure of libavcodec/vp9dsp_12bpp.o with gcc-7 and toolchain=hardened, but not with gcc-6 and not without -fstack-protector-all so I suspect another gcc-7 bug.

comment:2 Changed 5 weeks ago by cehoyos

  • Resolution set to fixed
  • Status changed from new to closed

Fixed since 640073ecebc46040f966fe3b52c10f3c5b11d66f, sorry about this: Reviews are still less important than merges.

Note: See TracTickets for help on using tickets.