[Mlir-commits] [llvm] [mlir] [IR] Make Instruction::DebugMarker private behind getDbgMarker(). NFC (PR #224190)

Fangrui Song llvmlistbot at llvm.org
Wed Sep 16 21:14:30 PDT 2026


MaskRay wrote:

`Instruction` should not have public data members. In addition, I'm testing 

```
-  DebugLoc DbgLoc;                         // 'dbg' Metadata cache.
+  /// The debug location or, if HasDbgMarker, the marker recording the
+  /// debugging information that takes effect immediately before this
+  /// instruction. The marker then holds the debug location.
+  union {
+    DebugLoc DbgLoc;
+    DbgMarker *DebugMarker;
+  };
```
but it's currently a memory-for-instructions trade, so I am not upstream the change.

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


More information about the Mlir-commits mailing list