[msan] Convert Msan to ModulePass
authorVitaly Buka <vitalybuka@google.com>
Tue, 6 Sep 2022 04:28:02 +0000 (21:28 -0700)
committerVitaly Buka <vitalybuka@google.com>
Tue, 6 Sep 2022 22:01:04 +0000 (15:01 -0700)
commite7bac3b9fa739f8d167a390a547068aad1d424a7
treeb5f6884c56bc510d24d79bbd4ec3bdf58af71ce1
parent82b65496540fbee7720a4fa47ebc3c3dac128980
[msan] Convert Msan to ModulePass

MemorySanitizerPass function pass violatied requirement 4 of function
pass to do not insert globals. Msan nees to insert globals for origin
tracking, and paramereters tracking.

https://llvm.org/docs/WritingAnLLVMPass.html#the-functionpass-class

Reviewed By: kstoimenov, fmayer

Differential Revision: https://reviews.llvm.org/D133336
16 files changed:
clang/lib/CodeGen/BackendUtil.cpp
llvm/include/llvm/Transforms/Instrumentation/MemorySanitizer.h
llvm/lib/Passes/PassRegistry.def
llvm/lib/Transforms/Instrumentation/MemorySanitizer.cpp
llvm/test/Instrumentation/MemorySanitizer/attributes.ll
llvm/test/Instrumentation/MemorySanitizer/check-array.ll
llvm/test/Instrumentation/MemorySanitizer/check-constant-shadow.ll
llvm/test/Instrumentation/MemorySanitizer/check-struct.ll
llvm/test/Instrumentation/MemorySanitizer/msan-disable-checks.ll
llvm/test/Instrumentation/MemorySanitizer/msan_basic.ll
llvm/test/Instrumentation/MemorySanitizer/msan_debug_info.ll
llvm/test/Instrumentation/MemorySanitizer/msan_eager.ll
llvm/test/Instrumentation/MemorySanitizer/msan_llvm_launder_invariant.ll
llvm/test/Instrumentation/MemorySanitizer/msan_llvm_strip_invariant.ll
llvm/test/Instrumentation/MemorySanitizer/reduce.ll
llvm/test/Other/new-pm-print-pipeline.ll