; LLVM IR from aws/s2n-tls :: tests/unit (s2n_self_talk_session_id_test)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%struct.s2n_connection = type { i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, [22 x i8], [22 x i8], [22 x i8], i32, i32, %struct.s2n_timer, i64, i64, [32 x i8], i8, i8, i8, i8, i8, i8, i8, ptr, ptr, %struct.s2n_secrets, ptr, ptr, %struct.s2n_kex_parameters, %struct.s2n_handshake_parameters, %struct.s2n_psk_parameters, ptr, i8, i32, [5 x i8], %struct.s2n_stuffer, %struct.s2n_stuffer, %struct.s2n_stuffer, %struct.s2n_stuffer, i32, i64, [2 x i8], %struct.s2n_stuffer, i8, i8, i8, i8, %struct.s2n_atomic_flag, %struct.s2n_atomic_flag, %struct.s2n_handshake, i16, i32, i16, i64, i8, i64, i64, i64, %struct.s2n_atomic_flag, %struct.s2n_atomic_flag, [256 x i8], [256 x i8], i32, %struct.s2n_blob, i32, %struct.s2n_blob, %struct.s2n_blob, %struct.s2n_blob, %struct.s2n_client_hello, %struct.s2n_x509_validator, ptr, ptr, i8, i32, %struct.s2n_blob, i32, %struct.s2n_ticket_fields, [138 x i8], %struct.s2n_stuffer, %struct.s2n_blob, %struct.s2n_blob, i8, i8, i8, i16, i16, i32, i32, %struct.s2n_blob, i32, %struct.s2n_post_handshake, %struct.s2n_atomic_flag, i8, i8 }
%struct.s2n_timer = type { i64 }
%struct.s2n_secrets = type { %union.anon, i32 }
%union.anon = type { %struct.s2n_tls13_secrets }
%struct.s2n_tls13_secrets = type { [48 x i8], [48 x i8], [48 x i8], [48 x i8], [48 x i8], [48 x i8], [48 x i8], [48 x i8], i32 }
%struct.s2n_kex_parameters = type { %struct.s2n_dh_params, %struct.s2n_ecc_evp_params, [4 x ptr], %struct.s2n_ecc_evp_params, %struct.s2n_kem_group_params, %struct.s2n_kem_group_params, [8 x ptr], %struct.s2n_kem_params, %struct.s2n_blob, %struct.s2n_blob }
%struct.s2n_dh_params = type { ptr }
%struct.s2n_ecc_evp_params = type { ptr, ptr }
%struct.s2n_kem_group_params = type { ptr, %struct.s2n_kem_params, %struct.s2n_ecc_evp_params }
%struct.s2n_kem_params = type { ptr, %struct.s2n_blob, %struct.s2n_blob, %struct.s2n_blob, i8 }
%struct.s2n_handshake_parameters = type { %struct.s2n_pkey, %struct.s2n_pkey, %struct.s2n_blob, i32, %struct.s2n_sig_scheme_list, ptr, ptr, ptr, [4 x ptr], [4 x ptr], i8, i8, [32 x i8], [32 x i8] }
%struct.s2n_pkey = type { ptr, ptr, ptr, ptr, ptr, ptr }
%struct.s2n_sig_scheme_list = type { [128 x i16], i8 }
%struct.s2n_psk_parameters = type { i32, %struct.s2n_array, i16, i16, ptr, i32 }
%struct.s2n_array = type { %struct.s2n_blob, i32, i32 }
%struct.s2n_handshake = type { %struct.s2n_stuffer, ptr, [8 x i8], [48 x i8], [48 x i8], i8, i32, i32, i32, i32, %struct.s2n_offered_early_data, i8, i32 }
%struct.s2n_offered_early_data = type { ptr }
%struct.s2n_client_hello = type { %struct.s2n_blob, %struct.s2n_parsed_extensions_list, %struct.s2n_blob, %struct.s2n_blob, %struct.s2n_blob, i8, i8, i8 }
%struct.s2n_parsed_extensions_list = type { [21 x %struct.s2n_parsed_extension], %struct.s2n_blob, i16 }
%struct.s2n_parsed_extension = type { %struct.s2n_blob, i16, i16, i8 }
%struct.s2n_x509_validator = type { ptr, ptr, i8, i8, i16, ptr, i32, ptr, %struct.s2n_cert_validation_info, i8 }
%struct.s2n_cert_validation_info = type { i8, [3 x i8] }
%struct.s2n_ticket_fields = type { %struct.s2n_blob, i32 }
%struct.s2n_stuffer = type { %struct.s2n_blob, i32, i32, i32, i8 }
%struct.s2n_blob = type { ptr, i32, i32, i8 }
%struct.s2n_post_handshake = type { %struct.s2n_stuffer, [4 x i8] }
%struct.s2n_atomic_flag = type { i32 }

