[LLVMdev] Illegal optimization in LLVM 2.8 during SelectionDAG? (Re: comparison pattern trouble - might be a bug in LLVM 2.8?)

Duncan Sands baldrick at free.fr
Sat Oct 2 05:20:01 PDT 2010


Hi,

> neither x86 or ARM have 1-bit registers, so they cannot convert the and to trunc.
>
> The trunc should be legal when the machine has 1-bit registers.

while it is true that x86 does not have a 1-bit register, it nonetheless
pretends that it natively supports i1 by declaring i1 to be a legal type.
This is a trick to get better code in some situations.

Ciao,

Duncan.



More information about the llvm-dev mailing list