; RUN: opt < %s -sample-profile -sample-profile-file=%S/Inputs/inline-act.prof ; Sample profile should have non-empty ACT passed to inliner ; int t; ; bool foo(int value) { ; switch(value) { ; case 0: ; case 1: ; case 3: ; return true; ; default: ; return false; ; } ; } ; void bar(int i) { ; if (foo(i)) ; t *= 2; ; } target datalayout = "e-m:e-i64:64-f80:128-n8:16:32:64-S128" target triple = "x86_64-unknown-linux-gnu" @t = global i32 0, align 4 ; Function Attrs: nounwind uwtable define zeroext i1 @_Z3fooi(i32) #0 { %switch.tableidx = sub i32 %0, 0 %2 = icmp ult i32 %switch.tableidx, 4 br i1 %2, label %switch.lookup, label %3 switch.lookup: ; preds = %1 %switch.cast = trunc i32 %switch.tableidx to i4 %switch.shiftamt = mul i4 %switch.cast, 1 %switch.downshift = lshr i4 -5, %switch.shiftamt %switch.masked = trunc i4 %switch.downshift to i1 ret i1 %switch.masked ;