[LLVMdev] Immediate instructions / register allocator
jonas.paulsson at ericsson.com
Mon Oct 22 03:38:23 PDT 2012
I tried transforming code that loads an immediate into a virtual register, and then uses that virtual register in various ways, into code that uses immediate operands instead.
To my surprise, this made the register allocator produce worse code in many cases. It seems that it is splitting live intervals and spilling more. In some cases the code was better.
I wonder how this could be? Generally, using the immediates directly as constant operands should decrease regpressure, right? How could the RA-algorithm have been mislead by this?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the llvm-dev