fate-extra / libyuv

Automatically exported from code.google.com/p/libyuv
BSD 3-Clause "New" or "Revised" License
1 stars 0 forks source link

linux build error on AVX code #367

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
On ubuntu Precise there are build errors:

With gcc

fbarchard@g36:/usr/local/google/libyuv/trunk$ CC=clang++  make -j7 V=1 -f 
linux.mk
g++ -c -O2 -fomit-frame-pointer -Iinclude/ source/row_posix.cc -o 
source/row_posix.o
source/row_posix.cc: In function â?~void libyuv::CopyRow_AVX(const uint8*, 
uint8*, int)â?T:
source/row_posix.cc:3290:4: error: unknown register name â?~ymm1â?T in 
â?~asmâ?T
source/row_posix.cc:3290:4: error: unknown register name â?~ymm0â?T in 
â?~asmâ?T
make: *** [source/row_posix.o] Error 1

and clang
fbarchard@g36:/usr/local/google/libyuv/trunk$ CXX=clang++  make -j7 V=1 -f 
linux.mk
clang++ -c -O2 -fomit-frame-pointer -Iinclude/ source/row_posix.cc -o 
source/row_posix.o
source/row_posix.cc:3288:7: error: unknown register name 'ymm0' in asm
    , "ymm0", "ymm1"
      ^
1 error generated.
make: *** [source/row_posix.o] Error 1
fbarchard@g36:/usr/local/google/libyuv/trunk$ clang++ --version
Ubuntu clang version 3.0-6ubuntu3 (tags/RELEASE_30/final) (based on LLVM 3.0)
Target: x86_64-pc-linux-gnu

Original issue reported on code.google.com by fbarch...@google.com on 2 Oct 2014 at 8:43

GoogleCodeExporter commented 9 years ago
Fixed in r1105

But unittests fail on linux.
[ RUN      ] libyuvTest.I422ToI420_Any
/usr/local/google/home/fbarchard/bin/runyuv: line 3: 28260 Segmentation fault   
   (core dumped) out/Release/libyuv_unittest --gtest_filter=*$*

Original comment by fbarch...@google.com on 2 Oct 2014 at 8:57

GoogleCodeExporter commented 9 years ago
make -j7 V=1 -f linux.mk CXX=clang++
has link error:
a - source/video_common.o
clang++ -O2 -fomit-frame-pointer -Iinclude/ -Iutil/ -o convert util/convert.cc 
libyuv.a
libyuv.a(convert.o): In function `X420ToI420':
convert.cc:(.text+0x2dd): undefined reference to `CopyRow_AVX'
libyuv.a(convert.o): In function `Q420ToI420':
convert.cc:(.text+0xf15): undefined reference to `CopyRow_AVX'
libyuv.a(planar_functions.o): In function `CopyPlane':
planar_functions.cc:(.text+0x51d): undefined reference to `CopyRow_AVX'
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [convert] Error 1
fbarchard@g36:/usr/local/google/libyuv/trunk$ make -j7 V=1 -f linux.mk 
CXX=clang++

Original comment by fbarch...@google.com on 2 Oct 2014 at 10:45

GoogleCodeExporter commented 9 years ago
[ RUN      ] libyuvTest.I444ToI420_Unaligned
/usr/local/google/home/fbarchard/bin/runyuv: line 3: 14899 Segmentation fault   
   (core dumped) out/Release/libyuv_unittest --gtest_filter=*$*
fbarchard@g36:/usr/local/google/libyuv/trunk$

Original comment by fbarch...@google.com on 2 Oct 2014 at 11:51

GoogleCodeExporter commented 9 years ago
Fixed in r1108.
All tests build and pass.

Original comment by fbarch...@google.com on 3 Oct 2014 at 6:04