1 ; RUN: llc -march=hexagon -simplifycfg-require-and-preserve-domtree=1 < %s | FileCheck %s
3 ; CHECK: GCC_except_table0:
4 ; CHECK: Call site Encoding = uleb128
6 target triple = "hexagon"
8 @g0 = external constant ptr
10 define i32 @f0() #0 personality ptr @f3 {
12 %v0 = alloca i32, align 4
13 %v1 = alloca i32, align 4
16 %v4 = alloca i32, align 4
18 store i32 1, ptr %v1, align 4
19 %v5 = call ptr @f1(i32 4) #2
21 invoke void @f2(ptr %v5, ptr @g0, ptr null) #3
22 to label %b6 unwind label %b1
25 %v7 = landingpad { ptr, i32 }
27 %v8 = extractvalue { ptr, i32 } %v7, 0
28 store ptr %v8, ptr %v2
29 %v9 = extractvalue { ptr, i32 } %v7, 1
30 store i32 %v9, ptr %v3
34 %v10 = load i32, ptr %v3
35 %v11 = call i32 @llvm.eh.typeid.for(ptr @g0) #2
36 %v12 = icmp eq i32 %v10, %v11
37 br i1 %v12, label %b3, label %b5
40 %v13 = load ptr, ptr %v2
41 %v14 = call ptr @f4(ptr %v13) #2
42 %v16 = load i32, ptr %v14, align 4
43 store i32 %v16, ptr %v4, align 4
44 store i32 2, ptr %v1, align 4
49 %v17 = load i32, ptr %v1, align 4
53 %v18 = load ptr, ptr %v2
54 %v19 = load i32, ptr %v3
55 %v20 = insertvalue { ptr, i32 } undef, ptr %v18, 0
56 %v21 = insertvalue { ptr, i32 } %v20, i32 %v19, 1
57 resume { ptr, i32 } %v21
65 declare void @f2(ptr, ptr, ptr)
69 ; Function Attrs: nounwind readnone
70 declare i32 @llvm.eh.typeid.for(ptr) #1
76 attributes #0 = { "frame-pointer"="all" }
77 attributes #1 = { nounwind readnone }
78 attributes #2 = { nounwind }
79 attributes #3 = { noreturn }