[llvm] [MemProf][NFC] remove unneeded sized memory access callback (PR #79260)
via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 24 16:23:45 PST 2024
https://github.com/Enna1 updated https://github.com/llvm/llvm-project/pull/79260
>From b9f7dc29d77173e0633be139e9ef6e8fe89a6cce Mon Sep 17 00:00:00 2001
From: "xumingjie.enna1" <xumingjie.enna1 at bytedance.com>
Date: Wed, 24 Jan 2024 14:08:53 +0800
Subject: [PATCH] [MemProf][NFC] remove unneeded sized memory access callback
As discussed in https://github.com/llvm/llvm-project/pull/79244,
the sized memory access callback is leftover stuff carried over from Asan,
can removed from the instrumentation.
---
llvm/lib/Transforms/Instrumentation/MemProfiler.cpp | 6 ------
1 file changed, 6 deletions(-)
diff --git a/llvm/lib/Transforms/Instrumentation/MemProfiler.cpp b/llvm/lib/Transforms/Instrumentation/MemProfiler.cpp
index 2236e9cd44c5049..f7dbe763a59f55f 100644
--- a/llvm/lib/Transforms/Instrumentation/MemProfiler.cpp
+++ b/llvm/lib/Transforms/Instrumentation/MemProfiler.cpp
@@ -215,7 +215,6 @@ class MemProfiler {
// These arrays is indexed by AccessIsWrite
FunctionCallee MemProfMemoryAccessCallback[2];
- FunctionCallee MemProfMemoryAccessCallbackSized[2];
FunctionCallee MemProfMemmove, MemProfMemcpy, MemProfMemset;
Value *DynamicShadowOffset = nullptr;
@@ -508,12 +507,7 @@ void MemProfiler::initializeCallbacks(Module &M) {
for (size_t AccessIsWrite = 0; AccessIsWrite <= 1; AccessIsWrite++) {
const std::string TypeStr = AccessIsWrite ? "store" : "load";
- SmallVector<Type *, 3> Args2 = {IntptrTy, IntptrTy};
SmallVector<Type *, 2> Args1{1, IntptrTy};
- MemProfMemoryAccessCallbackSized[AccessIsWrite] =
- M.getOrInsertFunction(ClMemoryAccessCallbackPrefix + TypeStr + "N",
- FunctionType::get(IRB.getVoidTy(), Args2, false));
-
MemProfMemoryAccessCallback[AccessIsWrite] =
M.getOrInsertFunction(ClMemoryAccessCallbackPrefix + TypeStr,
FunctionType::get(IRB.getVoidTy(), Args1, false));
More information about the llvm-commits
mailing list