2003-01-14 23:37:41 +01:00
|
|
|
//===- Transforms/Instrumentation.h - Instrumentation passes ----*- C++ -*-===//
|
2005-04-21 22:59:05 +02:00
|
|
|
//
|
2003-10-20 22:19:47 +02:00
|
|
|
// The LLVM Compiler Infrastructure
|
|
|
|
//
|
2007-12-29 20:59:42 +01:00
|
|
|
// This file is distributed under the University of Illinois Open Source
|
|
|
|
// License. See LICENSE.TXT for details.
|
2005-04-21 22:59:05 +02:00
|
|
|
//
|
2003-10-20 22:19:47 +02:00
|
|
|
//===----------------------------------------------------------------------===//
|
2003-01-14 23:37:41 +01:00
|
|
|
//
|
2008-03-06 11:36:00 +01:00
|
|
|
// This file defines constructor functions for instrumentation passes.
|
2003-01-14 23:37:41 +01:00
|
|
|
//
|
|
|
|
//===----------------------------------------------------------------------===//
|
|
|
|
|
|
|
|
#ifndef LLVM_TRANSFORMS_INSTRUMENTATION_H
|
|
|
|
#define LLVM_TRANSFORMS_INSTRUMENTATION_H
|
|
|
|
|
2003-11-11 23:41:34 +01:00
|
|
|
namespace llvm {
|
|
|
|
|
2004-09-30 22:13:55 +02:00
|
|
|
class ModulePass;
|
2012-02-13 23:50:51 +01:00
|
|
|
class FunctionPass;
|
2004-09-30 22:13:55 +02:00
|
|
|
|
2007-02-20 06:31:35 +01:00
|
|
|
// Insert edge profiling instrumentation
|
2005-01-07 07:57:28 +01:00
|
|
|
ModulePass *createEdgeProfilerPass();
|
|
|
|
|
2009-09-01 21:05:58 +02:00
|
|
|
// Insert optimal edge profiling instrumentation
|
|
|
|
ModulePass *createOptimalEdgeProfilerPass();
|
|
|
|
|
2011-01-29 02:09:53 +01:00
|
|
|
// Insert path profiling instrumentation
|
|
|
|
ModulePass *createPathProfilerPass();
|
|
|
|
|
2011-04-16 03:20:23 +02:00
|
|
|
// Insert GCOV profiling instrumentation
|
2011-05-18 01:05:13 +02:00
|
|
|
ModulePass *createGCOVProfilerPass(bool EmitNotes = true, bool EmitData = true,
|
2011-12-06 01:29:13 +01:00
|
|
|
bool Use402Format = false,
|
|
|
|
bool UseExtraChecksum = false);
|
2011-04-12 03:06:09 +02:00
|
|
|
|
2011-11-16 02:35:23 +01:00
|
|
|
// Insert AddressSanitizer (address sanity checking) instrumentation
|
2012-11-29 19:14:24 +01:00
|
|
|
FunctionPass *createAddressSanitizerFunctionPass(
|
|
|
|
bool CheckInitOrder = false, bool CheckUseAfterReturn = false,
|
|
|
|
bool CheckLifetime = false);
|
|
|
|
ModulePass *createAddressSanitizerModulePass(bool CheckInitOrder = false);
|
2012-11-29 10:57:20 +01:00
|
|
|
// Insert MemorySanitizer instrumentation (detection of uninitialized reads)
|
|
|
|
FunctionPass *createMemorySanitizerPass();
|
2012-02-13 23:50:51 +01:00
|
|
|
// Insert ThreadSanitizer (race detection) instrumentation
|
|
|
|
FunctionPass *createThreadSanitizerPass();
|
2011-11-16 02:35:23 +01:00
|
|
|
|
2012-07-21 00:39:33 +02:00
|
|
|
|
|
|
|
// BoundsChecking - This pass instruments the code to perform run-time bounds
|
|
|
|
// checking on loads, stores, and other memory intrinsics.
|
2012-11-23 11:47:35 +01:00
|
|
|
FunctionPass *createBoundsCheckingPass();
|
2012-07-21 00:39:33 +02:00
|
|
|
|
2003-11-11 23:41:34 +01:00
|
|
|
} // End llvm namespace
|
|
|
|
|
2003-01-14 23:37:41 +01:00
|
|
|
#endif
|