summaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
diff options
context:
space:
mode:
authorMatthias Springer <me@m-sp.org>2024-02-28 10:22:45 +0100
committerGitHub <noreply@github.com>2024-02-28 10:22:45 +0100
commit6008cd40b7bbdc66555550c2e38648d5ce99cc78 (patch)
treee9a3394f6e6ff0a6c14bb439b92fbf18364f4ae1 /lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp
parent26b8be201e2d15867bb327a8008fffb3e34d42a5 (diff)
[mlir][Transforms] Dialect conversion: Assert when accessing erased ops (#83132)
The dialect conversion maintains sets of "ignored" and "replaced" ops. This change simplifies the two sets, such that all nested ops are included. (This was previously not the case and sometimes only the parent op was included.) This change allows for more aggressive assertions to prevent incorrect rewriter API usage. E.g., accessing ops/blocks/regions within an erased op. A concrete example: I have seen conversion patterns in downstream projects where an op is replaced with a new op, and the region of the old op is afterwards inlined into the newly created op. This is invalid rewriter API usage: ops that were replaced/erased should not be accessed. Nested ops will be considered "ignored", even if they are moved to a different region after the region's parent op was erased (which is illegal API usage). Instead, create a new op, inline the regions, then replace the old op with the new op.
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/ScriptInterpreterPython.cpp')
0 files changed, 0 insertions, 0 deletions