[llvm] [memprof] Add const to isAllocationWithHotColdVariant (NFC) (PR #114719)

Kazu Hirata via llvm-commits llvm-commits at lists.llvm.org
Sun Nov 3 14:53:34 PST 2024


https://github.com/kazutakahirata created https://github.com/llvm/llvm-project/pull/114719

None

>From d54fbae9f174a8f83175d5bbfb5c79455974ffb8 Mon Sep 17 00:00:00 2001
From: Kazu Hirata <kazu at google.com>
Date: Sun, 3 Nov 2024 14:41:39 -0800
Subject: [PATCH] [memprof] Add const to isAllocationWithHotColdVariant (NFC)

---
 llvm/lib/Transforms/Instrumentation/MemProfiler.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/llvm/lib/Transforms/Instrumentation/MemProfiler.cpp b/llvm/lib/Transforms/Instrumentation/MemProfiler.cpp
index 248d72ea2cca84..70bee30fd151f6 100644
--- a/llvm/lib/Transforms/Instrumentation/MemProfiler.cpp
+++ b/llvm/lib/Transforms/Instrumentation/MemProfiler.cpp
@@ -754,7 +754,7 @@ stackFrameIncludesInlinedCallStack(ArrayRef<Frame> ProfileCallStack,
   return InlCallStackIter == InlinedCallStack.end();
 }
 
-static bool isAllocationWithHotColdVariant(Function *Callee,
+static bool isAllocationWithHotColdVariant(const Function *Callee,
                                            const TargetLibraryInfo &TLI) {
   if (!Callee)
     return false;



More information about the llvm-commits mailing list