[PATCH] D54337: [ASan] Make AddressSanitizer a ModulePass

Leonard Chan via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jan 3 10:37:04 PST 2019


leonardchan added a comment.

In D54337#1345024 <https://reviews.llvm.org/D54337#1345024>, @philip.pfaffe wrote:

> @leonardchan Are you making any progress here?


I haven't gotten back to this yet, but will do so after looking into what may be required for also porting SafeStack and ShadowCallStack to new PM.

> It depends on what you mean by task. There is no clean way for depending on changes between IR units. I.e. you can't express the requirement that two passes have to run in a specific order. But that's okay, implementing such requirements would incure insane complexity. Fortunately, if I recall correctly Asan oesn't need that! Correct me if I'm wrong.
>  But depending on information about other IR units is possible, that's why we have analyses. For asan this means: leave asan a function pass, but pull things pre-computed for the module into a module level analysis.

You're right in that Asan doesn't need to keep track of changes between IR units. I haven't started this yet, but the main thing I was concerned about was that, for some reason, function passes in the new PM couldn't depend on module level analyses and only function level analyses, but I think this is false since `TargetLibraryAnalysis` is an example of an analysis that was ported but is required by many function passes.


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D54337/new/

https://reviews.llvm.org/D54337





More information about the llvm-commits mailing list