https://github.com/fabianmcg created 
https://github.com/llvm/llvm-project/pull/158484

This patch adds the following description to the pointer dialect:
```
    The pointer dialect provides types and operations for representing and
    interacting with pointer values in MLIR, such as loading and storing values
    from/to memory addresses.

    The dialect's main type is an opaque pointer (`ptr`) that can be
    parameterized by a memory space. This type represents a handle to an object
    in memory, or target-dependent values like `nullptr`. Further, the dialect
    assumes that the minimum addressable unit by a pointer is a byte. However,
    the dialect does not make assumptions about the size of a byte, which is
    considered a target-specific property.
```

>From 120da3c559522ae1173a35953d92a47e0e4b5421 Mon Sep 17 00:00:00 2001
From: Fabian Mora <6982088+fabian...@users.noreply.github.com>
Date: Sun, 14 Sep 2025 14:17:38 +0000
Subject: [PATCH] [NFC][mlir][ptr] Clarify pointer dialect semantics

This patch adds the following description to the pointer dialect:
```
    The pointer dialect provides types and operations for representing and
    interacting with pointer values in MLIR, such as loading and storing values
    from/to memory addresses.

    The dialect's main type is an opaque pointer (`ptr`) that can be
    parameterized by a memory space. This type represents a handle to an object
    in memory, or target-dependent values like `nullptr`. Further, the dialect
    assumes that the minimum addressable unit by a pointer is a byte. However,
    the dialect does not make assumptions about the size of a byte, which is
    considered a target-specific property.
```
---
 mlir/include/mlir/Dialect/Ptr/IR/PtrDialect.td | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/mlir/include/mlir/Dialect/Ptr/IR/PtrDialect.td 
b/mlir/include/mlir/Dialect/Ptr/IR/PtrDialect.td
index 7407d74ce3a87..c98df5775195a 100644
--- a/mlir/include/mlir/Dialect/Ptr/IR/PtrDialect.td
+++ b/mlir/include/mlir/Dialect/Ptr/IR/PtrDialect.td
@@ -21,6 +21,18 @@ include "mlir/IR/OpBase.td"
 def Ptr_Dialect : Dialect {
   let name = "ptr";
   let summary = "Pointer dialect";
+  let description = [{
+    The pointer dialect provides types and operations for representing and
+    interacting with pointer values in MLIR, such as loading and storing values
+    from/to memory addresses.
+
+    The dialect's main type is an opaque pointer (`ptr`) that can be
+    parameterized by a memory space. This type represents a handle to an object
+    in memory, or target-dependent values like `nullptr`. Further, the dialect
+    assumes that the minimum addressable unit by a pointer is a byte. However,
+    the dialect does not make assumptions about the size of a byte, which is
+    considered a target-specific property.
+  }];
   let cppNamespace = "::mlir::ptr";
   let useDefaultTypePrinterParser = 1;
   let useDefaultAttributePrinterParser = 1;

_______________________________________________
llvm-branch-commits mailing list
llvm-branch-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

Reply via email to