[LLVMdev] big bitcode files producing bad ARM asm

Jakob Stoklund Olesen stoklund at 2pi.dk
Mon Apr 25 18:20:15 PDT 2011


On Apr 25, 2011, at 6:01 PM, Alexander MacDonald wrote:

> I have a rather large bitcode file which when run through "llc -march arm -O0" produces an asm file of about 500Mb. Trying to assemble this file with the ios assembler on osx gives me lots of "branch out of range" errors thanks to jump instructions overflowing the +/-32Mb relative jump limit.
> 
> I've tried running llc with the hidden "-arm-long-calls" option, which solves the problem but forces everything to be an indirect branch. That feels a bit like overkill, does anybody have a suggestion for what the right solution might be?

I don't think any other solutions are currently supported.

One problem is that the linker can move functions around as it pleases, so there is no way of knowing which functions are going to be far away.

/jakob





More information about the llvm-dev mailing list