[MPlayer-dev-eng] [PATCH] demux_mkv.c: fix crash with gcc 4.4 and optimizations

Andrew Savchenko bircoph at gmail.com
Wed Sep 30 12:00:18 CEST 2009


Hi,

On Wednesday 30 September 2009, Ivan Kalvachev wrote:
> On 9/30/09, Corey Hickey <bugfood-ml at fatooh.org> wrote:
> > Hello,
> >
> > The MKV demuxer segfaults when compiled with gcc 4.4.
>
> gcc 4.4.0 and 4.4.1 are known to produce bad code.
> I guess we must add them to the configure list of buggy
> compilers.
>
> Some of the problems may be related to -O4 level,
> if somebody is eager to mess with that stuff.

For gcc-4.4 the problem is in alignment of SSE code. Usually it is 
triggered by -ftree-vectorize which is part of -O3 (-O4 and higher 
in gcc have the same meaning as -O3 for now).
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40838

I fixed this by using my own CFLAGS/CXXFLAGS. And I got nice 
surprise: performance increased by 2..8% depending on test. Of 
course, options are hardware dependent, so may not be so easy 
reproducible.

-- 
Best regards,
Andrew
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20090930/3ffe22e5/attachment.pgp>


More information about the MPlayer-dev-eng mailing list