[LLVMdev] subregisters, def-kill

Jonas Paulsson jnspaulsson at hotmail.com
Thu May 19 23:22:29 PDT 2011


I see, thanks. 

I used to work with GCC, which has an SSA-property verification run after each pass. It is surprising to find that LLVM does not check this!

Jonas

> Subject: Re: [LLVMdev] subregisters, def-kill
> From: stoklund at 2pi.dk
> Date: Thu, 19 May 2011 15:39:40 -0700
> CC: llvmdev at cs.uiuc.edu
> To: jnspaulsson at hotmail.com
> 
> 
> On May 19, 2011, at 7:47 AM, Jonas Paulsson wrote:
> 
> > 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?
> 
> That code is not in SSA form as LiveVariables requires, there can only be one def per virtual register. You need to use INSERT_SUBREG or REG_SEQUENCE to do this.
> 
> /jakob
> 
 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20110520/7bf6d405/attachment.html>


More information about the llvm-dev mailing list