[Mlir-commits] [mlir] [memref] Support non-scalar copies in `reinterpret_cast` elision (PR #203873)

Andrzej WarzyƄski llvmlistbot at llvm.org
Thu Jul 2 03:09:56 PDT 2026


================

----------------
banach-space wrote:

Does the FIXME comment apply to the 1st `assert` or the 1st and the 2nd? ATM the formatting implies the latter.
```suggestion
  // FIXME: Despite what `getStaticOffsets` implies, `reinterpret_cast` takes
  // only a single offset. That should be fixed at the op definition level.
  assert(rcOffsets.size() == 1 && "Expecting single offset");

    assert(ShapedType::isStatic(rcOffsets[0]) && "expected static offset");
  assert(rcOffsets[0] >= 0 &&
         "static reinterpret_cast offset must be non-negative");
```

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


More information about the Mlir-commits mailing list