From d3c37e2cd143e67f6344a23f1cd509a8896d4b4b Mon Sep 17 00:00:00 2001 From: Vitaly Buka Date: Sat, 29 Apr 2023 17:40:33 -0700 Subject: [PATCH] [NFC][HWASAN] Use pointercast instead of bitcast --- llvm/lib/Transforms/Instrumentation/HWAddressSanitizer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/llvm/lib/Transforms/Instrumentation/HWAddressSanitizer.cpp b/llvm/lib/Transforms/Instrumentation/HWAddressSanitizer.cpp index 9708bf7..d377fe5 100644 --- a/llvm/lib/Transforms/Instrumentation/HWAddressSanitizer.cpp +++ b/llvm/lib/Transforms/Instrumentation/HWAddressSanitizer.cpp @@ -1010,7 +1010,7 @@ void HWAddressSanitizer::tagAlloca(IRBuilder<> &IRB, AllocaInst *AI, Value *Tag, IRB.CreateStore(ConstantInt::get(Int8Ty, SizeRemainder), IRB.CreateConstGEP1_32(Int8Ty, ShadowPtr, ShadowSize)); IRB.CreateStore(JustTag, IRB.CreateConstGEP1_32( - Int8Ty, IRB.CreateBitCast(AI, Int8PtrTy), + Int8Ty, IRB.CreatePointerCast(AI, Int8PtrTy), AlignedSize - 1)); } } -- 2.7.4