pkg repository for ARM?

Paul Mather paul at gromit.dlib.vt.edu
Thu Aug 22 13:12:33 UTC 2013


On Aug 15, 2013, at 10:19 PM, Tim Kientzle <tim at kientzle.com> wrote:

> 
> On Aug 15, 2013, at 4:09 PM, Paul Mather wrote:
> 
>> AFAIK, a native build under clang on arm is still broken.
> 
> I have done full native builds on BBB since the Clang
> switch got thrown.

I've not tried on the BBB, just Raspberry Pi.  I should probably give it a go on the BBB now I have a cross-built FreeBSD working on there.  I can't think of a good reason why it would work on BBB and not Raspberry Pi, though.


> I haven't been able to do it very consistently, but I
> don't think that can be entirely blamed on clang.  ;-)

Are you doing full native builds with WITHOUT_CLANG_IS_CC set?  I have never managed to do a successful native build using clang; I always have to set the compilers to point to the native GCC versions in my /etc/src.conf.  (I can, of course, successfully cross-build world and kernel using clang via crochet.)

Do you have a SVN revision number that will successfully build natively using clang?

I tried a native build on my Raspberry Pi yesterday, and I still get the clang Abort Trap internal compiler error bug triggered where it complains about unaligned access (Assertion failed: ((PtrVal & ((1 << PtrTraits::NumLowBitsAvailable)-1)) == 0 && "Pointer is not sufficiently aligned")):

=====
c++  -O -pipe -I/usr/src/lib/clang/libllvmsupport/../../../contrib/llvm/include -I/usr/src/lib/clang/libllvmsupport/../../../contrib/llvm/tools/clang/include -I/usr/src/lib/clang/libllvmsupport/../../../contrib/llvm/lib/Support -I. -I/usr/src/lib/clang/libllvmsupport/../../../contrib/llvm/../../lib/clang/include -DLLVM_ON_UNIX -DLLVM_ON_FREEBSD -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -fno-strict-aliasing -DLLVM_DEFAULT_TARGET_TRIPLE=\"armv6-gnueabi-freebsd10.0\" -DLLVM_HOST_TRIPLE=\"armv6-unknown-freebsd10.0\" -DDEFAULT_SYSROOT=\"\" -I/usr/obj/usr/src/tmp/legacy/usr/include -fno-exceptions -fno-rtti  -c /usr/src/lib/clang/libllvmsupport/../../../contrib/llvm/lib/Support/APFloat.cpp -o APFloat.o
Assertion failed: ((PtrVal & ((1 << PtrTraits::NumLowBitsAvailable)-1)) == 0 && "Pointer is not sufficiently aligned"), function initWithPointer, file /usr/src/lib/clang/libclangsema/../../../contrib/llvm/include/llvm/ADT/PointerIntPair.h, line 100.
Stack dump:
0.      Program arguments: /usr/bin/c++ -cc1 -triple armv6-unknown-freebsd10.0 -S -disable-free -main-file-name APFloat.cpp -mrelocation-model static -mdisable-fp-elim -relaxed-aliasing -mconstructor-aliases -target-abi apcs-gnu -target-cpu arm1136jf-s -msoft-float -mfloat-abi soft -target-feature +soft-float -target-feature +soft-float-abi -target-feature -neon -coverage-file /tmp/APFloat-5qvCkz.s -resource-dir /usr/bin/../lib/clang/3.3 -D LLVM_ON_UNIX -D LLVM_ON_FREEBSD -D __STDC_LIMIT_MACROS -D __STDC_CONSTANT_MACROS -D LLVM_DEFAULT_TARGET_TRIPLE="armv6-gnueabi-freebsd10.0" -D LLVM_HOST_TRIPLE="armv6-unknown-freebsd10.0" -D DEFAULT_SYSROOT="" -I /usr/src/lib/clang/libllvmsupport/../../../contrib/llvm/include -I /usr/src/lib/clang/libllvmsupport/../../../contrib/llvm/tools/clang/include -I /usr/src/lib/clang/libllvmsupport/../../../contrib/llvm/lib/Support -I . -I /usr/src/lib/clang/libllvmsupport/../../../contrib/llvm/../../lib/clang/include -I /usr/obj/usr/src/tmp/legacy/usr/include -O2 -fdeprecated-macro -fno-dwarf-directory-asm -fdebug-compilation-dir /usr/obj/usr/src/tmp/usr/src/lib/clang/libllvmsupport -ferror-limit 19 -fmessage-length 0 -mstackrealign -fno-rtti -fno-signed-char -fobjc-runtime=gnustep -fobjc-default-synthesize-properties -fsjlj-exceptions -fdiagnostics-show-option -backend-option -vectorize-loops -o /tmp/APFloat-5qvCkz.s -x c++ /usr/src/lib/clang/libllvmsupport/../../../contrib/llvm/lib/Support/APFloat.cpp 
1.      /usr/include/c++/4.2/bits/basic_string.tcc:978:43: current parser token ';'
2.      /usr/include/c++/4.2/bits/basic_string.tcc:48:1 <Spelling=/usr/include/c++/4.2/bits/c++config.h:76:38>: parsing namespace 'std'
c++: error: unable to execute command: Abort trap (core dumped)
c++: error: clang frontend command failed due to signal (use -v to see invocation)
FreeBSD clang version 3.3 (trunk 178860) 20130405
Target: armv6-unknown-freebsd10.0
Thread model: posix
c++: note: diagnostic msg: PLEASE submit a bug report to http://llvm.org/bugs/ and include the crash backtrace, preprocessed source, and associated run script.
c++: note: diagnostic msg: Error generating preprocessed source(s).
*** [APFloat.o] Error code 254

bmake[2]: stopped in /usr/src/lib/clang/libllvmsupport
1 error

bmake[2]: stopped in /usr/src/lib/clang/libllvmsupport
*** [bootstrap-tools] Error code 2

bmake[1]: stopped in /usr/src
1 error

bmake[1]: stopped in /usr/src
*** [_bootstrap-tools] Error code 2

bmake: stopped in /usr/src
1 error

bmake: stopped in /usr/src
*** [buildworld] Error code 2
1 error
=====

That is with this native version of clang:

FreeBSD clang version 3.3 (trunk 178860) 20130405
Target: armv6-unknown-freebsd10.0
Thread model: posix


Do you (or anyone else) know whether this bug has been fixed?  I'm going to do a native build using GCC and then see if I can do a native build using clang.

Cheers,

Paul.



More information about the freebsd-arm mailing list