[llvm-commits] Patch: Floating point optimizations for SimplifyInstruction

Duncan Sands baldrick at free.fr
Fri Dec 7 21:28:15 PST 2012


Hi Michael,
>> Can the pattern matching logic you added in your previous patch use
>> isExactlyValue as a cheaper way to test for 1.0?
>
> isExactlyValue does exactly the code from the pattern matching code around the contained APFloat. There doesn't seem to be an easy way out of it.

OK, but in that case maybe your pattern should use isExactlyValue rather than
duplicating the code?  If someone finds a better way one day then they can just
update isExactlyValue and the pattern benefits too.

Ciao, Duncan.



More information about the llvm-commits mailing list