Status of clang/llvm cross-compiling for ARM
Damjan Marion
damjan.marion at gmail.com
Mon Jul 4 15:11:11 UTC 2011
Hi,
Just to briefly share with wider audience progress on cross-compiling for
ARM using llvm/clang.
I managed to cross-compile kernel with clang for Marvel SoC and run world
compiled with gcc in multiuser. It works stable and I didn't notice any
issues so far. Cross compiling even works from MacOS. Caveat is that it
still requires binutils as integrated assembler is not stable enough.
The real benefit of having clang in place is support of new ARM
architectures (ARMv6, ARMv7) which are not supported in last GPLv2 gcc/binutils.
With regards to building world, main issue is ARM ABI. FreeBSD uses
ATPCS[1] procedure call standard which is older one. New one is called
AAPCS [2] and introduces some important performance related stuff. llvm/clang
doesn't support older ATPCS standard so it fails to build some libraries.
Andrew already did some work on moving to AAPCS[3]. When we will have AAPCS
implemented then I expect that building of world should work without any major
issues.
Damjan
[1] http://infocenter.arm.com/help/topic/com.arm.doc.espc0002/ATPCS.pdf
[2] http://infocenter.arm.com/help/topic/com.arm.doc.ihi0042d/IHI0042D_aapcs.pdf
[3] http://svnweb.freebsd.org/base/projects/arm_eabi/
More information about the freebsd-current
mailing list