[llvm-commits] [llvm] r43289 - in /llvm/trunk: lib/Transforms/Scalar/InstructionCombining.cpp test/Transforms/InstCombine/and2.ll test/Transforms/InstCombine/or2.ll

Chris Lattner clattner at apple.com
Wed Oct 24 11:55:15 PDT 2007


On Oct 24, 2007, at 9:24 AM, Dale Johannesen wrote:

>
> On Oct 24, 2007, at 9:06 AM, Chris Lattner wrote:
>
>>
>> On Oct 24, 2007, at 7:42 AM, Neil Booth wrote:
>>
>>> Chris Lattner wrote:-
>>>
>>>> Author: lattner
>>>> Date: Wed Oct 24 00:38:08 2007
>>>> New Revision: 43289
>>>>
>>>> URL: http://llvm.org/viewvc/llvm-project?rev=43289&view=rev
>>>> Log:
>>>> Implement a couple of foldings for ordered and unordered
>>>> comparisons,
>>>> implementing cases related to PR1738.
>>>
>>> Is there a reason you're not using APFloat's comparison operation?
>>
>> Which one?  I just need to know if single apfloats are nan, I'm not
>> comparing the constant values themselves.
>
> getCategory()==fcNaN
> I suppose we could add an isNan function, but this doesn't seem like
> a very common operation.

Yeah, having isNaN() would be much nicer, and it doesn't cost much.   
I added it and updated the code, thanks!

-Chris



More information about the llvm-commits mailing list