Testing LLVM 3.1 on Ubuntu 11.10/12.04 ARM

Few weeks ago LLVM project released LLVM 3.1 release and I decided to give it a try on my ARM boards. I’ve tested on Ubuntu 11.10 on Freescale donated i.MX53 Quick Start Board and on Ubuntu 12.04 on Pandaboard. The results are pretty interesting as is shown in the table below. The table lists number of unexpected failures of basic LLVM testsuite when LLVM is compiled with specific optimization option and with specific GNU C compiler (on appropriate Ubuntu). Please note that Ubuntu 11.10 is last soft-float ABI Ubuntu and it provides GNU C 4.6.1:

Using built-in specs.
Target: arm-linux-gnueabi
Configured with: ../src/configure -v --with-pkgversion='Ubuntu/Linaro 4.6.1-9ubuntu3' --with-bugurl=file:///usr/share/doc/gcc-4.6/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.6 --enable-shared --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.6 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-plugin --enable-objc-gc --enable-multilib --disable-sjlj-exceptions --with-arch=armv7-a --with-float=softfp --with-fpu=vfpv3-d16 --with-mode=thumb --disable-werror --enable-checking=release --build=arm-linux-gnueabi --host=arm-linux-gnueabi --target=arm-linux-gnueabi
Thread model: posix
gcc version 4.6.1 (Ubuntu/Linaro 4.6.1-9ubuntu3) 

On the other hand, Ubuntu 12.04 is the first which provides hard-float ABI and it comes with GNU C 4.6.3:

Using built-in specs.
Target: arm-linux-gnueabihf
Configured with: ../src/configure -v --with-pkgversion='Ubuntu/Linaro 4.6.3-1ubuntu5' --with-bugurl=file:///usr/share/doc/gcc-4.6/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.6 --enable-shared --enable-linker-build-id --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.6 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object --enable-plugin --enable-objc-gc --enable-multilib --disable-sjlj-exceptions --with-arch=armv7-a --with-float=hard --with-fpu=vfpv3-d16 --with-mode=thumb --disable-werror --enable-checking=release --build=arm-linux-gnueabihf --host=arm-linux-gnueabihf --target=arm-linux-gnueabihf
Thread model: posix
gcc version 4.6.3 (Ubuntu/Linaro 4.6.3-1ubuntu5) 

And now, finally those interesting results. The numbers are clickable and link to the testsuite log file which you can see for your reference.

-O0 -O1 -O2 default
GCC 4.6.1 (Ubuntu 11.10) 6 6 54 54
GCC 4.6.3 (Ubuntu 12.04) 6 6 6 6

So it looks like GCC 4.6.3 did a very nice job here. Honestly speaking I’m not sure if this is GCC or ABI switch from soft-float to hard-float and I’m not able to verify it since Ubuntu 12.04 is only hard-float ABI but my bet is on GCC here.


4 thoughts on “Testing LLVM 3.1 on Ubuntu 11.10/12.04 ARM

  1. Hello. I’m following all threads related to Haskell on ARM that I can find…It seems that there are only 6 problems left to be able to use GHC with ARM architecture. What are your expectations?

    • About what problems you are talking? I know so far just one show-stopper, GHCi is not working. Otherwise GHC should be fairly usable on native ARM/Linux.

  2. What’s the status of Android/iOS/Windows RT support? Can we merge the ARM patches into the official GHC distribution so that users have out-of-the-box support for mobile apps?

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s