From f8f8da3c374ac926e8d0eca4cca83d8a8a095b26 Mon Sep 17 00:00:00 2001 From: Dan Liew Date: Thu, 3 Apr 2014 15:30:52 +0100 Subject: Do not add SimplifyLibCallsPass for LLVM 3.4 and newer because it has been removed. From the LLVM 3.4 release notes: " The library call simplification pass has been removed. Its functionality has been integrated into the instruction combiner and function attribute marking passes. " --- lib/Module/Optimize.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib') diff --git a/lib/Module/Optimize.cpp b/lib/Module/Optimize.cpp index 41a106f1..9c200bc8 100644 --- a/lib/Module/Optimize.cpp +++ b/lib/Module/Optimize.cpp @@ -124,7 +124,9 @@ static void AddStandardCompilePasses(PassManager &PM) { addPass(PM, createFunctionInliningPass()); // Inline small functions addPass(PM, createArgumentPromotionPass()); // Scalarize uninlined fn args +#if LLVM_VERSION_CODE < LLVM_VERSION(3, 4) addPass(PM, createSimplifyLibCallsPass()); // Library Call Optimizations +#endif addPass(PM, createInstructionCombiningPass()); // Cleanup for scalarrepl. addPass(PM, createJumpThreadingPass()); // Thread jumps. addPass(PM, createCFGSimplificationPass()); // Merge & remove BBs -- cgit 1.4.1