[LLVMdev] instruction selection based on size

Owen Anderson resistor at mac.com
Thu Jul 19 20:26:58 PDT 2012


You can use the AddedComplexity field to give the smaller encoding priority in the SelectionDAG matcher.

--Owen

On Jul 19, 2012, at 6:26 PM, reed kotler wrote:

> in mips16, we have two versions of many of the instructions that have 
> immediate fields.
> 
> one version is 16 bits and the other is 32 bits.
> 
> we want it to chose the 16 bit version but both patterns will match the 
> selection dag if the
> immediate fields is small enough.
> 
> any simple way to do this?
> 
> tia.
> 
> Reed
> 
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev




More information about the llvm-dev mailing list