summaryrefslogtreecommitdiff
path: root/configure
diff options
context:
space:
mode:
authorRong Yan <rongyan236@gmail.com>2014-06-18 04:51:35 -0400
committerMichael Niedermayer <michaelni@gmx.at>2014-06-19 01:01:14 +0200
commitab12373956e92b865bced9b05b12971f062cfd3e (patch)
tree14f7a30a31dbe7fda32ca36cf280655323597009 /configure
parent8e2ade43f1d0d093f0a4280db7521ba952cc0b96 (diff)
ppc: Fix the bug of fft for little endian environment on POWER7 and later
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure15
1 files changed, 14 insertions, 1 deletions
diff --git a/configure b/configure
index d1eb8da92e..75740f976a 100755
--- a/configure
+++ b/configure
@@ -1548,6 +1548,7 @@ ARCH_EXT_LIST_PPC="
dcbzl
ldbrx
ppc4xx
+ vsx
"
ARCH_EXT_LIST_X86="
@@ -1933,6 +1934,7 @@ mipsdspr2_deps="mips"
altivec_deps="ppc"
ppc4xx_deps="ppc"
+vsx_deps="ppc"
cpunop_deps="i686"
x86_64_select="i686"
@@ -3691,6 +3693,7 @@ elif enabled mips; then
elif enabled ppc; then
disable ldbrx
+ disable vsx
case $(tolower $cpu) in
601|ppc601|powerpc601)
@@ -3718,7 +3721,7 @@ elif enabled ppc; then
g5|970|ppc970|powerpc970)
cpuflags="-mcpu=970"
;;
- power[3-7]*)
+ power[3-8]*)
cpuflags="-mcpu=$cpu"
;;
cell)
@@ -4286,6 +4289,12 @@ unsigned int endian = 'B' << 24 | 'I' << 16 | 'G' << 8 | 'E';
EOF
od -t x1 $TMPO | grep -q '42 *49 *47 *45' && enable bigendian
+if [ "$cpu" = "power7" ] || [ "$cpu" = "power8" ] ;then
+ if ! enabled bigendian ;then
+ enable vsx
+ fi
+fi
+
if enabled asm; then
enabled arm && nogas=die
@@ -4415,6 +4424,9 @@ EOF
enabled altivec || warn "Altivec disabled, possibly missing --cpu flag"
fi
+ if enabled vsx; then
+ check_cflags -mvsx
+ fi
elif enabled x86; then
check_builtin rdtsc intrin.h "__rdtsc()"
@@ -5256,6 +5268,7 @@ fi
if enabled ppc; then
echo "AltiVec enabled ${altivec-no}"
echo "PPC 4xx optimizations ${ppc4xx-no}"
+ echo "PPC VSX optimizations ${vsx-no}"
echo "dcbzl available ${dcbzl-no}"
fi
echo "debug symbols ${debug-no}"