[Ffmpeg-devel] Stack alignment warning

Ivan Kalvachev ikalvachev
Fri Dec 15 21:05:34 CET 2006


2006/12/15, Ismail Donmez <ismail at pardus.org.tr>:
> Hi all,
>
> I get the following warning on Linux with gcc 3.4.6 :
>
> Compiler did not align stack variables. Libavcodec has been miscompiled
> and may be very slow or crash. This is not a bug in libavcodec,
> but in the compiler. Do not report crashes to FFmpeg developers.
>
> I thought gcc on Linux did not have stack alignment problems. So whats up?

Take a look of the threads with subjects:

"[RFC][PATCH] wma with sse on windows fix"
"[Ffmpeg-devel] sse sigsegv and libavcodec/wmadec.c"

As of the moment it is know that all released gcc versions could
trigger the above warning, gcc 4.2 is expected to avoid it (support
stack aligned local arrays)

The fix for the only codec that was really affected (as segfault) was
fixed today. There is chance that the new code is about 0.3% faster (I
keep the irc logs with the benchmarks).

At the moment this warning is serving only to increase the cola debt
of michael. But I fear to remove it as he may need that cola. ;)
It may also be a clever plan to ignore all new bugreports.

Joke aside, there is a number of dsputil functions that use aligned
stack arrays. About 6-7 of them are mmx stuff. These doesn't segfault
but probably may run non-optimal.




More information about the ffmpeg-devel mailing list