@s2n_use_color_in_output = external dso_local global i8, align 1
@stderr = external global ptr, align 8
@.str = external hidden unnamed_addr constant [101 x i8], align 1
@test_count = external dso_local global i32, align 4
@.str.2 = external hidden unnamed_addr constant [88 x i8], align 1
@s2n_errno = external thread_local global i32, align 4
@.str.3 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [90 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [9 x i8], align 1
@SESSION_ID = external hidden constant [33 x i8], align 16
@.str.8 = external hidden unnamed_addr constant [42 x i8], align 1
@MSG = external hidden constant [5 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [89 x i8], align 1

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #0

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memmove.p0.p0.i64(ptr nocapture writeonly, ptr nocapture readonly, i64, i1 immarg) #1

; Function Attrs: nounwind willreturn memory(none)
declare ptr @__errno_location() #2

declare i32 @s2n_print_stacktrace(ptr noundef) #3

; Function Attrs: nounwind
declare i32 @isatty(i32 noundef) #4

; Function Attrs: nounwind
declare i32 @fileno(ptr noundef) #4

; Function Attrs: nounwind
declare i32 @fprintf(ptr noundef, ptr noundef, ...) #4

declare ptr @s2n_strerror(i32 noundef, ptr noundef) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare nonnull ptr @llvm.threadlocal.address.p0(ptr nonnull) #5

declare ptr @s2n_strerror_debug(i32 noundef, ptr noundef) #3

; Function Attrs: nounwind
declare ptr @strerror(i32 noundef) #4

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #0

; Function Attrs: noreturn nounwind
declare void @exit(i32 noundef) #6

; Function Attrs: nounwind willreturn memory(read)
declare i32 @memcmp(ptr noundef, ptr noundef, i64 noundef) #7

; Function Attrs: nounwind uwtable
define dso_local void @mock_client(ptr noundef %0) #8 {
  %2 = alloca ptr, align 8
  %3 = alloca i64, align 8
  %4 = alloca [256 x i8], align 16
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  store ptr %0, ptr %2, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #10
  store i64 0, ptr %3, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 256, ptr %4) #10
  call void @llvm.memset.p0.i64(ptr align 16 %4, i8 0, i64 256, i1 false)
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #10
  store ptr null, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #10
  store ptr null, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #10
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #10
  store i32 0, ptr %8, align 4, !tbaa !11
  %13 = call i32 @sleep(i32 noundef 1)
  %14 = call ptr @s2n_connection_new(i32 noundef 1)
  store ptr %14, ptr %5, align 8, !tbaa !5
  %15 = call ptr @s2n_config_new()
  store ptr %15, ptr %6, align 8, !tbaa !5
  %16 = load ptr, ptr %6, align 8, !tbaa !5
  %17 = call i32 @s2n_config_set_cipher_preferences(ptr noundef %16, ptr noundef @.str.7)
  %18 = load ptr, ptr %6, align 8, !tbaa !5
  %19 = call i32 @s2n_config_disable_x509_verification(ptr noundef %18)
  %20 = load ptr, ptr %5, align 8, !tbaa !5
  %21 = load ptr, ptr %6, align 8, !tbaa !5
  %22 = call i32 @s2n_connection_set_config(ptr noundef %20, ptr noundef %21)
  %23 = load ptr, ptr %5, align 8, !tbaa !5
  %24 = load ptr, ptr %2, align 8, !tbaa !5
  %25 = call i32 @s2n_connection_set_io_pair(ptr noundef %23, ptr noundef %24)
  br label %26

26:                                               ; preds = %1
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #10
  store i32 32, ptr %9, align 4, !tbaa !11
  %27 = load i32, ptr %9, align 4, !tbaa !11
  %28 = icmp ne i32 %27, 0
  br i1 %28, label %29, label %90

29:                                               ; preds = %26
  %30 = load ptr, ptr %5, align 8, !tbaa !5
  %31 = getelementptr inbounds %struct.s2n_connection, ptr %30, i32 0, i32 18
  %32 = getelementptr inbounds [32 x i8], ptr %31, i64 0, i64 0
  %33 = load i32, ptr %9, align 4, !tbaa !11
  %34 = sext i32 %33 to i64
  call void @llvm.memmove.p0.p0.i64(ptr align 8 %32, ptr align 16 @SESSION_ID, i64 %34, i1 false)
  %35 = icmp eq ptr %32, null
  br i1 %35, label %36, label %89

36:                                               ; preds = %29
  br label %37

37:                                               ; preds = %36
  br label %38

38:                                               ; preds = %37
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #10
  %39 = call ptr @__errno_location() #11
  %40 = load i32, ptr %39, align 4, !tbaa !11
  store i32 %40, ptr %10, align 4, !tbaa !11
  %41 = load ptr, ptr @stderr, align 8, !tbaa !5
  %42 = call i32 @s2n_print_stacktrace(ptr noundef %41)
  %43 = load i8, ptr @s2n_use_color_in_output, align 1, !tbaa !13, !range !15, !noundef !16
  %44 = trunc i8 %43 to i1
  br i1 %44, label %45, label %67

45:                                               ; preds = %38
  %46 = load ptr, ptr @stderr, align 8, !tbaa !5
  %47 = call i32 @fileno(ptr noundef %46) #10
  %48 = call i32 @isatty(i32 noundef %47) #10
  %49 = icmp ne i32 %48, 0
  br i1 %49, label %50, label %67

50:                                               ; preds = %45
  %51 = load i32, ptr %10, align 4, !tbaa !11
  %52 = call ptr @__errno_location() #11
  store i32 %51, ptr %52, align 4, !tbaa !11
  %53 = load ptr, ptr @stderr, align 8, !tbaa !5
  %54 = load i32, ptr @test_count, align 4, !tbaa !11
  %55 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %56 = load i32, ptr %55, align 4, !tbaa !11
  %57 = call ptr @s2n_strerror(i32 noundef %56, ptr noundef @.str.3)
  %58 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %59 = load i32, ptr %58, align 4, !tbaa !11
  %60 = call ptr @s2n_strerror_debug(i32 noundef %59, ptr noundef @.str.3)
  %61 = call ptr @__errno_location() #11
  %62 = load i32, ptr %61, align 4, !tbaa !11
  %63 = call ptr @strerror(i32 noundef %62) #10
  %64 = call ptr @__errno_location() #11
  %65 = load i32, ptr %64, align 4, !tbaa !11
  %66 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %53, ptr noundef @.str, i32 noundef %54, ptr noundef @.str.8, ptr noundef @.str.2, i32 noundef 163, ptr noundef %57, ptr noundef %60, ptr noundef %63, i32 noundef %65) #10
  br label %84

67:                                               ; preds = %45, %38
  %68 = load i32, ptr %10, align 4, !tbaa !11
  %69 = call ptr @__errno_location() #11
  store i32 %68, ptr %69, align 4, !tbaa !11
  %70 = load ptr, ptr @stderr, align 8, !tbaa !5
  %71 = load i32, ptr @test_count, align 4, !tbaa !11
  %72 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %73 = load i32, ptr %72, align 4, !tbaa !11
  %74 = call ptr @s2n_strerror(i32 noundef %73, ptr noundef @.str.3)
  %75 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %76 = load i32, ptr %75, align 4, !tbaa !11
  %77 = call ptr @s2n_strerror_debug(i32 noundef %76, ptr noundef @.str.3)
  %78 = call ptr @__errno_location() #11
  %79 = load i32, ptr %78, align 4, !tbaa !11
  %80 = call ptr @strerror(i32 noundef %79) #10
  %81 = call ptr @__errno_location() #11
  %82 = load i32, ptr %81, align 4, !tbaa !11
  %83 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %70, ptr noundef @.str.4, i32 noundef %71, ptr noundef @.str.8, ptr noundef @.str.2, i32 noundef 163, ptr noundef %74, ptr noundef %77, ptr noundef %80, i32 noundef %82) #10
  br label %84

84:                                               ; preds = %67, %50
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #10
  br label %85

85:                                               ; preds = %84
  br label %86

86:                                               ; preds = %85
  call void @exit(i32 noundef 1) #12
  unreachable

87:                                               ; No predecessors!
  br label %88

88:                                               ; preds = %87
  br label %89

89:                                               ; preds = %88, %29
  br label %90

90:                                               ; preds = %89, %26
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #10
  br label %91

91:                                               ; preds = %90
  br label %92

92:                                               ; preds = %91
  %93 = load ptr, ptr %5, align 8, !tbaa !5
  %94 = getelementptr inbounds %struct.s2n_connection, ptr %93, i32 0, i32 19
  store i8 32, ptr %94, align 8, !tbaa !17
  %95 = load ptr, ptr %5, align 8, !tbaa !5
  %96 = call i32 @s2n_negotiate(ptr noundef %95, ptr noundef %7)
  %97 = icmp ne i32 %96, 0
  br i1 %97, label %98, label %99

98:                                               ; preds = %92
  store i32 1, ptr %8, align 4, !tbaa !11
  br label %99

99:                                               ; preds = %98, %92
  %100 = load ptr, ptr %5, align 8, !tbaa !5
  %101 = call zeroext i1 @s2n_handshake_type_check_flag(ptr noundef %100, i32 noundef 2)
  br i1 %101, label %103, label %102

102:                                              ; preds = %99
  store i32 2, ptr %8, align 4, !tbaa !11
  br label %103

103:                                              ; preds = %102, %99
  %104 = getelementptr inbounds [256 x i8], ptr %4, i64 0, i64 0
  call void @llvm.memset.p0.i64(ptr align 16 %104, i8 0, i64 256, i1 false)
  %105 = load ptr, ptr %5, align 8, !tbaa !5
  %106 = call i32 @s2n_connection_get_session_length(ptr noundef %105)
  %107 = sext i32 %106 to i64
  store i64 %107, ptr %3, align 8, !tbaa !9
  %108 = load i64, ptr %3, align 8, !tbaa !9
  %109 = icmp ugt i64 %108, 256
  br i1 %109, label %110, label %111

