[PATCH] D56470: [NewPM] Second attempt at porting ASan
Leonard Chan via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Feb 4 15:35:14 PST 2019
leonardchan added inline comments.
================
Comment at: clang/lib/CodeGen/BackendUtil.cpp:1047
+ if (LangOpts.Sanitize.has(SanitizerKind::Address)) {
+ MPM.addPass(RequireAnalysisPass<ASanGlobalsMetadataAnalysis, Module>());
+ bool Recover = CodeGenOpts.SanitizeRecover.has(SanitizerKind::Address);
----------------
philip.pfaffe wrote:
> This is wrong! Sorry I overlooked that. This pass needs to go into the last Module EP before the sanitizer is inserted.
>
> You can't add it to MPM, it's being overwritten below.
I hope this was inserted correctly this time. By the last Module EP, do you mean the pipeline EP callbacks run over the ModulePassManager?
Also added RUN tests to make sure this works with LTO and ThinLTO.
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D56470/new/
https://reviews.llvm.org/D56470
More information about the llvm-commits
mailing list