1 // RUN: %clang_cc1 -triple x86_64-windows -fms-extensions -Wno-implicit-function-declaration -emit-llvm %s -o - | FileCheck %s
3 // CHECK: %[[src:[0-9-]+]] = call ptr @llvm.localaddress()
4 // CHECK-NEXT: %cleanup.dest = load i32, ptr %cleanup.dest.slot, align 4
5 // CHECK-NEXT: %[[src2:[0-9-]+]] = icmp ne i32 %cleanup.dest, 0
6 // CHECK-NEXT: %[[src3:[0-9-]+]] = zext i1 %[[src2]] to i8
7 // CHECK-NEXT: call void @"?fin$0@0@seh_abnormal_exits@@"(i8 noundef %[[src3]], ptr noundef %[[src]])
9 void seh_abnormal_exits(int *Counter
) {
10 for (int i
= 0; i
< 5; i
++) {
13 continue; // abnormal termination
15 goto t10
; // abnormal termination
17 __leave
; // normal execution
19 return; // abnormal termination
22 if (AbnormalTermination()) {
28 return; // *Counter == 3