110:                                              ; preds = %103
  store i32 3, ptr %8, align 4, !tbaa !11
  br label %111

111:                                              ; preds = %110, %103
  %112 = load ptr, ptr %5, align 8, !tbaa !5
  %113 = getelementptr inbounds [256 x i8], ptr %4, i64 0, i64 0
  %114 = call i32 @s2n_connection_get_session(ptr noundef %112, ptr noundef %113, i64 noundef 1)
  %115 = icmp eq i32 %114, 0
  br i1 %115, label %116, label %117

116:                                              ; preds = %111
  store i32 4, ptr %8, align 4, !tbaa !11
  br label %117

117:                                              ; preds = %116, %111
  %118 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %119 = load i32, ptr %118, align 4, !tbaa !11
  %120 = icmp ne i32 %119, 469762077
  br i1 %120, label %121, label %122

121:                                              ; preds = %117
  store i32 5, ptr %8, align 4, !tbaa !11
  br label %122

122:                                              ; preds = %121, %117
  %123 = load ptr, ptr %5, align 8, !tbaa !5
  %124 = getelementptr inbounds [256 x i8], ptr %4, i64 0, i64 0
  %125 = load i64, ptr %3, align 8, !tbaa !9
  %126 = call i32 @s2n_connection_get_session(ptr noundef %123, ptr noundef %124, i64 noundef %125)
  %127 = sext i32 %126 to i64
  %128 = load i64, ptr %3, align 8, !tbaa !9
  %129 = icmp ne i64 %127, %128
  br i1 %129, label %130, label %131

130:                                              ; preds = %122
  store i32 6, ptr %8, align 4, !tbaa !11
  br label %131

131:                                              ; preds = %130, %122
  %132 = load ptr, ptr %5, align 8, !tbaa !5
  %133 = getelementptr inbounds %struct.s2n_connection, ptr %132, i32 0, i32 18
  %134 = getelementptr inbounds [32 x i8], ptr %133, i64 0, i64 0
  %135 = call i32 @memcmp(ptr noundef %134, ptr noundef @SESSION_ID, i64 noundef 32) #13
  %136 = icmp eq i32 %135, 0
  br i1 %136, label %137, label %138

137:                                              ; preds = %131
  store i32 7, ptr %8, align 4, !tbaa !11
  br label %138

138:                                              ; preds = %137, %131
  %139 = load ptr, ptr %5, align 8, !tbaa !5
  %140 = call i64 @s2n_send(ptr noundef %139, ptr noundef @MSG, i64 noundef 5, ptr noundef %7)
  %141 = icmp ne i64 %140, 5
  br i1 %141, label %142, label %143

142:                                              ; preds = %138
  store i32 8, ptr %8, align 4, !tbaa !11
  br label %143

143:                                              ; preds = %142, %138
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #10
  store i32 -1, ptr %11, align 4, !tbaa !11
  br label %144

144:                                              ; preds = %147, %143
  %145 = load i32, ptr %11, align 4, !tbaa !11
  %146 = icmp ne i32 %145, 0
  br i1 %146, label %147, label %150

147:                                              ; preds = %144
  %148 = load ptr, ptr %5, align 8, !tbaa !5
  %149 = call i32 @s2n_shutdown(ptr noundef %148, ptr noundef %7)
  store i32 %149, ptr %11, align 4, !tbaa !11
  br label %144, !llvm.loop !43

150:                                              ; preds = %144
  %151 = load ptr, ptr %5, align 8, !tbaa !5
  %152 = call i32 @s2n_connection_free(ptr noundef %151)
  %153 = call i32 @sleep(i32 noundef 1)
  %154 = call ptr @s2n_connection_new(i32 noundef 1)
  store ptr %154, ptr %5, align 8, !tbaa !5
  %155 = load ptr, ptr %5, align 8, !tbaa !5
  %156 = load ptr, ptr %2, align 8, !tbaa !5
  %157 = call i32 @s2n_connection_set_io_pair(ptr noundef %155, ptr noundef %156)
  %158 = load ptr, ptr %5, align 8, !tbaa !5
  %159 = getelementptr inbounds [256 x i8], ptr %4, i64 0, i64 0
  %160 = load i64, ptr %3, align 8, !tbaa !9
  %161 = call i32 @s2n_connection_set_session(ptr noundef %158, ptr noundef %159, i64 noundef %160)
  %162 = icmp slt i32 %161, 0
  br i1 %162, label %163, label %164

163:                                              ; preds = %150
  store i32 9, ptr %8, align 4, !tbaa !11
  br label %164

164:                                              ; preds = %163, %150
  %165 = load ptr, ptr %5, align 8, !tbaa !5
  %166 = call i32 @s2n_negotiate(ptr noundef %165, ptr noundef %7)
  %167 = icmp ne i32 %166, 0
  br i1 %167, label %168, label %169

168:                                              ; preds = %164
  store i32 10, ptr %8, align 4, !tbaa !11
  br label %169

169:                                              ; preds = %168, %164
  %170 = load ptr, ptr %5, align 8, !tbaa !5
  %171 = call zeroext i1 @s2n_handshake_type_check_flag(ptr noundef %170, i32 noundef 2)
  br i1 %171, label %175, label %172

172:                                              ; preds = %169
  %173 = load ptr, ptr %5, align 8, !tbaa !5
  %174 = call zeroext i1 @s2n_handshake_type_check_flag(ptr noundef %173, i32 noundef 1)
  br i1 %174, label %176, label %175

175:                                              ; preds = %172, %169
  store i32 11, ptr %8, align 4, !tbaa !11
  br label %176

176:                                              ; preds = %175, %172
  %177 = load ptr, ptr %5, align 8, !tbaa !5
  %178 = call i64 @s2n_send(ptr noundef %177, ptr noundef @MSG, i64 noundef 5, ptr noundef %7)
  %179 = icmp ne i64 %178, 5
  br i1 %179, label %180, label %181

180:                                              ; preds = %176
  store i32 12, ptr %8, align 4, !tbaa !11
  br label %181

181:                                              ; preds = %180, %176
  store i32 -1, ptr %11, align 4, !tbaa !11
  br label %182

182:                                              ; preds = %185, %181
  %183 = load i32, ptr %11, align 4, !tbaa !11
  %184 = icmp ne i32 %183, 0
  br i1 %184, label %185, label %188

185:                                              ; preds = %182
  %186 = load ptr, ptr %5, align 8, !tbaa !5
  %187 = call i32 @s2n_shutdown(ptr noundef %186, ptr noundef %7)
  store i32 %187, ptr %11, align 4, !tbaa !11
  br label %182, !llvm.loop !45

188:                                              ; preds = %182
  %189 = load ptr, ptr %5, align 8, !tbaa !5
  %190 = call i32 @s2n_connection_free(ptr noundef %189)
  %191 = call i32 @sleep(i32 noundef 1)
  %192 = call ptr @s2n_connection_new(i32 noundef 1)
  store ptr %192, ptr %5, align 8, !tbaa !5
  br label %193

