[Mlir-commits] [mlir] [mlir][arith] doc updates for ub semantics, and int representations (PR #72932)

Fehr Mathieu llvmlistbot at llvm.org
Tue Nov 21 07:10:22 PST 2023


================
@@ -455,10 +471,11 @@ def Arith_CeilDivUIOp : Arith_IntBinaryOp<"ceildivui",
   let description = [{
     Unsigned integer division. Rounds towards positive infinity. Treats the
     leading bit as the most significant, i.e. for `i16` given two's complement
-    representation, `6 / -2 = 6 / (2^16 - 2) = 1`.
+    representation, `6 / -2 = 6 / (2^16 - 2) = 1`. 
 
-    Note: the semantics of division by zero is TBD; do NOT assume any specific
-    behavior.
+    Division by zero is undefined behaviour. When applied to `vector` and 
+    `tensor` values, the result is undefined if _any_ elements are divided by 
----------------
math-fehr wrote:

Same here

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


More information about the Mlir-commits mailing list