[Mlir-commits] [mlir] [mlir][LLVM] Add dedicated operations for assume align and separate_storage (PR #113317)
Tobias Gysi
llvmlistbot at llvm.org
Tue Oct 22 23:39:55 PDT 2024
gysit wrote:
> Yes I try to model the different assume operand bundles with dedicated operations, since I do not find a way to check whether an arbitrary operand bundle passed to llvm.intr.assume is valid or not. Is this possible?
You could add a verifier to AssumeOp that checks if the operand bundles are correct. If you do that, then it is important to replicate the logic in LLVM's Verifier.cpp. At the moment, only very few intrinsics in LLVM dialect implement a verifier though. Instead, the verification happens after lowering to LLVM proper. I am fine with either of these solutions!
> I agree that having convenience builders for assume operand bundles would be great enough, since the only point of this PR is to have some degree of convenience when building assume intrinsics with tags.
If the goal is to simplify the lowering, then I would go the convenience builder route and avoid introducing custom intrinsics for every operand bundle type.
Having different operations may be interesting if we want to use the assume information in transformations. However, if we want this then it would probably make sense to have a separate Assume dialect. That would require an RFC though especially since there is some overlap with existing dialects, such as memref, which implement some of this functionality.
https://github.com/llvm/llvm-project/pull/113317
More information about the Mlir-commits
mailing list