diff options
author | Duncan Sands <baldrick@free.fr> | 2010-11-14 18:36:10 +0000 |
---|---|---|
committer | Duncan Sands <baldrick@free.fr> | 2010-11-14 18:36:10 +0000 |
commit | eff0581583ef10e2872e9baf537a04b67d992101 (patch) | |
tree | 4aff00b570f7058263f492f0ec91f8e59119547a /include/llvm/Analysis/InstructionSimplify.h | |
parent | 0094345184bc0a791f0811c8d7f5b6f9c8296e0f (diff) | |
download | llvm-eff0581583ef10e2872e9baf537a04b67d992101.tar.gz llvm-eff0581583ef10e2872e9baf537a04b67d992101.tar.bz2 llvm-eff0581583ef10e2872e9baf537a04b67d992101.tar.xz |
If dom tree information is available, make it possible to pass
it to get better phi node simplification.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119055 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Analysis/InstructionSimplify.h')
-rw-r--r-- | include/llvm/Analysis/InstructionSimplify.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/include/llvm/Analysis/InstructionSimplify.h b/include/llvm/Analysis/InstructionSimplify.h index 9825caff8f..d1ad061d5c 100644 --- a/include/llvm/Analysis/InstructionSimplify.h +++ b/include/llvm/Analysis/InstructionSimplify.h @@ -17,6 +17,7 @@ #define LLVM_ANALYSIS_INSTRUCTIONSIMPLIFY_H namespace llvm { + class DominatorTree; class Instruction; class Value; class TargetData; @@ -73,7 +74,8 @@ namespace llvm { /// instruction. If not, this returns null. /// WARNING: If called on unreachable code, an instruction may be reported /// to simplify to itself. - Value *SimplifyInstruction(Instruction *I, const TargetData *TD = 0); + Value *SimplifyInstruction(Instruction *I, const TargetData *TD = 0, + const DominatorTree *DT = 0); /// ReplaceAndSimplifyAllUses - Perform From->replaceAllUsesWith(To) and then @@ -83,7 +85,8 @@ namespace llvm { /// simplifies and deletes scalar operations, it does not change the CFG. /// void ReplaceAndSimplifyAllUses(Instruction *From, Value *To, - const TargetData *TD = 0); + const TargetData *TD = 0, + const DominatorTree *DT = 0); } // end namespace llvm #endif |