[clang] [memprof] Export __memprof_default_options_str on Darwin (PR #128920)
Teresa Johnson via cfe-commits
cfe-commits at lists.llvm.org
Fri Feb 28 07:16:29 PST 2025
================
@@ -1617,6 +1617,10 @@ void DarwinClang::AddLinkRuntimeLibArgs(const ArgList &Args,
}
}
+ if (Sanitize.needsMemProfRt())
+ if (hasExportSymbolDirective(Args))
+ addExportedSymbol(CmdArgs, "___memprof_default_options_str");
----------------
teresajohnson wrote:
Can you add a comment about the added `_` prefix? Also, I think it would be nice to just move the name to ProfileData/MemProf.h. If I look at the ProfileData/InstrProf.h included here for example, it contains helper functions to get runtime function names, so this would seem like a good equivalent place for memprof.
https://github.com/llvm/llvm-project/pull/128920
More information about the cfe-commits
mailing list