193:                                              ; preds = %188
  %194 = load i32, ptr @test_count, align 4, !tbaa !11
  %195 = add nsw i32 %194, 1
  store i32 %195, ptr @test_count, align 4, !tbaa !11
  %196 = load ptr, ptr %5, align 8, !tbaa !5
  %197 = call i32 @s2n_connection_set_blinding(ptr noundef %196, i32 noundef 1)
  %198 = icmp eq i32 %197, -1
  br i1 %198, label %199, label %252

199:                                              ; preds = %193
  br label %200

200:                                              ; preds = %199
  br label %201

201:                                              ; preds = %200
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #10
  %202 = call ptr @__errno_location() #11
  %203 = load i32, ptr %202, align 4, !tbaa !11
  store i32 %203, ptr %12, align 4, !tbaa !11
  %204 = load ptr, ptr @stderr, align 8, !tbaa !5
  %205 = call i32 @s2n_print_stacktrace(ptr noundef %204)
  %206 = load i8, ptr @s2n_use_color_in_output, align 1, !tbaa !13, !range !15, !noundef !16
  %207 = trunc i8 %206 to i1
  br i1 %207, label %208, label %230

208:                                              ; preds = %201
  %209 = load ptr, ptr @stderr, align 8, !tbaa !5
  %210 = call i32 @fileno(ptr noundef %209) #10
  %211 = call i32 @isatty(i32 noundef %210) #10
  %212 = icmp ne i32 %211, 0
  br i1 %212, label %213, label %230

213:                                              ; preds = %208
  %214 = load i32, ptr %12, align 4, !tbaa !11
  %215 = call ptr @__errno_location() #11
  store i32 %214, ptr %215, align 4, !tbaa !11
  %216 = load ptr, ptr @stderr, align 8, !tbaa !5
  %217 = load i32, ptr @test_count, align 4, !tbaa !11
  %218 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %219 = load i32, ptr %218, align 4, !tbaa !11
  %220 = call ptr @s2n_strerror(i32 noundef %219, ptr noundef @.str.3)
  %221 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %222 = load i32, ptr %221, align 4, !tbaa !11
  %223 = call ptr @s2n_strerror_debug(i32 noundef %222, ptr noundef @.str.3)
  %224 = call ptr @__errno_location() #11
  %225 = load i32, ptr %224, align 4, !tbaa !11
  %226 = call ptr @strerror(i32 noundef %225) #10
  %227 = call ptr @__errno_location() #11
  %228 = load i32, ptr %227, align 4, !tbaa !11
  %229 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %216, ptr noundef @.str, i32 noundef %217, ptr noundef @.str.9, ptr noundef @.str.2, i32 noundef 248, ptr noundef %220, ptr noundef %223, ptr noundef %226, i32 noundef %228) #10
  br label %247

230:                                              ; preds = %208, %201
  %231 = load i32, ptr %12, align 4, !tbaa !11
  %232 = call ptr @__errno_location() #11
  store i32 %231, ptr %232, align 4, !tbaa !11
  %233 = load ptr, ptr @stderr, align 8, !tbaa !5
  %234 = load i32, ptr @test_count, align 4, !tbaa !11
  %235 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %236 = load i32, ptr %235, align 4, !tbaa !11
  %237 = call ptr @s2n_strerror(i32 noundef %236, ptr noundef @.str.3)
  %238 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %239 = load i32, ptr %238, align 4, !tbaa !11
  %240 = call ptr @s2n_strerror_debug(i32 noundef %239, ptr noundef @.str.3)
  %241 = call ptr @__errno_location() #11
  %242 = load i32, ptr %241, align 4, !tbaa !11
  %243 = call ptr @strerror(i32 noundef %242) #10
  %244 = call ptr @__errno_location() #11
  %245 = load i32, ptr %244, align 4, !tbaa !11
  %246 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %233, ptr noundef @.str.4, i32 noundef %234, ptr noundef @.str.9, ptr noundef @.str.2, i32 noundef 248, ptr noundef %237, ptr noundef %240, ptr noundef %243, i32 noundef %245) #10
  br label %247

247:                                              ; preds = %230, %213
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #10
  br label %248

248:                                              ; preds = %247
  br label %249

249:                                              ; preds = %248
  call void @exit(i32 noundef 1) #12
  unreachable

250:                                              ; No predecessors!
  br label %251

251:                                              ; preds = %250
  br label %252

252:                                              ; preds = %251, %193
  br label %253

253:                                              ; preds = %252
  br label %254

254:                                              ; preds = %253
  %255 = load ptr, ptr %5, align 8, !tbaa !5
  %256 = load ptr, ptr %2, align 8, !tbaa !5
  %257 = call i32 @s2n_connection_set_io_pair(ptr noundef %255, ptr noundef %256)
  %258 = getelementptr inbounds [256 x i8], ptr %4, i64 0, i64 0
  store i8 3, ptr %258, align 16, !tbaa !46
  %259 = load ptr, ptr %5, align 8, !tbaa !5
  %260 = getelementptr inbounds [256 x i8], ptr %4, i64 0, i64 0
  %261 = load i64, ptr %3, align 8, !tbaa !9
  %262 = call i32 @s2n_connection_set_session(ptr noundef %259, ptr noundef %260, i64 noundef %261)
  %263 = icmp eq i32 %262, 0
  br i1 %263, label %264, label %265

264:                                              ; preds = %254
  store i32 13, ptr %8, align 4, !tbaa !11
  br label %265

265:                                              ; preds = %264, %254
  %266 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %267 = load i32, ptr %266, align 4, !tbaa !11
  %268 = icmp ne i32 %267, 469762076
  br i1 %268, label %269, label %270

269:                                              ; preds = %265
  store i32 14, ptr %8, align 4, !tbaa !11
  br label %270

270:                                              ; preds = %269, %265
  %271 = getelementptr inbounds [256 x i8], ptr %4, i64 0, i64 0
  store i8 0, ptr %271, align 16, !tbaa !46
  %272 = load i64, ptr %3, align 8, !tbaa !9
  %273 = icmp ult i64 %272, 36
  br i1 %273, label %274, label %275

274:                                              ; preds = %270
  store i32 15, ptr %8, align 4, !tbaa !11
  br label %275

275:                                              ; preds = %274, %270
  %276 = getelementptr inbounds [256 x i8], ptr %4, i64 0, i64 35
  store i8 30, ptr %276, align 1, !tbaa !46
  %277 = load ptr, ptr %5, align 8, !tbaa !5
  %278 = getelementptr inbounds [256 x i8], ptr %4, i64 0, i64 0
  %279 = load i64, ptr %3, align 8, !tbaa !9
  %280 = call i32 @s2n_connection_set_session(ptr noundef %277, ptr noundef %278, i64 noundef %279)
  %281 = icmp slt i32 %280, 0
  br i1 %281, label %282, label %283

282:                                              ; preds = %275
  store i32 16, ptr %8, align 4, !tbaa !11
  br label %283

283:                                              ; preds = %282, %275
  %284 = load ptr, ptr %5, align 8, !tbaa !5
  %285 = call i32 @s2n_negotiate(ptr noundef %284, ptr noundef %7)
  %286 = icmp eq i32 %285, 0
  br i1 %286, label %287, label %288

287:                                              ; preds = %283
  store i32 17, ptr %8, align 4, !tbaa !11
  br label %288

288:                                              ; preds = %287, %283
  %289 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %290 = load i32, ptr %289, align 4, !tbaa !11
  %291 = icmp ne i32 %290, 335544322
  br i1 %291, label %292, label %293

