[patch] Two fixes to the vpermilvar optimization
Rafael EspĂndola
rafael.espindola at gmail.com
Tue Apr 29 14:13:52 PDT 2014
>> Using a 42 in here has well defined behaviour according to the intel manual.
>
> OK. So this is cleaning things ignored bits of the constant up so the isel matchers will fire correctly? That makes sense. Can you elaborate in the comment a bit?
No, it is clearing it up so that the created shuffle is valid. In the
above case the 42 has to be converted to a 1 since vpermilvar.pd only
uses the second bit for indexing. A shufflevector with an index of 42
would be invalid.
Cheers,
Rafael
More information about the llvm-commits
mailing list