Author: cehoyos Date: Sat Nov 5 14:47:51 2011 New Revision: 34302 Log: Define HAVE_YASM etc. not only for x86. Modified: trunk/configure Modified: trunk/configure ============================================================================== --- trunk/configure Fri Nov 4 16:22:51 2011 (r34301) +++ trunk/configure Sat Nov 5 14:47:51 2011 (r34302) @@ -2761,15 +2761,6 @@ if test "$_yasm" ; then yasm_check || die "yasm not found, use --yasm='' if you really want to compile without" fi fi -if test $_yasm ; then - def_yasm='#define HAVE_YASM 1' - have_yasm="yes" - echores "$_yasm" -else - def_yasm='#define HAVE_YASM 0' - have_yasm="no" - echores "no" -fi echocheck "bswap" echo 'bswap %eax' > $TMPS @@ -2783,8 +2774,19 @@ inline_asm_check '"":::"%xmm0"' && xmm_clobbers=yes || xmm_clobbers=no echores "$xmm_clobbers" +else + _yasm='' fi #if x86 +if test $_yasm ; then + def_yasm='#define HAVE_YASM 1' + have_yasm="yes" + echores "$_yasm" +else + def_yasm='#define HAVE_YASM 0' + have_yasm="no" + echores "no" +fi #FIXME: This should happen before the check for CFLAGS.. def_altivec_h='#define HAVE_ALTIVEC_H 0'
On Sat, Nov 05, 2011 at 02:47:51PM +0100, cehoyos wrote:
Log: Define HAVE_YASM etc. not only for x86.
... and this you did - why? YASM is x86-only. Diego
On Mon, Nov 07, 2011 at 07:29:53PM +0100, Diego Biurrun wrote:
On Sat, Nov 05, 2011 at 02:47:51PM +0100, cehoyos wrote:
Log: Define HAVE_YASM etc. not only for x86.
... and this you did - why? YASM is x86-only.
Because it is valid to use if (HAVE_YASM) some_init(); in non-x86 code (we use that kind of thing in other places to avoid an #if). In that specific case the file is diracdsp.c And now I'd like to add that please think twice before committing something with a one-line commit message. Because that most likely means you forgot to mention something that would have made it a lot easier to understand _why_ you are doing the change - this one really is not obvious.
On Mon, Nov 07, 2011 at 07:41:36PM +0100, Reimar Döffinger wrote:
On Mon, Nov 07, 2011 at 07:29:53PM +0100, Diego Biurrun wrote:
On Sat, Nov 05, 2011 at 02:47:51PM +0100, cehoyos wrote:
Log: Define HAVE_YASM etc. not only for x86.
... and this you did - why? YASM is x86-only.
Because it is valid to use if (HAVE_YASM) some_init(); in non-x86 code (we use that kind of thing in other places to avoid an #if). In that specific case the file is diracdsp.c
Wrong - the C code should not have to care how arch-specific optimizations are implemented beyond calling the right init under ARCH_FOO.
And now I'd like to add that please think twice before committing something with a one-line commit message. Because that most likely means you forgot to mention something that would have made it a lot easier to understand _why_ you are doing the change - this one really is not obvious.
+1 Diego
participants (3)
-
cehoyos -
Diego Biurrun -
Reimar Döffinger