InstSimplify: fold 0/X to 0 if nnan and nsz

Fiona Glaser fglaser at apple.com
Mon Feb 23 08:11:23 PST 2015


Done!

Fiona

-------------- next part --------------
A non-text attachment was scrubbed...
Name: fdivsimplify.diff
Type: application/octet-stream
Size: 8698 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20150223/33fb3865/attachment.obj>
-------------- next part --------------


> On Feb 22, 2015, at 8:49 PM, Michael Ilseman <milseman at apple.com> wrote:
> 
> Add a comment before the transformation, otherwise LGTM.
> 
> 
>> On Feb 20, 2015, at 7:17 PM, Fiona Glaser <fglaser at apple.com> wrote:
>> 
>> Per the subject! This came up in real production code, so it’s not merely an artificial test case. I was kind of surprised this combine seemed to be missing; is there some reason it’s not legitimate, or was it just forgotten?
>> 
>> (Also, fast-math logic: we need nnan because 0 / 0 can cause NaN, and we need nsz because we don’t know the sign of X, so 0/X could result in either 0 or -0 depending on the sign of X.)
>> 
>> Fiona
>> 
>> 
>> <fdivsimplify.diff>_______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
> 



More information about the llvm-commits mailing list