[cfe-dev] choosing the gcc toolchain

Reed Kotler rkotler at mips.com
Mon Mar 3 17:00:06 PST 2014


This native compiler was built using clang/llvm as the first stage compiler.

On 03/03/2014 04:39 PM, Reed Kotler wrote:
> On the big endian machine; which is the one we have as the build slave
> to the official llvm build bot, there is only one failure with your
> patch and it's some mips specific test in the driver.
>
>   make check-all
> llvm[0]: Running test suite
> make[1]: Entering directory `/home/rkotler/caviumllvmwclangbe/build/test'
> Making LLVM 'lit.site.cfg' file...
> Making LLVM unittest 'lit.site.cfg' file...
> make -C /home/rkotler/caviumllvmwclangbe/build/test/../tools/clang/test
> lit.site.cfg Unit/lit.site.cfg
> make[2]: Entering directory
> `/home/rkotler/caviumllvmwclangbe/build/tools/clang/test'
> Making Clang 'lit.site.cfg' file...
> Making Clang 'Unit/lit.site.cfg' file...
> make[2]: Leaving directory
> `/home/rkotler/caviumllvmwclangbe/build/tools/clang/test'
> ( ulimit -t 600 ; ulimit -d 512000 ; ulimit -m 512000 ; ulimit -s 8192 ; \
>        /usr/bin/python /home/rkotler/workspace/llvm/utils/lit/lit.py -s
> -v . /home/rkotler/caviumllvmwclangbe/build/test/../tools/clang/test )
> lit.py: lit.cfg:196: note: using clang:
> '/home/rkotler/caviumllvmwclangbe/build/Release+Asserts/bin/clang'
> FAIL: Clang :: Driver/mips-reduced-toolchain.cpp (2882 of 16898)
> ******************** TEST 'Clang :: Driver/mips-reduced-toolchain.cpp'
> FAILED ********************
> Script:
> --
> /home/rkotler/caviumllvmwclangbe/build/Release+Asserts/bin/clang
> -no-canonical-prefixes
> /home/rkotler/workspace/llvm/tools/clang/test/Driver/mips-reduced-toolchain.cpp
> -### -o
> /home/rkotler/caviumllvmwclangbe/build/tools/clang/test/Driver/Output/mips-reduced-toolchain.cpp.tmp.o
> 2>&1      --target=mips-linux-gnu
> --sysroot=/home/rkotler/workspace/llvm/tools/clang/test/Driver/Inputs/debian_reduced_mips_tree
>     | FileCheck --check-prefix=CHECK-DEBIAN-MIPS
> /home/rkotler/workspace/llvm/tools/clang/test/Driver/mips-reduced-toolchain.cpp
>
> /home/rkotler/caviumllvmwclangbe/build/Release+Asserts/bin/clang
> -no-canonical-prefixes
> /home/rkotler/workspace/llvm/tools/clang/test/Driver/mips-reduced-toolchain.cpp
> -### -o
> /home/rkotler/caviumllvmwclangbe/build/tools/clang/test/Driver/Output/mips-reduced-toolchain.cpp.tmp.o
> 2>&1      --target=mipsel-linux-gnu
> --sysroot=/home/rkotler/workspace/llvm/tools/clang/test/Driver/Inputs/debian_reduced_mips_tree
>     | FileCheck --check-prefix=CHECK-DEBIAN-MIPSEL
> /home/rkotler/workspace/llvm/tools/clang/test/Driver/mips-reduced-toolchain.cpp
>
> --
> Exit Code: 1
>
> Command Output (stderr):
> --
> /home/rkotler/workspace/llvm/tools/clang/test/Driver/mips-reduced-toolchain.cpp:9:23:
> error: expected string not found in input
> // CHECK-DEBIAN-MIPS:
> "{{.*}}/usr/lib/gcc/mips-linux-gnu/4.7{{/|\\\\}}crtbegin.o"
>                        ^
> <stdin>:6:113: note: scanning from here
>   "/usr/bin/ld"
> "--sysroot=/home/rkotler/workspace/llvm/tools/clang/test/Driver/Inputs/debian_reduced_mips_tree"
> "--sysroot=/home/rkotler/workspace/llvm/tools/clang/test/Driver/Inputs/debian_reduced_mips_tree"
> "--build-id" "--eh-frame-hdr" "-m" "elf32btsmip" "-dynamic-linker"
> "/lib/ld.so.1" "-o"
> "/home/rkotler/caviumllvmwclangbe/build/tools/clang/test/Driver/Output/mips-reduced-toolchain.cpp.tmp.o"
> "crt1.o" "crti.o" "crtbegin.o" "/tmp/mips-reduced-toolchain-6e24a4.o"
> "-lgcc" "--as-needed" "-lgcc_s" "--no-as-needed" "-lc" "-lgcc"
> "--as-needed" "-lgcc_s" "--no-as-needed" "crtend.o" "crtn.o"
>
>                                           ^
> <stdin>:6:549: note: possible intended match here
>   "/usr/bin/ld"
> "--sysroot=/home/rkotler/workspace/llvm/tools/clang/test/Driver/Inputs/debian_reduced_mips_tree"
> "--sysroot=/home/rkotler/workspace/llvm/tools/clang/test/Driver/Inputs/debian_reduced_mips_tree"
> "--build-id" "--eh-frame-hdr" "-m" "elf32btsmip" "-dynamic-linker"
> "/lib/ld.so.1" "-o"
> "/home/rkotler/caviumllvmwclangbe/build/tools/clang/test/Driver/Output/mips-reduced-toolchain.cpp.tmp.o"
> "crt1.o" "crti.o" "crtbegin.o" "/tmp/mips-reduced-toolchain-6e24a4.o"
> "-lgcc" "--as-needed" "-lgcc_s" "--no-as-needed" "-lc" "-lgcc"
> "--as-needed" "-lgcc_s" "--no-as-needed" "crtend.o" "crtn.o"
>
>
>
>
>
>
>
>                                                     ^
>
> --
>
> ********************
> Testing Time: 1593.28s
> ********************
> Failing Tests (1):
>      Clang :: Driver/mips-reduced-toolchain.cpp
>
>    Expected Passes    : 16759
>    Expected Failures  : 95
>    Unsupported Tests  : 43
>    Unexpected Failures: 1
> make[1]: *** [check-local-all] Error 1
> make[1]: Leaving directory `/home/rkotler/caviumllvmwclangbe/build/test'
> make: *** [check-all] Error 2
>
> On 03/03/2014 02:00 PM, reed kotler wrote:
>> So it seems to work.
>>
>> rkotler at mipsswbrd006-le:~/caviumnativellvm/build$
>> ./Release+Asserts/bin/clang++ -v -target mipsel-unknown-linux-gnu
>> clang version 3.5
>> (gitosis-ePK3LoutQbwPXssp/fMQcEEOCMrvLtNR-XMD5yJDbdMReXY1tMh2IBg at public.gmane.org:clang.git
>>
>> f4481e0e412e3f817e65d5ce1c835381dc7a7773)
>> (gitosis-ePK3LoutQbwPXssp/fMQcEEOCMrvLtNR-XMD5yJDbdMReXY1tMh2IBg at public.gmane.org:llvm.git
>>
>> 18fe44cb057e4b11533bd3f814b96fdca724baf0)
>> Target: mipsel-unknown-linux-gnu
>> Thread model: posix
>> Found candidate GCC installation: /usr/lib/gcc/mipsel-linux-gnu/4.4
>> Found candidate GCC installation: /usr/lib/gcc/mipsel-linux-gnu/4.4.6
>> Found candidate GCC installation: /usr/lib/gcc/mipsel-linux-gnu/4.4.7
>> Found candidate GCC installation: /usr/lib/gcc/mipsel-linux-gnu/4.6
>> Found candidate GCC installation: /usr/lib/gcc/mipsel-linux-gnu/4.6.3
>> Found candidate GCC installation: /usr/lib/gcc/mipsel-linux-gnu/4.7
>> Found candidate GCC installation: /usr/lib/gcc/mipsel-linux-gnu/4.7.2
>> Selected GCC installation: /usr/lib/gcc/mipsel-linux-gnu/4.7
>> Candidate multilib: .;@m32
>> Selected multilib: .;@m32
>>
>> rkotler at mipsswbrd006-le:~/caviumnativellvm/build$ find /usr/lib -name
>> crtbegin.o
>> /usr/lib/gcc/mipsel-linux-gnu/4.7/crtbegin.o
>> /usr/lib/gcc/mipsel-linux-gnu/4.6/64/crtbegin.o
>> /usr/lib/gcc/mipsel-linux-gnu/4.6/n32/crtbegin.o
>> /usr/lib/gcc/mipsel-linux-gnu/4.6/crtbegin.o
>> /usr/lib/gcc/mipsel-linux-gnu/4.4/crtbegin.o
>> rkotler at mipsswbrd006-le:~/caviumnativellvm/build$
>>
>> 4.7.2 is linked to 4.7
>>
>> rkotler at mipsswbrd006-le:~/caviumnativellvm/build$ ls -l
>> /usr/lib/gcc/mipsel-linux-gnu/4.7.2
>> lrwxrwxrwx 1 root root 3 Oct  7 14:44
>> /usr/lib/gcc/mipsel-linux-gnu/4.7.2 -> 4.7
>> rkotler at mipsswbrd006-le:~/caviumnativellvm/build$
>>
>> rkotler at mipsswbrd006-le:~/caviumnativellvm/build$
>> ./Release+Asserts/bin/clang++ -v -target mipsel-unknown-linux-gnu
>>
>> rkotler at mipsswbrd006-le:~/caviumnativellvm/build$
>> On 03/03/2014 10:59 AM, Simon Atanasyan wrote:
>>> On Mon, Mar 3, 2014 at 10:42 PM, Reed Kotler
>>> <rkotler-8NJIiSa5LzA-XMD5yJDbdMReXY1tMh2IBg at public.gmane.org> wrote:
>>>> I reran with mip32. Seems to not work at all now.
>>> Could you run "find /usr/lib -name crtbegin.o" on that host?
>>>




More information about the cfe-dev mailing list