[PATCH] D127913: [NFC] [HWASan] Remove indirection for getting analyses.
Min-Yih Hsu via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Jun 21 13:52:07 PDT 2022
myhsu added a comment.
Mostly LG. Just curious if the analysis results would be invalidated between GetDT/GetPDT calls (in the original code)?
================
Comment at: llvm/lib/Transforms/Instrumentation/HWAddressSanitizer.cpp:263
bool sanitizeFunction(Function &F,
- llvm::function_ref<const DominatorTree &()> GetDT,
- llvm::function_ref<const PostDominatorTree &()> GetPDT);
+ llvm::AnalysisManager<llvm::Function> &FAM);
void initializeModule();
----------------
Could you use FunctionAnalysisManager instead and drop the "llvm::" prefix.
================
Comment at: llvm/lib/Transforms/Instrumentation/HWAddressSanitizer.cpp:1346
bool HWAddressSanitizer::sanitizeFunction(
- Function &F, llvm::function_ref<const DominatorTree &()> GetDT,
- llvm::function_ref<const PostDominatorTree &()> GetPDT) {
+ Function &F, llvm::AnalysisManager<llvm::Function> &FAM) {
if (&F == HwasanCtorFunction)
----------------
ditto
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D127913/new/
https://reviews.llvm.org/D127913
More information about the llvm-commits
mailing list