292:                                              ; preds = %288
  store i32 18, ptr %8, align 4, !tbaa !11
  br label %293

293:                                              ; preds = %292, %288
  %294 = load ptr, ptr %5, align 8, !tbaa !5
  %295 = call i32 @s2n_connection_free(ptr noundef %294)
  %296 = load ptr, ptr %6, align 8, !tbaa !5
  %297 = call i32 @s2n_config_free(ptr noundef %296)
  %298 = call i32 @sleep(i32 noundef 1)
  %299 = load ptr, ptr %2, align 8, !tbaa !5
  %300 = call i32 @s2n_io_pair_close_one_end(ptr noundef %299, i32 noundef 1)
  %301 = load i32, ptr %8, align 4, !tbaa !11
  call void @exit(i32 noundef %301) #12
  unreachable
}

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #9

declare i32 @sleep(i32 noundef) #3

declare ptr @s2n_connection_new(i32 noundef) #3

declare ptr @s2n_config_new() #3

declare i32 @s2n_config_set_cipher_preferences(ptr noundef, ptr noundef) #3

declare i32 @s2n_config_disable_x509_verification(ptr noundef) #3

declare i32 @s2n_connection_set_config(ptr noundef, ptr noundef) #3

declare i32 @s2n_connection_set_io_pair(ptr noundef, ptr noundef) #3

declare i32 @s2n_negotiate(ptr noundef, ptr noundef) #3

declare zeroext i1 @s2n_handshake_type_check_flag(ptr noundef, i32 noundef) #3

declare i32 @s2n_connection_get_session_length(ptr noundef) #3

declare i32 @s2n_connection_get_session(ptr noundef, ptr noundef, i64 noundef) #3

declare i64 @s2n_send(ptr noundef, ptr noundef, i64 noundef, ptr noundef) #3

declare i32 @s2n_shutdown(ptr noundef, ptr noundef) #3

declare i32 @s2n_connection_free(ptr noundef) #3

declare i32 @s2n_connection_set_session(ptr noundef, ptr noundef, i64 noundef) #3

declare i32 @s2n_connection_set_blinding(ptr noundef, i32 noundef) #3

declare i32 @s2n_config_free(ptr noundef) #3

