aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/llvm/Transforms/Utils/Local.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/include/llvm/Transforms/Utils/Local.h b/include/llvm/Transforms/Utils/Local.h
index 132a10a..eb21945 100644
--- a/include/llvm/Transforms/Utils/Local.h
+++ b/include/llvm/Transforms/Utils/Local.h
@@ -47,6 +47,15 @@ bool ConstantFoldTerminator(BasicBlock *BB);
Constant *ConstantFoldInstruction(Instruction *I);
+/// canConstantFoldCallTo - Return true if its even possible to fold a call to
+/// the specified function.
+bool canConstantFoldCallTo(Function *F);
+
+/// ConstantFoldCall - Attempt to constant fold a call to the specified function
+/// with the specified arguments, returning null if unsuccessful.
+Constant *ConstantFoldCall(Function *F, const std::vector<Constant*> &Operands);
+
+
//===----------------------------------------------------------------------===//
// Local dead code elimination...
//