[FFmpeg-devel] [PATCH] Compile libswscale without MMX, MMX2 and 3DNOW code

Michael Niedermayer michaelni
Sun Jun 10 11:57:52 CEST 2007


Hi

On Sun, Jun 10, 2007 at 09:50:15AM +0100, M?ns Rullg?rd wrote:
> Michael Niedermayer <michaelni at gmx.at> writes:
> 
> > Hi
> >
> > On Sun, Jun 10, 2007 at 12:48:46AM +0200, Carl Eugen Hoyos wrote:
> >> Hi!
> >> 
> >> Currently, libswscale is always compiled with MMX, MMX2 and 3DNOW
> >> support, even when they where deactivated during configure.
> >> 
> >> Attached patch tries to fix this by using COMPILE_MMX etc. as does
> >> libpostproc.
> >> 
> >> Please comment, Carl Eugen
> >
> > if we do want COMPILE_* defines they should mabybe be set at a more central
> 
> What's wrong with HAVE_MMX and friends?  They are set by configure if
> the toolchain can build mmx code.

the problem is code like


#define HAVE_MMX
#undef HAVE_MMX2
...
#include "foobar_template.h"

#define HAVE_MMX
#define HAVE_MMX2
...
#include "foobar_template.h"

this cant be just put under #ifdef HAVE_MMX2 ...
and we have more than 1 place with such code IIRC so the
#ifdef HAVE_MMX
#define CAN_COMPILE_MMX
#endif
style code would be duplicated
-> one solution (likely not the only one) and possibly not the best
would be to put the CAN_COMPILE_MMX or equivalent into its own header or
configure

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Those who are too smart to engage in politics are punished by being
governed by those who are dumber. -- Plato 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20070610/b7c60ff0/attachment.pgp>



More information about the ffmpeg-devel mailing list