[PATCH] D75670: [FPEnv] Intrinsic llvm.roundeven

Eli Friedman via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Mar 5 10:25:26 PST 2020


efriedma added inline comments.


================
Comment at: llvm/docs/LangRef.rst:12931-12934
+'``llvm.roundeven.*``' Intrinsic
+^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+
+Syntax:
----------------
arsenm wrote:
> Isn't this the same as rint? Since the default rounding mode is assumed 
The name is a hint that we should prefer to lower to a library function named "roundeven", if we can't generate an inline sequence.  Other than that, yes, it's identical.

I vaguely recall that I tried to merge llvm.rint and llvm.nearbyint at some point, but someone ran into issues with missing symbols.  I can try to dig it up if you think it's important.


================
Comment at: llvm/docs/LangRef.rst:12965
+This function implements IEEE-754 operation ``roundToIntegralTiesToEven``. It
+also behaves in the same way as C standard function ``roundeven``, except that
+it does not raise floating point exceptions.
----------------
arsenm wrote:
> I've never heard of this C standard function?
It's part of TS 18661-1, which I think is proposed to be part of the next version of the C standard.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D75670





More information about the llvm-commits mailing list