[patch][pr22947] Use sext in fast isel

Rafael EspĂ­ndola rafael.espindola at gmail.com
Wed Mar 18 08:45:21 PDT 2015


Fast isel currently has a bug in that it zero extends immediates to 64
bits. This normally goes unnoticed because the value is truncated to
32 bits for output.

Two cases were it is noticed:

* We fail to use smaller encodings.
* If the original constant was smaller than i32.

For example, the only possible values for i1 are 0 and -1, yet we were
expanding -1 to i32 1.

Cheers,
Rafael
-------------- next part --------------
A non-text attachment was scrubbed...
Name: t.patch
Type: text/x-patch
Size: 3358 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150318/cb2c7b89/attachment.bin>


More information about the llvm-commits mailing list