[Mlir-commits] [mlir] [mlir][amd] fix LLVM::InsertValueOp::create failure to disambiguate (PR #150605)

Maksim Levental llvmlistbot at llvm.org
Fri Jul 25 06:25:12 PDT 2025


================
@@ -232,8 +232,8 @@ struct FatRawBufferCastLowering
     Value result = MemRefDescriptor::poison(
         rewriter, loc,
         getTypeConverter()->convertType(op.getResult().getType()));
-    result = LLVM::InsertValueOp::create(rewriter, loc, result, fatPtr,
-                                         kAllocatedPtrPosInMemRefDescriptor);
+    SmallVector<int64_t> pos{kAllocatedPtrPosInMemRefDescriptor};
+    result = LLVM::InsertValueOp::create(rewriter, loc, result, fatPtr, pos);
----------------
makslevental wrote:

you have have to do `ArrayRef<int64_t>{...}` and I thought this was version was clearer but yea you're right.

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


More information about the Mlir-commits mailing list