declare i32 @s2n_io_pair_close_one_end(ptr noundef, i32 noundef) #3

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { nounwind willreturn memory(none) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nounwind willreturn memory(read) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #8 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #9 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #10 = { nounwind }
attributes #11 = { nounwind willreturn memory(none) }
attributes #12 = { noreturn nounwind }
attributes #13 = { nounwind willreturn memory(read) }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!14, !14, i64 0}
!14 = !{!"_Bool", !7, i64 0}
!15 = !{i8 0, i8 2}
!16 = !{}
!17 = !{!18, !7, i64 216}
!18 = !{!"s2n_connection", !12, i64 0, !12, i64 0, !12, i64 0, !12, i64 0, !12, i64 0, !12, i64 0, !12, i64 0, !12, i64 0, !12, i64 1, !12, i64 1, !12, i64 1, !12, i64 1, !12, i64 1, !12, i64 1, !12, i64 1, !12, i64 1, !12, i64 2, !12, i64 2, !12, i64 2, !12, i64 2, !12, i64 2, !12, i64 2, !12, i64 2, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !7, i64 80, !7, i64 102, !7, i64 124, !12, i64 148, !12, i64 152, !19, i64 160, !10, i64 168, !10, i64 176, !7, i64 184, !7, i64 216, !7, i64 217, !7, i64 218, !7, i64 219, !7, i64 220, !7, i64 221, !7, i64 222, !6, i64 224, !6, i64 232, !20, i64 240, !6, i64 632, !6, i64 640, !21, i64 648, !27, i64 1144, !30, i64 1688, !6, i64 1752, !7, i64 1760, !12, i64 1764, !7, i64 1768, !33, i64 1776, !33, i64 1816, !33, i64 1856, !33, i64 1896, !12, i64 1936, !10, i64 1944, !7, i64 1952, !33, i64 1960, !7, i64 2000, !7, i64 2001, !7, i64 2002, !14, i64 2003, !34, i64 2004, !34, i64 2008, !35, i64 2016, !32, i64 2208, !12, i64 2212, !32, i64 2216, !10, i64 2224, !7, i64 2232, !10, i64 2240, !10, i64 2248, !10, i64 2256, !34, i64 2264, !34, i64 2268, !7, i64 2272, !7, i64 2528, !12, i64 2784, !26, i64 2792, !12, i64 2816, !26, i64 2824, !26, i64 2848, !26, i64 2872, !37, i64 2896, !39, i64 3704, !6, i64 3760, !6, i64 3768, !7, i64 3776, !12, i64 3780, !26, i64 3784, !12, i64 3808, !41, i64 3816, !7, i64 3848, !33, i64 3992, !26, i64 4032, !26, i64 4056, !14, i64 4080, !14, i64 4081, !14, i64 4082, !32, i64 4084, !32, i64 4086, !12, i64 4088, !12, i64 4092, !26, i64 4096, !12, i64 4120, !42, i64 4128, !34, i64 4176, !7, i64 4180, !7, i64 4181}
!19 = !{!"s2n_timer", !10, i64 0}
!20 = !{!"s2n_secrets", !7, i64 0, !12, i64 388}
!21 = !{!"s2n_kex_parameters", !22, i64 0, !23, i64 8, !7, i64 24, !23, i64 56, !24, i64 72, !24, i64 184, !7, i64 296, !25, i64 360, !26, i64 448, !26, i64 472}
!22 = !{!"s2n_dh_params", !6, i64 0}
!23 = !{!"s2n_ecc_evp_params", !6, i64 0, !6, i64 8}
!24 = !{!"s2n_kem_group_params", !6, i64 0, !25, i64 8, !23, i64 96}
!25 = !{!"s2n_kem_params", !6, i64 0, !26, i64 8, !26, i64 32, !26, i64 56, !14, i64 80}
!26 = !{!"s2n_blob", !6, i64 0, !12, i64 8, !12, i64 12, !12, i64 16}
!27 = !{!"s2n_handshake_parameters", !28, i64 0, !28, i64 48, !26, i64 96, !12, i64 120, !29, i64 124, !6, i64 384, !6, i64 392, !6, i64 400, !7, i64 408, !7, i64 440, !7, i64 472, !7, i64 473, !7, i64 474, !7, i64 506}
!28 = !{!"s2n_pkey", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40}
!29 = !{!"s2n_sig_scheme_list", !7, i64 0, !7, i64 256}
!30 = !{!"s2n_psk_parameters", !12, i64 0, !31, i64 8, !32, i64 40, !32, i64 42, !6, i64 48, !12, i64 56}
!31 = !{!"s2n_array", !26, i64 0, !12, i64 24, !12, i64 28}
!32 = !{!"short", !7, i64 0}
!33 = !{!"s2n_stuffer", !26, i64 0, !12, i64 24, !12, i64 28, !12, i64 32, !12, i64 36, !12, i64 36, !12, i64 36}
!34 = !{!"", !12, i64 0}
!35 = !{!"s2n_handshake", !33, i64 0, !6, i64 40, !7, i64 48, !7, i64 56, !7, i64 104, !7, i64 152, !12, i64 156, !12, i64 160, !12, i64 164, !12, i64 168, !36, i64 176, !12, i64 184, !12, i64 184, !12, i64 184, !12, i64 184, !12, i64 188}
!36 = !{!"s2n_offered_early_data", !6, i64 0}
!37 = !{!"s2n_client_hello", !26, i64 0, !38, i64 24, !26, i64 728, !26, i64 752, !26, i64 776, !7, i64 800, !7, i64 801, !12, i64 802, !12, i64 802, !12, i64 802, !12, i64 802, !12, i64 802, !12, i64 802, !12, i64 802}
!38 = !{!"", !7, i64 0, !26, i64 672, !32, i64 696}
!39 = !{!"s2n_x509_validator", !6, i64 0, !6, i64 8, !7, i64 16, !7, i64 17, !32, i64 18, !6, i64 24, !12, i64 32, !6, i64 40, !40, i64 48, !14, i64 52}
!40 = !{!"s2n_cert_validation_info", !12, i64 0, !12, i64 0}
!41 = !{!"s2n_ticket_fields", !26, i64 0, !12, i64 24}
!42 = !{!"s2n_post_handshake", !33, i64 0, !7, i64 40}
!43 = distinct !{!43, !44}
!44 = !{!"llvm.loop.mustprogress"}
!45 = distinct !{!45, !44}
!46 = !{!7, !7, i64 0}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

@s2n_use_color_in_output = external dso_local local_unnamed_addr global i8, align 1
@stderr = external local_unnamed_addr global ptr, align 8
@.str = external hidden unnamed_addr constant [101 x i8], align 1
@test_count = external dso_local local_unnamed_addr global i32, align 4
@.str.2 = external hidden unnamed_addr constant [88 x i8], align 1
@s2n_errno = external thread_local local_unnamed_addr global i32, align 4
@.str.3 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [90 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [9 x i8], align 1
@SESSION_ID = external hidden constant [33 x i8], align 16
@MSG = external hidden constant [5 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [89 x i8], align 1

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #0

; Function Attrs: mustprogress nofree nosync nounwind willreturn memory(none)
declare ptr @__errno_location() local_unnamed_addr #1

declare i32 @s2n_print_stacktrace(ptr noundef) local_unnamed_addr #2

; Function Attrs: nounwind
declare i32 @isatty(i32 noundef) local_unnamed_addr #3

; Function Attrs: nofree nounwind
declare noundef i32 @fileno(ptr nocapture noundef) local_unnamed_addr #4

; Function Attrs: nofree nounwind
declare noundef i32 @fprintf(ptr nocapture noundef, ptr nocapture noundef readonly, ...) local_unnamed_addr #4

declare ptr @s2n_strerror(i32 noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare nonnull ptr @llvm.threadlocal.address.p0(ptr nonnull) #5

declare ptr @s2n_strerror_debug(i32 noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: nounwind
declare ptr @strerror(i32 noundef) local_unnamed_addr #3

; Function Attrs: noreturn nounwind
declare void @exit(i32 noundef) local_unnamed_addr #6

; Function Attrs: noreturn nounwind uwtable
define dso_local void @mock_client(ptr noundef %0) local_unnamed_addr #7 {
  %2 = alloca [256 x i8], align 16
  %3 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %2) #11
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #11
  %4 = tail call i32 @sleep(i32 noundef 1) #11
  %5 = tail call ptr @s2n_connection_new(i32 noundef 1) #11
  %6 = tail call ptr @s2n_config_new() #11
  %7 = tail call i32 @s2n_config_set_cipher_preferences(ptr noundef %6, ptr noundef nonnull @.str.7) #11
  %8 = tail call i32 @s2n_config_disable_x509_verification(ptr noundef %6) #11
  %9 = tail call i32 @s2n_connection_set_config(ptr noundef %5, ptr noundef %6) #11
  %10 = tail call i32 @s2n_connection_set_io_pair(ptr noundef %5, ptr noundef %0) #11
  %11 = getelementptr inbounds i8, ptr %5, i64 184
  tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(32) %11, ptr noundef nonnull align 16 dereferenceable(32) @SESSION_ID, i64 32, i1 false)
  %12 = getelementptr inbounds i8, ptr %5, i64 216
  store i8 32, ptr %12, align 8, !tbaa !5
  %13 = call i32 @s2n_negotiate(ptr noundef %5, ptr noundef nonnull %3) #11
  %.not = icmp ne i32 %13, 0
  %14 = call zeroext i1 @s2n_handshake_type_check_flag(ptr noundef %5, i32 noundef 2) #11
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %2, i8 0, i64 256, i1 false)
  %15 = call i32 @s2n_connection_get_session_length(ptr noundef %5) #11
  %16 = sext i32 %15 to i64
  %17 = icmp ugt i32 %15, 256
  %18 = call i32 @s2n_connection_get_session(ptr noundef %5, ptr noundef nonnull %2, i64 noundef 1) #11
  %19 = icmp eq i32 %18, 0
  %20 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %21 = load i32, ptr %20, align 4, !tbaa !37
  %.not52 = icmp eq i32 %21, 469762077
  %22 = call i32 @s2n_connection_get_session(ptr noundef %5, ptr noundef nonnull %2, i64 noundef %16) #11
  %.not53 = icmp eq i32 %22, %15
  %bcmp = call i32 @bcmp(ptr noundef nonnull dereferenceable(32) %11, ptr noundef nonnull dereferenceable(32) @SESSION_ID, i64 32)
  %23 = icmp eq i32 %bcmp, 0
  %24 = call i64 @s2n_send(ptr noundef %5, ptr noundef nonnull @MSG, i64 noundef 5, ptr noundef nonnull %3) #11
  %.not54 = icmp eq i64 %24, 5
  br label %25

25:                                               ; preds = %1, %25
  %26 = call i32 @s2n_shutdown(ptr noundef %5, ptr noundef nonnull %3) #11
  %.not55 = icmp eq i32 %26, 0
  br i1 %.not55, label %27, label %25, !llvm.loop !38

27:                                               ; preds = %25
  %28 = call i32 @s2n_connection_free(ptr noundef %5) #11
  %29 = call i32 @sleep(i32 noundef 1) #11
  %30 = call ptr @s2n_connection_new(i32 noundef 1) #11
  %31 = call i32 @s2n_connection_set_io_pair(ptr noundef %30, ptr noundef %0) #11
  %32 = call i32 @s2n_connection_set_session(ptr noundef %30, ptr noundef nonnull %2, i64 noundef %16) #11
  %33 = call i32 @s2n_negotiate(ptr noundef %30, ptr noundef nonnull %3) #11
  %34 = call zeroext i1 @s2n_handshake_type_check_flag(ptr noundef %30, i32 noundef 2) #11
  br i1 %34, label %38, label %35

35:                                               ; preds = %27
  %.050 = zext i1 %.not to i32
  %.151 = select i1 %14, i32 %.050, i32 2
  %.2 = select i1 %17, i32 3, i32 %.151
  %.3 = select i1 %19, i32 4, i32 %.2
  %.4 = select i1 %.not52, i32 %.3, i32 5
  %.5 = select i1 %.not53, i32 %.4, i32 6
  %.6 = select i1 %23, i32 7, i32 %.5
  %.7 = select i1 %.not54, i32 %.6, i32 8
  %.not56 = icmp eq i32 %33, 0
  %36 = icmp slt i32 %32, 0
  %spec.select = select i1 %36, i32 9, i32 %.7
  %.9 = select i1 %.not56, i32 %spec.select, i32 10
  %37 = call zeroext i1 @s2n_handshake_type_check_flag(ptr noundef %30, i32 noundef 1) #11
  br i1 %37, label %39, label %38

38:                                               ; preds = %35, %27
  br label %39

39:                                               ; preds = %38, %35
  %.10 = phi i32 [ 11, %38 ], [ %.9, %35 ]
  %40 = call i64 @s2n_send(ptr noundef %30, ptr noundef nonnull @MSG, i64 noundef 5, ptr noundef nonnull %3) #11
  br label %41

41:                                               ; preds = %39, %41
  %42 = call i32 @s2n_shutdown(ptr noundef %30, ptr noundef nonnull %3) #11
  %.not58 = icmp eq i32 %42, 0
  br i1 %.not58, label %43, label %41, !llvm.loop !40

43:                                               ; preds = %41
  %44 = call i32 @s2n_connection_free(ptr noundef %30) #11
  %45 = call i32 @sleep(i32 noundef 1) #11
  %46 = call ptr @s2n_connection_new(i32 noundef 1) #11
  %47 = load i32, ptr @test_count, align 4, !tbaa !37
  %48 = add nsw i32 %47, 1
  store i32 %48, ptr @test_count, align 4, !tbaa !37
  %49 = call i32 @s2n_connection_set_blinding(ptr noundef %46, i32 noundef 1) #11
  %50 = icmp eq i32 %49, -1
  br i1 %50, label %51, label %74

51:                                               ; preds = %43
  %52 = tail call ptr @__errno_location() #12
  %53 = load i32, ptr %52, align 4, !tbaa !37
  %54 = load ptr, ptr @stderr, align 8, !tbaa !41
  %55 = call i32 @s2n_print_stacktrace(ptr noundef %54) #11
  %56 = load i8, ptr @s2n_use_color_in_output, align 1, !tbaa !42, !range !43, !noundef !44
  %57 = trunc nuw i8 %56 to i1
  br i1 %57, label %58, label %62

58:                                               ; preds = %51
  %59 = load ptr, ptr @stderr, align 8, !tbaa !41
  %60 = call i32 @fileno(ptr noundef %59) #11
  %61 = call i32 @isatty(i32 noundef %60) #11
  %.not61 = icmp eq i32 %61, 0
  br i1 %.not61, label %62, label %63

62:                                               ; preds = %58, %51
  br label %63

63:                                               ; preds = %58, %62
  %.str.4.sink = phi ptr [ @.str.4, %62 ], [ @.str, %58 ]
  store i32 %53, ptr %52, align 4, !tbaa !37
  %64 = load ptr, ptr @stderr, align 8, !tbaa !41
  %65 = load i32, ptr @test_count, align 4, !tbaa !37
  %66 = load i32, ptr %20, align 4, !tbaa !37
  %67 = call ptr @s2n_strerror(i32 noundef %66, ptr noundef nonnull @.str.3) #11
  %68 = load i32, ptr %20, align 4, !tbaa !37
  %69 = call ptr @s2n_strerror_debug(i32 noundef %68, ptr noundef nonnull @.str.3) #11
  %70 = load i32, ptr %52, align 4, !tbaa !37
  %71 = call ptr @strerror(i32 noundef %70) #11
  %72 = load i32, ptr %52, align 4, !tbaa !37
  %73 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %64, ptr noundef nonnull %.str.4.sink, i32 noundef %65, ptr noundef nonnull @.str.9, ptr noundef nonnull @.str.2, i32 noundef 248, ptr noundef %67, ptr noundef %69, ptr noundef %71, i32 noundef %72) #13
  call void @exit(i32 noundef 1) #14
  unreachable

74:                                               ; preds = %43
  %.not57 = icmp eq i64 %40, 5
  %spec.select62 = select i1 %.not57, i32 %.10, i32 12
  %75 = call i32 @s2n_connection_set_io_pair(ptr noundef %46, ptr noundef %0) #11
  store i8 3, ptr %2, align 16, !tbaa !45
  %76 = call i32 @s2n_connection_set_session(ptr noundef %46, ptr noundef nonnull %2, i64 noundef %16) #11
  %77 = icmp eq i32 %76, 0
  %spec.select63 = select i1 %77, i32 13, i32 %spec.select62
  %78 = load i32, ptr %20, align 4, !tbaa !37
  %.not59 = icmp eq i32 %78, 469762076
  %.13 = select i1 %.not59, i32 %spec.select63, i32 14
  store i8 0, ptr %2, align 16, !tbaa !45
  %79 = icmp ult i32 %15, 36
  %.14 = select i1 %79, i32 15, i32 %.13
  %80 = getelementptr inbounds i8, ptr %2, i64 35
  store i8 30, ptr %80, align 1, !tbaa !45
  %81 = call i32 @s2n_connection_set_session(ptr noundef %46, ptr noundef nonnull %2, i64 noundef %16) #11
  %82 = icmp slt i32 %81, 0
  %.15 = select i1 %82, i32 16, i32 %.14
  %83 = call i32 @s2n_negotiate(ptr noundef %46, ptr noundef nonnull %3) #11
  %84 = icmp eq i32 %83, 0
  %.16 = select i1 %84, i32 17, i32 %.15
  %85 = load i32, ptr %20, align 4, !tbaa !37
  %.not60 = icmp eq i32 %85, 335544322
  %.17 = select i1 %.not60, i32 %.16, i32 18
  %86 = call i32 @s2n_connection_free(ptr noundef %46) #11
  %87 = call i32 @s2n_config_free(ptr noundef %6) #11
  %88 = call i32 @sleep(i32 noundef 1) #11
  %89 = call i32 @s2n_io_pair_close_one_end(ptr noundef %0, i32 noundef 1) #11
  call void @exit(i32 noundef %.17) #14
  unreachable
}

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #8

