[llvm] [SystemZ] Add proper mcount handling (PR #135767)

Dominik Steenken via llvm-commits llvm-commits at lists.llvm.org
Fri May 2 01:57:14 PDT 2025


================
@@ -558,6 +559,32 @@ void SystemZELFFrameLowering::emitPrologue(MachineFunction &MF,
   // to determine the end of the prologue.
   DebugLoc DL;
 
+  // Add mcount instrumentation if necessary.
+  if (MF.getFunction().getFnAttribute("systemz-backend").getValueAsString() ==
+      "insert-mcount") {
----------------
dominik-steenken wrote:

I have renamed the attribute as requested.

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


More information about the llvm-commits mailing list