[PATCH] D143505: [InstSimplify] fix/improve folding with an SNaN operand

Sanjay Patel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Feb 14 10:57:01 PST 2023


spatel added inline comments.


================
Comment at: llvm/lib/Analysis/InstructionSimplify.cpp:5320
       // Replace unknown or undef elements with canonical NaN.
+      // TODO: Quiet a signaling NaN element.
       if (EltC && (isa<PoisonValue>(EltC) || EltC->isNaN()))
----------------
jyknight wrote:
> Why is this a TODO? Is it more complex than just another call to makeQuiet?
I don't think so. It was just to have a minimal patch as a first step (the APFloat change wasn't in this patch in the first draft either). 

I can add vector tests and make that a follow-up patch, or I can squash it all together if that's preferred.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D143505/new/

https://reviews.llvm.org/D143505



More information about the llvm-commits mailing list