diff options
-rw-r--r-- | llvm/lib/Analysis/InlineCost.cpp | 2 | ||||
-rw-r--r-- | llvm/test/Transforms/Inline/inline-cold.ll | 20 |
2 files changed, 3 insertions, 19 deletions
diff --git a/llvm/lib/Analysis/InlineCost.cpp b/llvm/lib/Analysis/InlineCost.cpp index 100a591e452..44c14cb17c2 100644 --- a/llvm/lib/Analysis/InlineCost.cpp +++ b/llvm/lib/Analysis/InlineCost.cpp @@ -63,7 +63,7 @@ static cl::opt<bool> // PGO before we actually hook up inliner with analysis passes such as BPI and // BFI. static cl::opt<int> ColdThreshold( - "inlinecold-threshold", cl::Hidden, cl::init(225), + "inlinecold-threshold", cl::Hidden, cl::init(45), cl::desc("Threshold for inlining functions with cold attribute")); static cl::opt<int> diff --git a/llvm/test/Transforms/Inline/inline-cold.ll b/llvm/test/Transforms/Inline/inline-cold.ll index 93d2569d87a..e0e679ad403 100644 --- a/llvm/test/Transforms/Inline/inline-cold.ll +++ b/llvm/test/Transforms/Inline/inline-cold.ll @@ -1,4 +1,4 @@ -; RUN: opt < %s -inline -S -inlinecold-threshold=75 | FileCheck %s +; RUN: opt < %s -inline -S -inlinecold-threshold=25 | FileCheck %s ; Test that functions with attribute Cold are not inlined while the ; same function without attribute Cold will be inlined. @@ -64,23 +64,7 @@ entry: %x3 = add i32 %x2, %a3 %a4 = load volatile i32, i32* @a %x4 = add i32 %x3, %a4 - %a5 = load volatile i32, i32* @a - %x5 = add i32 %x4, %a5 - %a6 = load volatile i32, i32* @a - %x6 = add i32 %x5, %a6 - %a7 = load volatile i32, i32* @a - %x7 = add i32 %x6, %a6 - %a8 = load volatile i32, i32* @a - %x8 = add i32 %x7, %a8 - %a9 = load volatile i32, i32* @a - %x9 = add i32 %x8, %a9 - %a10 = load volatile i32, i32* @a - %x10 = add i32 %x9, %a10 - %a11 = load volatile i32, i32* @a - %x11 = add i32 %x10, %a11 - %a12 = load volatile i32, i32* @a - %x12 = add i32 %x11, %a12 - %add = add i32 %x12, %a + %add = add i32 %x4, %a ret i32 %add } |