Add more graph traits specializations for dominator tree nodes
[oota-llvm.git] / include / llvm / Analysis / Verifier.h
1 //===-- llvm/Analysis/Verifier.h - Module Verifier ---------------*- C++ -*-==//
2 //
3 // This file defines the function verifier interface, that can be used for some
4 // sanity checking of input to the system, and for checking that transformations
5 // haven't done something bad.
6 //
7 // Note that this does not provide full 'java style' security and verifications,
8 // instead it just tries to ensure that code is well formed.
9 //
10 // To see what specifically is checked, look at the top of Verifier.cpp
11 //
12 //===----------------------------------------------------------------------===//
13
14 #ifndef LLVM_ANALYSIS_VERIFIER_H
15 #define LLVM_ANALYSIS_VERIFIER_H
16
17 class Pass;
18 class Module;
19 class Function;
20
21 // createVerifierPass - Check a module or function for validity.  If errors are
22 // detected, error messages corresponding to the problem are printed to stderr.
23 //
24 Pass *createVerifierPass();
25
26 // verifyModule - Check a module for errors, printing messages on stderr.
27 // Return true if the module is corrupt.  This should only be used for
28 // debugging, because it plays games with PassManagers and stuff.
29 //
30 bool verifyModule(const Module &M);
31
32 // verifyFunction - Check a function for errors, useful for use when debugging a
33 // pass.
34 bool verifyFunction(const Function &F);
35
36 #endif