[MPlayer-dev-eng] [PATCH] compilers "optimizing" pe_image too much

Reimar Döffinger Reimar.Doeffinger at stud.uni-karlsruhe.de
Tue Sep 14 00:43:43 CEST 2004


Hi,
e.g. gcc 3.2.2 inlines extend_stack_for_dll_alloca which breaks the code 
because of the alloca (which causes occasional segfaults in the dlls). 
Although this is clearly a compiler bug, I suggest the attached patch 
(actually the noinline attribute). I'm usually against working around 
other projects' bugs, but this one is hard to find and debug...
In addition I suggest declaring the mem variable volatile to indicate to 
the compiler not to optimize this away (although it seems it isn't 
exactly specified what volatile is supposed to do...).

Greetings,
Reimar Döffinger
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: pe_loader.diff
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20040914/90afbe71/attachment.txt>


More information about the MPlayer-dev-eng mailing list