[Mlir-commits] [mlir] [mlir][LLVMIR] Skip or folding for mismatched constant types (PR #226026)

Tobias Gysi llvmlistbot at llvm.org
Thu Sep 24 00:10:58 PDT 2026


https://github.com/gysit commented:

Thanks for the PR.

Is this something that actually can be reproduced with `llvm.constant` or `arith.constant`? In general, if feels more like a bug of the constant operation rather than a folder bug if the attribute type doesn't match the op type? 

I am not strictly opposed to adding the check suggested in the PR as defensive programming measure. However, I think we should apply it consistently then? For exmaple, the `ShlOp` folder above should probably also perform a similar check? 

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


More information about the Mlir-commits mailing list