[flang-commits] [llvm] [mlir] [clang-tools-extra] [libcxxabi] [compiler-rt] [flang] [libc] [libunwind] [libcxx] [lldb] [clang] [ASan][AMDGPU] Fix Assertion Failure. (PR #78242)

via flang-commits flang-commits at lists.llvm.org
Wed Jan 17 00:26:18 PST 2024


================
@@ -1254,9 +1254,11 @@ Value *AddressSanitizer::memToShadow(Value *Shadow, IRBuilder<> &IRB) {
 void AddressSanitizer::instrumentMemIntrinsic(MemIntrinsic *MI) {
   InstrumentationIRBuilder IRB(MI);
   if (isa<MemTransferInst>(MI)) {
-    IRB.CreateCall(isa<MemMoveInst>(MI) ? AsanMemmove : AsanMemcpy,
-                   {MI->getOperand(0), MI->getOperand(1),
-                    IRB.CreateIntCast(MI->getOperand(2), IntptrTy, false)});
+    IRB.CreateCall(
+        isa<MemMoveInst>(MI) ? AsanMemmove : AsanMemcpy,
+        {MI->getOperand(0),
+         IRB.CreatePointerBitCastOrAddrSpaceCast(MI->getOperand(1), PtrTy),
----------------
ampandey-1995 wrote:

Hi @arsenm Can you please review https://github.com/llvm/llvm-project/pull/78410. 

I have made changes according to your comments.

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


More information about the flang-commits mailing list