[FFmpeg-trac] #4148(avcodec:open): Crash in ff_add_bytes_l2_sse2 when decoding attached APNG file
FFmpeg
trac at avcodec.org
Tue Dec 2 11:52:42 CET 2014
#4148: Crash in ff_add_bytes_l2_sse2 when decoding attached APNG file
-------------------------------------+-------------------------------------
Reporter: benoit | Owner:
Type: defect | Status: open
Priority: important | Component: avcodec
Version: git-master | Resolution:
Keywords: png crash | Blocked By:
SIGSEGV regression | Reproduced by developer: 1
Blocking: |
Analyzed by developer: 0 |
-------------------------------------+-------------------------------------
Comment (by kurosu):
Crap, my comment was not posted, so I'll make it briefer:
0) Are you sure src1 is always aligned? I think not
1) Can the caller be fixed to use aligned addresses without copying around
data? If yes, that should be done to have as few unaligned loads as
possible
2) Speed generally matters, so deciding in case of unaligned addresses to
use the slow, scalar version depends on how often and how large the areas
it applies to are
3) If speed matters, a SIMD handling unaligned addresses should be used
4) Compare its speed to the aligned version for aligned addresses. Larger
areas, older PCs should show larger differences.
5) If the speed difference is large enough, add a branch for unaligned
addresses, otherwise just replace the aligned code
6) If you're right about src1:
{{{
test dstq, 15
jnz .handle_unaligned
}}}
If you're not:
{{{
mov iq, dstq
or iq, src1q
test iq, 15
jnz .handle_unaligned
}}}
then xor iq on each path.
--
Ticket URL: <https://trac.ffmpeg.org/ticket/4148#comment:6>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker
More information about the FFmpeg-trac
mailing list