declare i32 @sleep(i32 noundef) local_unnamed_addr #2

declare ptr @s2n_connection_new(i32 noundef) local_unnamed_addr #2

declare ptr @s2n_config_new() local_unnamed_addr #2

declare i32 @s2n_config_set_cipher_preferences(ptr noundef, ptr noundef) local_unnamed_addr #2

declare i32 @s2n_config_disable_x509_verification(ptr noundef) local_unnamed_addr #2

declare i32 @s2n_connection_set_config(ptr noundef, ptr noundef) local_unnamed_addr #2

declare i32 @s2n_connection_set_io_pair(ptr noundef, ptr noundef) local_unnamed_addr #2

declare i32 @s2n_negotiate(ptr noundef, ptr noundef) local_unnamed_addr #2

declare zeroext i1 @s2n_handshake_type_check_flag(ptr noundef, i32 noundef) local_unnamed_addr #2

declare i32 @s2n_connection_get_session_length(ptr noundef) local_unnamed_addr #2

declare i32 @s2n_connection_get_session(ptr noundef, ptr noundef, i64 noundef) local_unnamed_addr #2

declare i64 @s2n_send(ptr noundef, ptr noundef, i64 noundef, ptr noundef) local_unnamed_addr #2

declare i32 @s2n_shutdown(ptr noundef, ptr noundef) local_unnamed_addr #2

