diff options
author | Chris Lattner <sabre@nondot.org> | 2001-07-06 16:57:52 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2001-07-06 16:57:52 +0000 |
commit | 87d0461d5bafe5214870b18080b9450cb32a22c9 (patch) | |
tree | 632d2aabb420858d8745b57492bb663b1053750e /include | |
parent | c348d21bf6160c1f1d1511cc432bc8a7ede66244 (diff) | |
download | external_llvm-87d0461d5bafe5214870b18080b9450cb32a22c9.zip external_llvm-87d0461d5bafe5214870b18080b9450cb32a22c9.tar.gz external_llvm-87d0461d5bafe5214870b18080b9450cb32a22c9.tar.bz2 |
New file, includes method to merge exit nodes together
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include')
-rw-r--r-- | include/llvm/Analysis/SimplifyCFG.h | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/include/llvm/Analysis/SimplifyCFG.h b/include/llvm/Analysis/SimplifyCFG.h new file mode 100644 index 0000000..062d16a --- /dev/null +++ b/include/llvm/Analysis/SimplifyCFG.h @@ -0,0 +1,27 @@ +//===- llvm/Analysis/SimplifyCFG.h - CFG Simplification XForms ---*- C++ -*--=// +// +// This file provides several routines that are useful for simplifying CFGs in +// various ways... +// +//===----------------------------------------------------------------------===// + +#ifndef LLVM_ANALYSIS_SIMPLIFY_CFG_H +#define LLVM_ANALYSIS_SIMPLIFY_CFG_H + +class BasicBlock; +class Method; + +namespace cfg { + + // UnifyAllExitNodes - Unify all exit nodes of the CFG by creating a new + // BasicBlock, and converting all returns to unconditional branches to this + // new basic block. The singular exit node is returned. + // + // If there are no return stmts in the Method, a null pointer is returned. + // + BasicBlock *UnifyAllExitNodes(Method *M); + +} // End Namespace cfg + + +#endif |