[Mlir-commits] [mlir] [MLIR][MemRefToLLVM] Fix crash in MemorySpaceCastOpLowering when type conversion fails (PR #186404)
Mehdi Amini
llvmlistbot at llvm.org
Fri Mar 13 08:16:10 PDT 2026
================
@@ -1255,8 +1255,10 @@ struct MemorySpaceCastOpLowering
Type resultType = op.getDest().getType();
if (auto resultTypeR = dyn_cast<MemRefType>(resultType)) {
- auto resultDescType =
- cast<LLVM::LLVMStructType>(typeConverter->convertType(resultTypeR));
+ Type convertedType = typeConverter->convertType(resultTypeR);
----------------
joker-eph wrote:
It's not the same semantics though? (`cast` vs `dyn_cast`)
I'm not sure it matters here though...
https://github.com/llvm/llvm-project/pull/186404
More information about the Mlir-commits
mailing list