[FFmpeg-cvslog] r9848 - trunk/libavcodec/ac3dec.c
Uoti Urpala
uoti.urpala
Wed Aug 1 16:57:19 CEST 2007
On Wed, 2007-08-01 at 16:35 +0200, Benjamin Larsson wrote:
> Uoti Urpala skrev:
> > On Wed, 2007-08-01 at 07:39 +0200, Benjamin Larsson wrote:
> >> This wont work on win32/beos with regular gcc's. Please use an array
> >> allocated in the AC3DecodeContext.
> >
> > What do you mean by "with regular gccs"? And why would it fail? I don't
> > see anything special about this case - if you're talking about the same
> > "other code misaligns stack and no forced realign was used" or "old
> > buggy gcc version was used" issues then those already occur elsewhere in
> > the code.
> DECLARE_ALIGNED doesn't work on win32 on stack variables.
> I guess that falls into the old buggy gcc version was used case.
Your statements are contradictory. Old pre-4 gcc versions ignore
alignment of stack variables, but there is nothing win32-specific about
that. Are you using a gcc version older than 4? And as I said that
affects other code anyway so it's not a reason to change this code.
The win32-specific problem (which could occur elsewhere but in practice
is an issue mostly on win32) occurs when the FFmpeg library is called
from a program that misaligns the stack. If the exported functions in
FFmpeg were marked (as has been discussed before in the context of
shared library ABI improvements) then the attribute to add forced stack
realignment code to them could be set on win32 under gcc 4.2 and later.
They probably aren't called so often that it would have a significant
performance penalty (are there any FFmpeg functions that could both be
called from outside and which FFmpeg itself calls so often that the
overhead would matter?).
More information about the ffmpeg-cvslog
mailing list