[Ffmpeg-devel] DECLARE_ALIGNED_16 not honoured correctly in MinGW

Christophe Mutricy xtophe
Fri Oct 27 17:10:53 CEST 2006

Le ven 27 oct 06 ? 14:54 +0200, Steve Lhomme a ?crit :
> Hi,
> We are encountering a crash when calling DrFFMPEG from DrDivX on 
> Windows. The crash occurs when decoding WMA content. After some 
> investigation it appears that this declaration in wmadec.c doesn't 
> produce what it's supposed to do:
> DECLARE_ALIGNED_16(FFTSample, output[BLOCK_MAX_SIZE * 2]);
> When the DLL (could be libavcodec) is called from MSVC code 'output' is 
> not aligned to 16 bits (0x01F36D28 in this case for example). And it 
> crashes the SSE code used later. But it works fine when everything is 
> built with MinGW. It appears that gcc assumes the stack is already 
> aligned a certain way when it does the alignment of this variable in the 
> stack. And this is not true when the stack is given by MSVC code.

I can confirm this also.

However i have this problem with mingw 3.4.5.

Here's the ticket in VLC's Trac http://trac.videolan.org/vlc/ticket/757


More information about the ffmpeg-devel mailing list