LLVM on ARM A15

Hi folks,

I’ve been playing with LLVM on a Chromebook (Ubuntu) and it seems to work quite well. Installing Ubuntu on the Chromebook was a breeze[1] and all tools/libs/headers required to check-out and build LLVM were accessible via apt-get.

I had two problems to build it, but apart from those, it all ran smoother than I’d expected. I’ll investigate the errors a bit deeper later on, in case they’re not just me messing up. Anyone else trying the same thing out there?

  • First error: DataTypes.h

The generated header tests for some macros regarding unsigned int 64-bits, doesn’t find it and prints an error. Just commenting it out the #error line was enough, since it gets defined later on anyway.

  • Second error: PIC not available

During CMake, SUPPORTS_FPIC_FLAG is set to false, leading to obvious linking problems of shared libraries. Just commenting out the whole if/else block and setting -fPIC anyway does the trick. I’ll check later why the flag is “not supported”.

  • Timings

Whole compilation with -j2 took an hour (ARM back-end only), including check-all, which passed brilliantly, except for LoopVectorize tests. :wink:

I’m guessing this is due to it being disabled by Nadav and when we get the cost model right it’ll go back to passing. Maybe we should mark them as supported only by platforms that implement the cost model?

Hi Renato,

The tests below are target independent and should pass.

Did you build the x86 backend ? I think that the problem is that opt uses the triple from the LL file to initialize the backends and the cost model, and if you don’t have the x86 backend then the tests fail. I will fix the tests shortly.

Thanks,
Nadav

Did you build the x86 backend ? I think that the problem is that opt uses
the triple from the LL file to initialize the backends and the cost model,
and if you don't have the x86 backend then the tests fail.

I did not, that's a good point. I haven't looked at the error messages, to
be honest, it's a bit late here and the Chromebook is already sleeping. :wink:

I will fix the tests shortly.

Thanks!

cheers,
--renato