[LLVMdev] subregisters, def-kill

Jonas Paulsson jnspaulsson at hotmail.com
Thu May 19 07:47:24 PDT 2011


Hi,

I am combining 16-bit registers to a 32 bit register in order to make a wide store, as per below:

732 %reg16506:hi16<def,dead> = COPY %reg16445<kill>; 
740 %reg16506:lo16<def> = COPY %reg16468<kill>;
748 %r3<def,dead> = store %reg16506<kill>, %r3, 

As you can see, LiveVariables has marked the high part dead, even though the super-register is used at SlotIndex 748. Why is this? Should I add anything special to the basic BuildMI calls?

The LiveIntervalsAnalysis, then adds ranges to 16506 for the whole block - even prior to 732 which is the first subreg-def. This is a loop body, but 16506 is marked as killed at 748, so I don't see why there is a live range from earlier than 732. The coalescer will then report "Interference", and not coalesce the COPY to the subreg due to overlapping live intervals. 

Any good tips and explanation would be appreciated,

Jonas

 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110519/9bcea208/attachment.html>


More information about the llvm-dev mailing list