declare i32 @s2n_connection_free(ptr noundef) local_unnamed_addr #2

declare i32 @s2n_connection_set_session(ptr noundef, ptr noundef, i64 noundef) local_unnamed_addr #2

declare i32 @s2n_connection_set_blinding(ptr noundef, i32 noundef) local_unnamed_addr #2

declare i32 @s2n_config_free(ptr noundef) local_unnamed_addr #2

declare i32 @s2n_io_pair_close_one_end(ptr noundef, i32 noundef) local_unnamed_addr #2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #9

; Function Attrs: nofree nounwind willreturn memory(argmem: read)
declare i32 @bcmp(ptr nocapture, ptr nocapture, i64) local_unnamed_addr #10

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nofree nosync nounwind willreturn memory(none) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { nofree nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { noreturn nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #8 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #9 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #10 = { nofree nounwind willreturn memory(argmem: read) }
attributes #11 = { nounwind }
attributes #12 = { nounwind willreturn memory(none) }
attributes #13 = { cold nounwind }
attributes #14 = { noreturn nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !8, i64 216}
!6 = !{!"s2n_connection", !7, i64 0, !7, i64 0, !7, i64 0, !7, i64 0, !7, i64 0, !7, i64 0, !7, i64 0, !7, i64 0, !7, i64 1, !7, i64 1, !7, i64 1, !7, i64 1, !7, i64 1, !7, i64 1, !7, i64 1, !7, i64 1, !7, i64 2, !7, i64 2, !7, i64 2, !7, i64 2, !7, i64 2, !7, i64 2, !7, i64 2, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !10, i64 72, !8, i64 80, !8, i64 102, !8, i64 124, !7, i64 148, !7, i64 152, !11, i64 160, !12, i64 168, !12, i64 176, !8, i64 184, !8, i64 216, !8, i64 217, !8, i64 218, !8, i64 219, !8, i64 220, !8, i64 221, !8, i64 222, !10, i64 224, !10, i64 232, !13, i64 240, !10, i64 632, !10, i64 640, !14, i64 648, !21, i64 1144, !24, i64 1688, !10, i64 1752, !8, i64 1760, !7, i64 1764, !8, i64 1768, !27, i64 1776, !27, i64 1816, !27, i64 1856, !27, i64 1896, !7, i64 1936, !12, i64 1944, !8, i64 1952, !27, i64 1960, !8, i64 2000, !8, i64 2001, !8, i64 2002, !20, i64 2003, !28, i64 2004, !28, i64 2008, !29, i64 2016, !26, i64 2208, !7, i64 2212, !26, i64 2216, !12, i64 2224, !8, i64 2232, !12, i64 2240, !12, i64 2248, !12, i64 2256, !28, i64 2264, !28, i64 2268, !8, i64 2272, !8, i64 2528, !7, i64 2784, !19, i64 2792, !7, i64 2816, !19, i64 2824, !19, i64 2848, !19, i64 2872, !31, i64 2896, !33, i64 3704, !10, i64 3760, !10, i64 3768, !8, i64 3776, !7, i64 3780, !19, i64 3784, !7, i64 3808, !35, i64 3816, !8, i64 3848, !27, i64 3992, !19, i64 4032, !19, i64 4056, !20, i64 4080, !20, i64 4081, !20, i64 4082, !26, i64 4084, !26, i64 4086, !7, i64 4088, !7, i64 4092, !19, i64 4096, !7, i64 4120, !36, i64 4128, !28, i64 4176, !8, i64 4180, !8, i64 4181}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"s2n_timer", !12, i64 0}
!12 = !{!"long", !8, i64 0}
!13 = !{!"s2n_secrets", !8, i64 0, !7, i64 388}
!14 = !{!"s2n_kex_parameters", !15, i64 0, !16, i64 8, !8, i64 24, !16, i64 56, !17, i64 72, !17, i64 184, !8, i64 296, !18, i64 360, !19, i64 448, !19, i64 472}
!15 = !{!"s2n_dh_params", !10, i64 0}
!16 = !{!"s2n_ecc_evp_params", !10, i64 0, !10, i64 8}
!17 = !{!"s2n_kem_group_params", !10, i64 0, !18, i64 8, !16, i64 96}
!18 = !{!"s2n_kem_params", !10, i64 0, !19, i64 8, !19, i64 32, !19, i64 56, !20, i64 80}
!19 = !{!"s2n_blob", !10, i64 0, !7, i64 8, !7, i64 12, !7, i64 16}
!20 = !{!"_Bool", !8, i64 0}
!21 = !{!"s2n_handshake_parameters", !22, i64 0, !22, i64 48, !19, i64 96, !7, i64 120, !23, i64 124, !10, i64 384, !10, i64 392, !10, i64 400, !8, i64 408, !8, i64 440, !8, i64 472, !8, i64 473, !8, i64 474, !8, i64 506}
!22 = !{!"s2n_pkey", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40}
!23 = !{!"s2n_sig_scheme_list", !8, i64 0, !8, i64 256}
!24 = !{!"s2n_psk_parameters", !7, i64 0, !25, i64 8, !26, i64 40, !26, i64 42, !10, i64 48, !7, i64 56}
!25 = !{!"s2n_array", !19, i64 0, !7, i64 24, !7, i64 28}
!26 = !{!"short", !8, i64 0}
!27 = !{!"s2n_stuffer", !19, i64 0, !7, i64 24, !7, i64 28, !7, i64 32, !7, i64 36, !7, i64 36, !7, i64 36}
!28 = !{!"", !7, i64 0}
!29 = !{!"s2n_handshake", !27, i64 0, !10, i64 40, !8, i64 48, !8, i64 56, !8, i64 104, !8, i64 152, !7, i64 156, !7, i64 160, !7, i64 164, !7, i64 168, !30, i64 176, !7, i64 184, !7, i64 184, !7, i64 184, !7, i64 184, !7, i64 188}
!30 = !{!"s2n_offered_early_data", !10, i64 0}
!31 = !{!"s2n_client_hello", !19, i64 0, !32, i64 24, !19, i64 728, !19, i64 752, !19, i64 776, !8, i64 800, !8, i64 801, !7, i64 802, !7, i64 802, !7, i64 802, !7, i64 802, !7, i64 802, !7, i64 802, !7, i64 802}
!32 = !{!"", !8, i64 0, !19, i64 672, !26, i64 696}
!33 = !{!"s2n_x509_validator", !10, i64 0, !10, i64 8, !8, i64 16, !8, i64 17, !26, i64 18, !10, i64 24, !7, i64 32, !10, i64 40, !34, i64 48, !20, i64 52}
!34 = !{!"s2n_cert_validation_info", !7, i64 0, !7, i64 0}
!35 = !{!"s2n_ticket_fields", !19, i64 0, !7, i64 24}
!36 = !{!"s2n_post_handshake", !27, i64 0, !8, i64 40}
!37 = !{!7, !7, i64 0}
!38 = distinct !{!38, !39}
!39 = !{!"llvm.loop.mustprogress"}
!40 = distinct !{!40, !39}
!41 = !{!10, !10, i64 0}
!42 = !{!20, !20, i64 0}
!43 = !{i8 0, i8 2}
!44 = !{}
!45 = !{!8, !8, i64 0}


; Effective O3 passes: DSEPass,EarlyCSEPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,LoopRotatePass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass,TailCallElimPass