Owen Anderson | aa4897f | 2010-10-07 20:17:24 +0000 | [diff] [blame] | 1 | //===-- Instrumentation.cpp - TransformUtils Infrastructure ---------------===// |
| 2 | // |
| 3 | // The LLVM Compiler Infrastructure |
| 4 | // |
| 5 | // This file is distributed under the University of Illinois Open Source |
| 6 | // License. See LICENSE.TXT for details. |
| 7 | // |
| 8 | //===----------------------------------------------------------------------===// |
| 9 | // |
| 10 | // This file defines the common initialization infrastructure for the |
| 11 | // Instrumentation library. |
| 12 | // |
| 13 | //===----------------------------------------------------------------------===// |
| 14 | |
| 15 | #include "llvm/InitializePasses.h" |
Filip Pizlo | 40be1e8 | 2013-05-01 20:59:00 +0000 | [diff] [blame] | 16 | #include "llvm/PassRegistry.h" |
Owen Anderson | aa4897f | 2010-10-07 20:17:24 +0000 | [diff] [blame] | 17 | #include "llvm-c/Initialization.h" |
| 18 | |
| 19 | using namespace llvm; |
| 20 | |
| 21 | /// initializeInstrumentation - Initialize all passes in the TransformUtils |
| 22 | /// library. |
| 23 | void llvm::initializeInstrumentation(PassRegistry &Registry) { |
Chandler Carruth | 9b4df49 | 2012-07-22 05:19:32 +0000 | [diff] [blame] | 24 | initializeAddressSanitizerPass(Registry); |
Kostya Serebryany | 1416edc | 2012-11-28 10:31:36 +0000 | [diff] [blame] | 25 | initializeAddressSanitizerModulePass(Registry); |
Chandler Carruth | 9b4df49 | 2012-07-22 05:19:32 +0000 | [diff] [blame] | 26 | initializeBoundsCheckingPass(Registry); |
Chandler Carruth | 9b4df49 | 2012-07-22 05:19:32 +0000 | [diff] [blame] | 27 | initializeGCOVProfilerPass(Registry); |
Evgeniy Stepanov | aa4f97d | 2012-11-29 09:57:20 +0000 | [diff] [blame] | 28 | initializeMemorySanitizerPass(Registry); |
Kostya Serebryany | 60ebb194 | 2012-02-13 22:50:51 +0000 | [diff] [blame] | 29 | initializeThreadSanitizerPass(Registry); |
Peter Collingbourne | 6fa33f5 | 2013-08-07 22:47:18 +0000 | [diff] [blame] | 30 | initializeDataFlowSanitizerPass(Registry); |
Owen Anderson | aa4897f | 2010-10-07 20:17:24 +0000 | [diff] [blame] | 31 | } |
| 32 | |
| 33 | /// LLVMInitializeInstrumentation - C binding for |
| 34 | /// initializeInstrumentation. |
| 35 | void LLVMInitializeInstrumentation(LLVMPassRegistryRef R) { |
| 36 | initializeInstrumentation(*unwrap(R)); |
| 37 | } |