[Ffmpeg-devel] SSE2 Crashing

Gianluigi Tiesi mplayer
Fri Aug 18 01:35:40 CEST 2006


On Wed, Aug 16, 2006 at 10:13:58PM -0500, Brian Brice wrote:
> Hi!
> I'm not sure if this is the right place to bring this up, but maybe
> others have experience with this issue.  I've compiled ffmpeg with
> gcc-3.4.5/ld-2.16-91 in mingw.  It seems to work correctly in the
> ffmpeg program, but when I use the libraries with something else,
> then I experience crashes involving SSE2 instructions.  The crashes
> were occurring in lavc/i386/fdct_mmx.c, fdct_row_sse2.  I do have
> SSE and the memalign hack enabled.  The function that calls
> fdct_row_sse2 is ff_fdct_sse2 allocates a buffer that is aligned
> to to an 8 byte boundary.  I've watched the allocation of this
> buffer and it seems to not actually be aligned correctly.  Is this
> a problem with my version of gcc?  Anyone else experience this and
> figure out a way around it?  Thanks.
> 
iirc sse code needs to be aligned to 16 byte, av_malloc always
aligns to 16 bytes by using memalign or memalign hack,
look if the code uses av_malloc to alloc memory in this case
something is wrong in the memalign hack.

My builds of mplayer have sse enabled and I got no bad feedbacks
so far, I'm using gcc 4.1.1 and ld 2.17
if you want to use my versions they are here:
http://oss.netfarm.it/mplayer-win32.php

you need to make a copy of gcc e g++ executables,
from gcc-4.1 and g++-4.1 ones, also remove libiberty from /lib
I've made this to be able to use different compilers at the same time,
a bit inspired by debian gcc packages :)

Bye

-- 
Gianluigi Tiesi <sherpya at netfarm.it>
EDP Project Leader
Netfarm S.r.l. - http://www.netfarm.it/
Free Software: http://oss.netfarm.it/




More information about the ffmpeg-devel mailing list