[llvm] [IR] Add zext nneg flag (PR #67982)

Alex Bradbury via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 9 12:09:25 PDT 2023


================
@@ -11156,6 +11156,9 @@ until it reaches the size of the destination type, ``ty2``.
 
 When zero extending from i1, the result will always be either 0 or 1.
 
+If the ``nneg`` flag is set, and the ``zext`` argument is negative, the result
----------------
asb wrote:

The description of `nneg` is very minimal, vs the more detailed description in the RFC and PR. Maybe add to "Overview" something like "The `nneg` (non-negative) flag, if present, specifies that the operand is non-negative. This property may be used by optimization passes to later convert the `zext` to a semantically equivalent `sext`."

https://github.com/llvm/llvm-project/pull/67982


More information about the llvm-commits mailing list