1 ; RUN: opt -S -passes=jump-threading %s | FileCheck %s
3 ; Test if edge weights are properly updated after jump threading.
5 ; CHECK: !2 = !{!"branch_weights", i32 1561806291, i32 585677357}
7 define void @foo(i32 %n) !prof !0 {
9 %cmp = icmp sgt i32 %n, 10
10 br i1 %cmp, label %if.then.1, label %if.else.1, !prof !1
21 %cmp1 = icmp sgt i32 %n, 5
22 br i1 %cmp1, label %if.then.2, label %if.else.2, !prof !2
41 !0 = !{!"function_entry_count", i64 1}
42 !1 = !{!"branch_weights", i32 10, i32 5}
43 !2 = !{!"branch_weights", i32 10, i32 1}