[PATCH] D27028: Add intrinsics for constrained floating point operations

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 5 12:12:28 PST 2016


craig.topper added inline comments.


================
Comment at: lib/IR/IntrinsicInst.cpp:107
+  else if (RoundingArg.equals("LLVM_ROUND_TONEAREST"))
+    return rmToNearest;
+  else if (RoundingArg.equals("LLVM_ROUND_DOWNWARD")) 
----------------
andrew.w.kaylor wrote:
> craig.topper wrote:
> > You could maybe use a StringSwitch.
> That would be perfect, but can I put an llvm_unreachable() in a StringSwitch?
I think StringSwitch will assert if it doesn't find a match and there is no default specified.


Repository:
  rL LLVM

https://reviews.llvm.org/D27028





More information about the llvm-commits mailing list