[llvm] [LangRef] Clarify the `nsz` semantic for `{u, s}itofp` (PR #201557)
via llvm-commits
llvm-commits at lists.llvm.org
Thu Jun 4 05:06:02 PDT 2026
llvmorg-github-actions[bot] wrote:
<!--LLVM PR SUMMARY COMMENT-->
@llvm/pr-subscribers-llvm-ir
Author: paperchalice
<details>
<summary>Changes</summary>
`nsz` has special semantic in `{u,s}itofp`, which falls into the "unless otherwise mentioned" in `nsz` doc, this PR clarifies it in LangRef.
---
Full diff: https://github.com/llvm/llvm-project/pull/201557.diff
1 Files Affected:
- (modified) llvm/docs/LangRef.rst (+6)
``````````diff
diff --git a/llvm/docs/LangRef.rst b/llvm/docs/LangRef.rst
index 4bc684c23ea4f..83c07f16e6a29 100644
--- a/llvm/docs/LangRef.rst
+++ b/llvm/docs/LangRef.rst
@@ -13145,6 +13145,9 @@ the default rounding mode.
If the ``nneg`` flag is set, and the ``uitofp`` argument is negative,
the result is a poison value.
+if the '``nsz``' flag is set and the input value is 0, the sign bit of
+the result is non-deterministic.
+
Example:
""""""""
@@ -13192,6 +13195,9 @@ quantity and converts it to the corresponding floating-point value. If the
value cannot be exactly represented, it is rounded using the default rounding
mode.
+if the '``nsz``' flag is set and the input value is 0, the sign bit of
+the result is non-deterministic.
+
Example:
""""""""
``````````
</details>
https://github.com/llvm/llvm-project/pull/201557
More information about the llvm-commits
mailing list