[Mlir-commits] [mlir] [mlir] Walk nested non-symbol table ops in symbol dce (PR #143353)

Mehdi Amini llvmlistbot at llvm.org
Tue Jun 24 07:21:28 PDT 2025


================
@@ -98,3 +98,38 @@ module {
   // CHECK: "live.user"() {uses = [@unknown_symbol]} : () -> ()
   "live.user"() {uses = [@unknown_symbol]} : () -> ()
 }
+
+// -----
+
+// Check that we don't DCE nested symbols if they are nested inside region
+// without SymbolTable.
+
+// CHECK-LABEL: module attributes {test.nested_nosymboltable_region}
+module attributes { test.nested_nosymboltable_region } {
+  "test.one_region_op"() ({
+    "test.symbol_scope"() ({
+      // CHECK: func @nfunction
+      func.func @nfunction() {
----------------
joker-eph wrote:

```suggestion
      // CHECK: func nested @nfunction
      func.func nested @nfunction() {
```

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


More information about the Mlir-commits mailing list