[clang] [CIR] Add poison attribute (PR #150760)

Henrich Lauko via cfe-commits cfe-commits at lists.llvm.org
Sat Jul 26 11:21:42 PDT 2025


================
@@ -2239,16 +2249,18 @@ static OpFoldResult
 foldUnaryBitOp(mlir::Attribute inputAttr,
                llvm::function_ref<llvm::APInt(const llvm::APInt &)> func,
                bool poisonZero = false) {
+  if (mlir::isa_and_present<PoisonAttr>(inputAttr)) {
----------------
xlauko wrote:

```suggestion
  if (mlir::isa_and_present<cir::PoisonAttr>(inputAttr)) {
```

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


More information about the cfe-commits mailing list