[llvm] LangRef: rint, nearbyint: mention that default rounding mode is assumed (PR #77191)
Andy Kaylor via llvm-commits
llvm-commits at lists.llvm.org
Mon Jan 8 09:50:14 PST 2024
================
@@ -15751,7 +15751,9 @@ Semantics:
""""""""""
This function returns the same values as the libm ``rint`` functions
-would, and handles error conditions in the same way.
+would, and handles error conditions in the same way. The rounding mode
+is assumed to be set to "nearest", so halfway cases are rounded to the
----------------
andykaylor wrote:
It's probably worth mentioning that this assumption is because of the default environment (with a link) and mentioning that constrained intrinsics can be used to avoid the assumption.
https://github.com/llvm/llvm-project/pull/77191
More information about the llvm-commits
mailing list