[PATCH] D43515: More math intrinsics for conservative math handling

Kevin P. Neal via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 5 12:37:58 PST 2018


kpn added inline comments.


================
Comment at: test/CodeGen/X86/fp-intrinsics.ll:346
 declare double @llvm.experimental.constrained.fma.f64(double, double, double, metadata, metadata)
+declare i32 @llvm.experimental.constrained.fptosi.i32.f64(double, metadata)
+declare float @llvm.experimental.constrained.fptrunc.f32.f64(double, metadata)
----------------
cameron.mcinally wrote:
> Do we want unsigned convert tests too? fptoui?
> 
> I see that there are SystemZ tests to cover them, so maybe that's sufficient? Just pointing this out so others can see.
The SystemZ tests target hardware new enough to lower to a single instruction.

The tests for fptoui on x86 use the default lowering, but the default lowering is disallowed since it does speculative execution and traps. The support for fixing that I had in this patch but was asked to split it out into another patch. So there's no constrained fptoui test here using the default lowering in this patch.


================
Comment at: test/Feature/fp-intrinsics.ll:311
+declare float @llvm.experimental.constrained.fptrunc.f32(double, metadata)
+declare double @llvm.experimental.constrained.fpext.f64(double, metadata)
----------------
cameron.mcinally wrote:
> Should 'fpext.f64' have a float argument instead of a double?
Probably, yes. Will fix.


https://reviews.llvm.org/D43515





More information about the llvm-commits mailing list