; LLVM IR from aws/s2n-tls :: tests/unit (s2n_server_new_session_ticket_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_debug_info = type { ptr, ptr }
%struct.s2n_result = type { i32 }
%struct.s2n_blob = type { ptr, i32, i32, i8 }
%struct.s2n_session_ticket = type { %struct.s2n_blob, i32 }
%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_post_handshake = type { %struct.s2n_stuffer, [4 x i8] }
%struct.s2n_atomic_flag = type { i32 }
%struct.s2n_config = type { i32, ptr, ptr, %struct.certs_by_type, %struct.s2n_blob, ptr, ptr, ptr, ptr, ptr, ptr, i32, i32, ptr, i64, ptr, i64, i64, ptr, ptr, ptr, ptr, ptr, ptr, i32, i8, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i8, i8, %struct.s2n_x509_trust_store, i16, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, i32, i32, ptr, i32, i32, ptr, ptr, i32, %struct.s2n_blob }
%struct.certs_by_type = type { [4 x ptr] }
%struct.s2n_x509_trust_store = type { ptr, i8 }

@_s2n_debug_info = external thread_local global %struct.s2n_debug_info, align 8
@s2n_errno = external thread_local global i32, align 4
@.str.13 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [106 x i8], align 1

declare i32 @s2n_stuffer_read_uint32(ptr noundef, ptr noundef) #0

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

declare i32 @s2n_stuffer_read_uint16(ptr noundef, ptr noundef) #0

declare i32 @s2n_realloc(ptr noundef, i32 noundef) #0

declare i32 @s2n_stuffer_read(ptr noundef, ptr noundef) #0

declare i32 @s2n_connection_get_session_length(ptr noundef) #0

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

declare i32 @s2n_free(ptr noundef) #0

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

; 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) #3

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

; Function Attrs: nounwind willreturn memory(read)
declare ptr @strrchr(ptr noundef, i32 noundef) #5

declare i32 @s2n_calculate_stacktrace() #0

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

declare i32 @s2n_blob_init(ptr noundef, ptr noundef, i32 noundef) #0

; Function Attrs: nounwind uwtable
declare hidden i32 @s2n_generate_session_secret(ptr noundef, ptr noundef, ptr noundef) #6

; Function Attrs: nounwind uwtable
define dso_local i32 @s2n_tls13_server_nst_recv(ptr noundef %0, ptr noundef %1) #6 {
  %3 = alloca %struct.s2n_result, align 4
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i8, align 1
  %10 = alloca [255 x i8], align 16
  %11 = alloca %struct.s2n_blob, align 8
  %12 = alloca i16, align 2
  %13 = alloca i16, align 2
  %14 = alloca %struct.s2n_blob, align 8
  %15 = alloca %struct.s2n_session_ticket, align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  br label %16

16:                                               ; preds = %2
  %17 = load ptr, ptr %4, align 8, !tbaa !5
  %18 = icmp ne ptr %17, null
  br i1 %18, label %51, label %19

19:                                               ; preds = %16
  br label %20

20:                                               ; preds = %19
  br label %21

21:                                               ; preds = %20
  %22 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %23 = getelementptr inbounds %struct.s2n_debug_info, ptr %22, i32 0, i32 0
  store ptr @.str.13, ptr %23, align 8, !tbaa !9
  %24 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %25 = getelementptr inbounds %struct.s2n_debug_info, ptr %24, i32 0, i32 0
  %26 = load ptr, ptr %25, align 8, !tbaa !9
  %27 = getelementptr inbounds i8, ptr %26, i64 21
  %28 = call ptr @strrchr(ptr noundef %27, i32 noundef 47) #7
  %29 = icmp ne ptr %28, null
  br i1 %29, label %30, label %37

30:                                               ; preds = %21
  %31 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %32 = getelementptr inbounds %struct.s2n_debug_info, ptr %31, i32 0, i32 0
  %33 = load ptr, ptr %32, align 8, !tbaa !9
  %34 = getelementptr inbounds i8, ptr %33, i64 21
  %35 = call ptr @strrchr(ptr noundef %34, i32 noundef 47) #7
  %36 = getelementptr inbounds i8, ptr %35, i64 1
  br label %42

37:                                               ; preds = %21
  %38 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %39 = getelementptr inbounds %struct.s2n_debug_info, ptr %38, i32 0, i32 0
  %40 = load ptr, ptr %39, align 8, !tbaa !9
  %41 = getelementptr inbounds i8, ptr %40, i64 21
  br label %42

42:                                               ; preds = %37, %30
  %43 = phi ptr [ %36, %30 ], [ %41, %37 ]
  %44 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %45 = getelementptr inbounds %struct.s2n_debug_info, ptr %44, i32 0, i32 1
  store ptr %43, ptr %45, align 8, !tbaa !11
  %46 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 402653193, ptr %46, align 4, !tbaa !12
  %47 = call i32 @s2n_calculate_stacktrace()
  br label %48

48:                                               ; preds = %42
  %49 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %49, align 4, !tbaa !14
  br label %513

50:                                               ; No predecessors!
  br label %51

51:                                               ; preds = %50, %16
  br label %52

52:                                               ; preds = %51
  br label %53

53:                                               ; preds = %52
  %54 = load ptr, ptr %5, align 8, !tbaa !5
  %55 = icmp ne ptr %54, null
  br i1 %55, label %88, label %56

56:                                               ; preds = %53
  br label %57

57:                                               ; preds = %56
  br label %58

58:                                               ; preds = %57
  %59 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %60 = getelementptr inbounds %struct.s2n_debug_info, ptr %59, i32 0, i32 0
  store ptr @.str.14, ptr %60, align 8, !tbaa !9
  %61 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %62 = getelementptr inbounds %struct.s2n_debug_info, ptr %61, i32 0, i32 0
  %63 = load ptr, ptr %62, align 8, !tbaa !9
  %64 = getelementptr inbounds i8, ptr %63, i64 21
  %65 = call ptr @strrchr(ptr noundef %64, i32 noundef 47) #7
  %66 = icmp ne ptr %65, null
  br i1 %66, label %67, label %74

67:                                               ; preds = %58
  %68 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %69 = getelementptr inbounds %struct.s2n_debug_info, ptr %68, i32 0, i32 0
  %70 = load ptr, ptr %69, align 8, !tbaa !9
  %71 = getelementptr inbounds i8, ptr %70, i64 21
  %72 = call ptr @strrchr(ptr noundef %71, i32 noundef 47) #7
  %73 = getelementptr inbounds i8, ptr %72, i64 1
  br label %79

74:                                               ; preds = %58
  %75 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %76 = getelementptr inbounds %struct.s2n_debug_info, ptr %75, i32 0, i32 0
  %77 = load ptr, ptr %76, align 8, !tbaa !9
  %78 = getelementptr inbounds i8, ptr %77, i64 21
  br label %79

79:                                               ; preds = %74, %67
  %80 = phi ptr [ %73, %67 ], [ %78, %74 ]
  %81 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %82 = getelementptr inbounds %struct.s2n_debug_info, ptr %81, i32 0, i32 1
  store ptr %80, ptr %82, align 8, !tbaa !11
  %83 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 402653193, ptr %83, align 4, !tbaa !12
  %84 = call i32 @s2n_calculate_stacktrace()
  br label %85

85:                                               ; preds = %79
  %86 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %86, align 4, !tbaa !14
  br label %513

87:                                               ; No predecessors!
  br label %88

88:                                               ; preds = %87, %53
  br label %89

89:                                               ; preds = %88
  br label %90

90:                                               ; preds = %89
  %91 = load ptr, ptr %4, align 8, !tbaa !5
  %92 = getelementptr inbounds %struct.s2n_connection, ptr %91, i32 0, i32 1
  %93 = load ptr, ptr %92, align 8, !tbaa !16
  %94 = icmp ne ptr %93, null
  br i1 %94, label %127, label %95

95:                                               ; preds = %90
  br label %96

96:                                               ; preds = %95
  br label %97

97:                                               ; preds = %96
  %98 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %99 = getelementptr inbounds %struct.s2n_debug_info, ptr %98, i32 0, i32 0
  store ptr @.str.15, ptr %99, align 8, !tbaa !9
  %100 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %101 = getelementptr inbounds %struct.s2n_debug_info, ptr %100, i32 0, i32 0
  %102 = load ptr, ptr %101, align 8, !tbaa !9
  %103 = getelementptr inbounds i8, ptr %102, i64 21
  %104 = call ptr @strrchr(ptr noundef %103, i32 noundef 47) #7
  %105 = icmp ne ptr %104, null
  br i1 %105, label %106, label %113

106:                                              ; preds = %97
  %107 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %108 = getelementptr inbounds %struct.s2n_debug_info, ptr %107, i32 0, i32 0
  %109 = load ptr, ptr %108, align 8, !tbaa !9
  %110 = getelementptr inbounds i8, ptr %109, i64 21
  %111 = call ptr @strrchr(ptr noundef %110, i32 noundef 47) #7
  %112 = getelementptr inbounds i8, ptr %111, i64 1
  br label %118

113:                                              ; preds = %97
  %114 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %115 = getelementptr inbounds %struct.s2n_debug_info, ptr %114, i32 0, i32 0
  %116 = load ptr, ptr %115, align 8, !tbaa !9
  %117 = getelementptr inbounds i8, ptr %116, i64 21
  br label %118

118:                                              ; preds = %113, %106
  %119 = phi ptr [ %112, %106 ], [ %117, %113 ]
  %120 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %121 = getelementptr inbounds %struct.s2n_debug_info, ptr %120, i32 0, i32 1
  store ptr %119, ptr %121, align 8, !tbaa !11
  %122 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 402653193, ptr %122, align 4, !tbaa !12
  %123 = call i32 @s2n_calculate_stacktrace()
  br label %124

124:                                              ; preds = %118
  %125 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %125, align 4, !tbaa !14
  br label %513

126:                                              ; No predecessors!
  br label %127

127:                                              ; preds = %126, %90
  br label %128

128:                                              ; preds = %127
  br label %129

129:                                              ; preds = %128
  %130 = load ptr, ptr %4, align 8, !tbaa !5
  %131 = getelementptr inbounds %struct.s2n_connection, ptr %130, i32 0, i32 23
  %132 = load i8, ptr %131, align 4, !tbaa !43
  %133 = zext i8 %132 to i32
  %134 = icmp sge i32 %133, 34
  br i1 %134, label %167, label %135

135:                                              ; preds = %129
  br label %136

136:                                              ; preds = %135
  br label %137

137:                                              ; preds = %136
  %138 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %139 = getelementptr inbounds %struct.s2n_debug_info, ptr %138, i32 0, i32 0
  store ptr @.str.16, ptr %139, align 8, !tbaa !9
  %140 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %141 = getelementptr inbounds %struct.s2n_debug_info, ptr %140, i32 0, i32 0
  %142 = load ptr, ptr %141, align 8, !tbaa !9
  %143 = getelementptr inbounds i8, ptr %142, i64 21
  %144 = call ptr @strrchr(ptr noundef %143, i32 noundef 47) #7
  %145 = icmp ne ptr %144, null
  br i1 %145, label %146, label %153

146:                                              ; preds = %137
  %147 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %148 = getelementptr inbounds %struct.s2n_debug_info, ptr %147, i32 0, i32 0
  %149 = load ptr, ptr %148, align 8, !tbaa !9
  %150 = getelementptr inbounds i8, ptr %149, i64 21
  %151 = call ptr @strrchr(ptr noundef %150, i32 noundef 47) #7
  %152 = getelementptr inbounds i8, ptr %151, i64 1
  br label %158

153:                                              ; preds = %137
  %154 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %155 = getelementptr inbounds %struct.s2n_debug_info, ptr %154, i32 0, i32 0
  %156 = load ptr, ptr %155, align 8, !tbaa !9
  %157 = getelementptr inbounds i8, ptr %156, i64 21
  br label %158

158:                                              ; preds = %153, %146
  %159 = phi ptr [ %152, %146 ], [ %157, %153 ]
  %160 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %161 = getelementptr inbounds %struct.s2n_debug_info, ptr %160, i32 0, i32 1
  store ptr %159, ptr %161, align 8, !tbaa !11
  %162 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 335544322, ptr %162, align 4, !tbaa !12
  %163 = call i32 @s2n_calculate_stacktrace()
  br label %164

164:                                              ; preds = %158
  %165 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %165, align 4, !tbaa !14
  br label %513

166:                                              ; No predecessors!
  br label %167

167:                                              ; preds = %166, %129
  br label %168

168:                                              ; preds = %167
  br label %169

169:                                              ; preds = %168
  %170 = load ptr, ptr %4, align 8, !tbaa !5
  %171 = getelementptr inbounds %struct.s2n_connection, ptr %170, i32 0, i32 13
  %172 = load i32, ptr %171, align 4, !tbaa !44
  %173 = icmp eq i32 %172, 1
  br i1 %173, label %206, label %174

174:                                              ; preds = %169
  br label %175

175:                                              ; preds = %174
  br label %176

176:                                              ; preds = %175
  %177 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %178 = getelementptr inbounds %struct.s2n_debug_info, ptr %177, i32 0, i32 0
  store ptr @.str.17, ptr %178, align 8, !tbaa !9
  %179 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %180 = getelementptr inbounds %struct.s2n_debug_info, ptr %179, i32 0, i32 0
  %181 = load ptr, ptr %180, align 8, !tbaa !9
  %182 = getelementptr inbounds i8, ptr %181, i64 21
  %183 = call ptr @strrchr(ptr noundef %182, i32 noundef 47) #7
  %184 = icmp ne ptr %183, null
  br i1 %184, label %185, label %192

185:                                              ; preds = %176
  %186 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %187 = getelementptr inbounds %struct.s2n_debug_info, ptr %186, i32 0, i32 0
  %188 = load ptr, ptr %187, align 8, !tbaa !9
  %189 = getelementptr inbounds i8, ptr %188, i64 21
  %190 = call ptr @strrchr(ptr noundef %189, i32 noundef 47) #7
  %191 = getelementptr inbounds i8, ptr %190, i64 1
  br label %197

192:                                              ; preds = %176
  %193 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %194 = getelementptr inbounds %struct.s2n_debug_info, ptr %193, i32 0, i32 0
  %195 = load ptr, ptr %194, align 8, !tbaa !9
  %196 = getelementptr inbounds i8, ptr %195, i64 21
  br label %197

197:                                              ; preds = %192, %185
  %198 = phi ptr [ %191, %185 ], [ %196, %192 ]
  %199 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %200 = getelementptr inbounds %struct.s2n_debug_info, ptr %199, i32 0, i32 1
  store ptr %198, ptr %200, align 8, !tbaa !11
  %201 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 335544322, ptr %201, align 4, !tbaa !12
  %202 = call i32 @s2n_calculate_stacktrace()
  br label %203

203:                                              ; preds = %197
  %204 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %204, align 4, !tbaa !14
  br label %513

205:                                              ; No predecessors!
  br label %206

206:                                              ; preds = %205, %169
  br label %207

207:                                              ; preds = %206
  %208 = load ptr, ptr %4, align 8, !tbaa !5
  %209 = getelementptr inbounds %struct.s2n_connection, ptr %208, i32 0, i32 1
  %210 = load ptr, ptr %209, align 8, !tbaa !16
  %211 = load i32, ptr %210, align 8
  %212 = and i32 %211, 1
  %213 = icmp ne i32 %212, 0
  br i1 %213, label %216, label %214

214:                                              ; preds = %207
  %215 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 0, ptr %215, align 4, !tbaa !14
  br label %513

216:                                              ; preds = %207
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #8
  %217 = load ptr, ptr %4, align 8, !tbaa !5
  %218 = getelementptr inbounds %struct.s2n_connection, ptr %217, i32 0, i32 79
  store ptr %218, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #8
  store i32 0, ptr %7, align 4, !tbaa !12
  br label %219

219:                                              ; preds = %216
  %220 = load ptr, ptr %5, align 8, !tbaa !5
  %221 = call i32 @s2n_stuffer_read_uint32(ptr noundef %220, ptr noundef %7)
  %222 = icmp sgt i32 %221, -1
  br i1 %222, label %225, label %223

223:                                              ; preds = %219
  %224 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %224, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %512

225:                                              ; preds = %219
  br label %226

226:                                              ; preds = %225
  br label %227

227:                                              ; preds = %226
  br label %228

228:                                              ; preds = %227
  %229 = load i32, ptr %7, align 4, !tbaa !12
  %230 = icmp ule i32 %229, 604800
  br i1 %230, label %265, label %231

231:                                              ; preds = %228
  br label %232

232:                                              ; preds = %231
  br label %233

233:                                              ; preds = %232
  %234 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %235 = getelementptr inbounds %struct.s2n_debug_info, ptr %234, i32 0, i32 0
  store ptr @.str.18, ptr %235, align 8, !tbaa !9
  %236 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %237 = getelementptr inbounds %struct.s2n_debug_info, ptr %236, i32 0, i32 0
  %238 = load ptr, ptr %237, align 8, !tbaa !9
  %239 = getelementptr inbounds i8, ptr %238, i64 21
  %240 = call ptr @strrchr(ptr noundef %239, i32 noundef 47) #7
  %241 = icmp ne ptr %240, null
  br i1 %241, label %242, label %249

242:                                              ; preds = %233
  %243 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %244 = getelementptr inbounds %struct.s2n_debug_info, ptr %243, i32 0, i32 0
  %245 = load ptr, ptr %244, align 8, !tbaa !9
  %246 = getelementptr inbounds i8, ptr %245, i64 21
  %247 = call ptr @strrchr(ptr noundef %246, i32 noundef 47) #7
  %248 = getelementptr inbounds i8, ptr %247, i64 1
  br label %254

249:                                              ; preds = %233
  %250 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %251 = getelementptr inbounds %struct.s2n_debug_info, ptr %250, i32 0, i32 0
  %252 = load ptr, ptr %251, align 8, !tbaa !9
  %253 = getelementptr inbounds i8, ptr %252, i64 21
  br label %254

254:                                              ; preds = %249, %242
  %255 = phi ptr [ %248, %242 ], [ %253, %249 ]
  %256 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %257 = getelementptr inbounds %struct.s2n_debug_info, ptr %256, i32 0, i32 1
  store ptr %255, ptr %257, align 8, !tbaa !11
  %258 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 335544322, ptr %258, align 4, !tbaa !12
  %259 = call i32 @s2n_calculate_stacktrace()
  br label %260

260:                                              ; preds = %254
  br label %261

261:                                              ; preds = %260
  %262 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %262, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %512

263:                                              ; No predecessors!
  br label %264

264:                                              ; preds = %263
  br label %265

265:                                              ; preds = %264, %228
  br label %266

266:                                              ; preds = %265
  br label %267

267:                                              ; preds = %266
  %268 = load i32, ptr %7, align 4, !tbaa !12
  %269 = icmp eq i32 %268, 0
  br i1 %269, label %270, label %272

270:                                              ; preds = %267
  %271 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 0, ptr %271, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %512

272:                                              ; preds = %267
  %273 = load i32, ptr %7, align 4, !tbaa !12
  %274 = load ptr, ptr %4, align 8, !tbaa !5
  %275 = getelementptr inbounds %struct.s2n_connection, ptr %274, i32 0, i32 78
  store i32 %273, ptr %275, align 8, !tbaa !45
  br label %276

276:                                              ; preds = %272
  %277 = load ptr, ptr %5, align 8, !tbaa !5
  %278 = load ptr, ptr %6, align 8, !tbaa !5
  %279 = getelementptr inbounds %struct.s2n_ticket_fields, ptr %278, i32 0, i32 1
  %280 = call i32 @s2n_stuffer_read_uint32(ptr noundef %277, ptr noundef %279)
  %281 = icmp sgt i32 %280, -1
  br i1 %281, label %284, label %282

282:                                              ; preds = %276
  %283 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %283, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %512

284:                                              ; preds = %276
  br label %285

285:                                              ; preds = %284
  br label %286

286:                                              ; preds = %285
  call void @llvm.lifetime.start.p0(i64 1, ptr %9) #8
  store i8 0, ptr %9, align 1, !tbaa !46
  br label %287

287:                                              ; preds = %286
  %288 = load ptr, ptr %5, align 8, !tbaa !5
  %289 = call i32 @s2n_stuffer_read_uint8(ptr noundef %288, ptr noundef %9)
  %290 = icmp sgt i32 %289, -1
  br i1 %290, label %293, label %291

291:                                              ; preds = %287
  %292 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %292, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %511

293:                                              ; preds = %287
  br label %294

294:                                              ; preds = %293
  br label %295

295:                                              ; preds = %294
  call void @llvm.lifetime.start.p0(i64 255, ptr %10) #8
  call void @llvm.memset.p0.i64(ptr align 16 %10, i8 0, i64 255, i1 false)
  call void @llvm.lifetime.start.p0(i64 24, ptr %11) #8
  call void @llvm.memset.p0.i64(ptr align 8 %11, i8 0, i64 24, i1 false)
  br label %296

296:                                              ; preds = %295
  %297 = getelementptr inbounds [255 x i8], ptr %10, i64 0, i64 0
  %298 = load i8, ptr %9, align 1, !tbaa !46
  %299 = zext i8 %298 to i32
  %300 = call i32 @s2n_blob_init(ptr noundef %11, ptr noundef %297, i32 noundef %299)
  %301 = icmp sgt i32 %300, -1
  br i1 %301, label %304, label %302

302:                                              ; preds = %296
  %303 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %303, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %510

304:                                              ; preds = %296
  br label %305

305:                                              ; preds = %304
  br label %306

306:                                              ; preds = %305
  br label %307

307:                                              ; preds = %306
  %308 = load ptr, ptr %5, align 8, !tbaa !5
  %309 = getelementptr inbounds %struct.s2n_blob, ptr %11, i32 0, i32 0
  %310 = load ptr, ptr %309, align 8, !tbaa !47
  %311 = load i8, ptr %9, align 1, !tbaa !46
  %312 = zext i8 %311 to i32
  %313 = call i32 @s2n_stuffer_read_bytes(ptr noundef %308, ptr noundef %310, i32 noundef %312)
  %314 = icmp sgt i32 %313, -1
  br i1 %314, label %317, label %315

315:                                              ; preds = %307
  %316 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %316, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %510

317:                                              ; preds = %307
  br label %318

318:                                              ; preds = %317
  br label %319

319:                                              ; preds = %318
  br label %320

320:                                              ; preds = %319
  %321 = load ptr, ptr %4, align 8, !tbaa !5
  %322 = load ptr, ptr %6, align 8, !tbaa !5
  %323 = getelementptr inbounds %struct.s2n_ticket_fields, ptr %322, i32 0, i32 0
  %324 = call i32 @s2n_generate_session_secret(ptr noundef %321, ptr noundef %11, ptr noundef %323)
  %325 = icmp sgt i32 %324, -1
  br i1 %325, label %328, label %326

326:                                              ; preds = %320
  %327 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %327, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %510

328:                                              ; preds = %320
  br label %329

329:                                              ; preds = %328
  br label %330

330:                                              ; preds = %329
  call void @llvm.lifetime.start.p0(i64 2, ptr %12) #8
  store i16 0, ptr %12, align 2, !tbaa !48
  br label %331

331:                                              ; preds = %330
  %332 = load ptr, ptr %5, align 8, !tbaa !5
  %333 = call i32 @s2n_stuffer_read_uint16(ptr noundef %332, ptr noundef %12)
  %334 = icmp sgt i32 %333, -1
  br i1 %334, label %337, label %335

335:                                              ; preds = %331
  %336 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %336, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %509

337:                                              ; preds = %331
  br label %338

338:                                              ; preds = %337
  br label %339

339:                                              ; preds = %338
  br label %340

340:                                              ; preds = %339
  %341 = load i16, ptr %12, align 2, !tbaa !48
  %342 = zext i16 %341 to i32
  %343 = icmp sgt i32 %342, 0
  br i1 %343, label %378, label %344

344:                                              ; preds = %340
  br label %345

345:                                              ; preds = %344
  br label %346

346:                                              ; preds = %345
  %347 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %348 = getelementptr inbounds %struct.s2n_debug_info, ptr %347, i32 0, i32 0
  store ptr @.str.19, ptr %348, align 8, !tbaa !9
  %349 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %350 = getelementptr inbounds %struct.s2n_debug_info, ptr %349, i32 0, i32 0
  %351 = load ptr, ptr %350, align 8, !tbaa !9
  %352 = getelementptr inbounds i8, ptr %351, i64 21
  %353 = call ptr @strrchr(ptr noundef %352, i32 noundef 47) #7
  %354 = icmp ne ptr %353, null
  br i1 %354, label %355, label %362

355:                                              ; preds = %346
  %356 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %357 = getelementptr inbounds %struct.s2n_debug_info, ptr %356, i32 0, i32 0
  %358 = load ptr, ptr %357, align 8, !tbaa !9
  %359 = getelementptr inbounds i8, ptr %358, i64 21
  %360 = call ptr @strrchr(ptr noundef %359, i32 noundef 47) #7
  %361 = getelementptr inbounds i8, ptr %360, i64 1
  br label %367

362:                                              ; preds = %346
  %363 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %364 = getelementptr inbounds %struct.s2n_debug_info, ptr %363, i32 0, i32 0
  %365 = load ptr, ptr %364, align 8, !tbaa !9
  %366 = getelementptr inbounds i8, ptr %365, i64 21
  br label %367

367:                                              ; preds = %362, %355
  %368 = phi ptr [ %361, %355 ], [ %366, %362 ]
  %369 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %370 = getelementptr inbounds %struct.s2n_debug_info, ptr %369, i32 0, i32 1
  store ptr %368, ptr %370, align 8, !tbaa !11
  %371 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 402653194, ptr %371, align 4, !tbaa !12
  %372 = call i32 @s2n_calculate_stacktrace()
  br label %373

373:                                              ; preds = %367
  br label %374

374:                                              ; preds = %373
  %375 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %375, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %509

376:                                              ; No predecessors!
  br label %377

377:                                              ; preds = %376
  br label %378

378:                                              ; preds = %377, %340
  br label %379

379:                                              ; preds = %378
  br label %380

380:                                              ; preds = %379
  br label %381

381:                                              ; preds = %380
  %382 = load ptr, ptr %4, align 8, !tbaa !5
  %383 = getelementptr inbounds %struct.s2n_connection, ptr %382, i32 0, i32 77
  %384 = load i16, ptr %12, align 2, !tbaa !48
  %385 = zext i16 %384 to i32
  %386 = call i32 @s2n_realloc(ptr noundef %383, i32 noundef %385)
  %387 = icmp sgt i32 %386, -1
  br i1 %387, label %390, label %388

388:                                              ; preds = %381
  %389 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %389, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %509

390:                                              ; preds = %381
  br label %391

391:                                              ; preds = %390
  br label %392

392:                                              ; preds = %391
  br label %393

393:                                              ; preds = %392
  %394 = load ptr, ptr %5, align 8, !tbaa !5
  %395 = load ptr, ptr %4, align 8, !tbaa !5
  %396 = getelementptr inbounds %struct.s2n_connection, ptr %395, i32 0, i32 77
  %397 = call i32 @s2n_stuffer_read(ptr noundef %394, ptr noundef %396)
  %398 = icmp sgt i32 %397, -1
  br i1 %398, label %401, label %399

399:                                              ; preds = %393
  %400 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %400, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %509

401:                                              ; preds = %393
  br label %402

402:                                              ; preds = %401
  br label %403

403:                                              ; preds = %402
  br label %404

404:                                              ; preds = %403
  %405 = load ptr, ptr %4, align 8, !tbaa !5
  %406 = load ptr, ptr %5, align 8, !tbaa !5
  %407 = call i32 @s2n_extension_list_recv(i32 noundef 7, ptr noundef %405, ptr noundef %406)
  %408 = icmp sgt i32 %407, -1
  br i1 %408, label %411, label %409

409:                                              ; preds = %404
  %410 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %410, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %509

411:                                              ; preds = %404
  br label %412

412:                                              ; preds = %411
  br label %413

413:                                              ; preds = %412
  %414 = load ptr, ptr %4, align 8, !tbaa !5
  %415 = getelementptr inbounds %struct.s2n_connection, ptr %414, i32 0, i32 1
  %416 = load ptr, ptr %415, align 8, !tbaa !16
  %417 = getelementptr inbounds %struct.s2n_config, ptr %416, i32 0, i32 44
  %418 = load ptr, ptr %417, align 8, !tbaa !49
  %419 = icmp ne ptr %418, null
  br i1 %419, label %420, label %507

420:                                              ; preds = %413
  call void @llvm.lifetime.start.p0(i64 2, ptr %13) #8
  %421 = load ptr, ptr %4, align 8, !tbaa !5
  %422 = call i32 @s2n_connection_get_session_length(ptr noundef %421)
  %423 = trunc i32 %422 to i16
  store i16 %423, ptr %13, align 2, !tbaa !48
  call void @llvm.lifetime.start.p0(i64 24, ptr %14) #8
  call void @llvm.memset.p0.i64(ptr align 8 %14, i8 0, i64 24, i1 false)
  br label %424

424:                                              ; preds = %420
  %425 = load i16, ptr %13, align 2, !tbaa !48
  %426 = zext i16 %425 to i32
  %427 = call i32 @s2n_realloc(ptr noundef %14, i32 noundef %426)
  %428 = icmp sgt i32 %427, -1
  br i1 %428, label %431, label %429

429:                                              ; preds = %424
  %430 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %430, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %503

431:                                              ; preds = %424
  br label %432

432:                                              ; preds = %431
  br label %433

433:                                              ; preds = %432
  br label %434

434:                                              ; preds = %433
  %435 = load ptr, ptr %4, align 8, !tbaa !5
  %436 = getelementptr inbounds %struct.s2n_blob, ptr %14, i32 0, i32 0
  %437 = load ptr, ptr %436, align 8, !tbaa !47
  %438 = getelementptr inbounds %struct.s2n_blob, ptr %14, i32 0, i32 1
  %439 = load i32, ptr %438, align 8, !tbaa !53
  %440 = zext i32 %439 to i64
  %441 = call i32 @s2n_connection_get_session(ptr noundef %435, ptr noundef %437, i64 noundef %440)
  %442 = icmp sgt i32 %441, -1
  br i1 %442, label %445, label %443

443:                                              ; preds = %434
  %444 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %444, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %503

445:                                              ; preds = %434
  br label %446

446:                                              ; preds = %445
  br label %447

447:                                              ; preds = %446
  call void @llvm.lifetime.start.p0(i64 32, ptr %15) #8
  %448 = getelementptr inbounds %struct.s2n_session_ticket, ptr %15, i32 0, i32 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %448, ptr align 8 %14, i64 24, i1 false), !tbaa.struct !54
  %449 = getelementptr inbounds %struct.s2n_session_ticket, ptr %15, i32 0, i32 1
  %450 = load i32, ptr %7, align 4, !tbaa !12
  store i32 %450, ptr %449, align 8, !tbaa !55
  br label %451

451:                                              ; preds = %447
  %452 = load ptr, ptr %4, align 8, !tbaa !5
  %453 = getelementptr inbounds %struct.s2n_connection, ptr %452, i32 0, i32 1
  %454 = load ptr, ptr %453, align 8, !tbaa !16
  %455 = getelementptr inbounds %struct.s2n_config, ptr %454, i32 0, i32 44
  %456 = load ptr, ptr %455, align 8, !tbaa !49
  %457 = load ptr, ptr %4, align 8, !tbaa !5
  %458 = load ptr, ptr %4, align 8, !tbaa !5
  %459 = getelementptr inbounds %struct.s2n_connection, ptr %458, i32 0, i32 1
  %460 = load ptr, ptr %459, align 8, !tbaa !16
  %461 = getelementptr inbounds %struct.s2n_config, ptr %460, i32 0, i32 45
  %462 = load ptr, ptr %461, align 8, !tbaa !57
  %463 = call i32 %456(ptr noundef %457, ptr noundef %462, ptr noundef %15)
  %464 = icmp sge i32 %463, 0
  br i1 %464, label %499, label %465

465:                                              ; preds = %451
  br label %466

466:                                              ; preds = %465
  br label %467

467:                                              ; preds = %466
  %468 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %469 = getelementptr inbounds %struct.s2n_debug_info, ptr %468, i32 0, i32 0
  store ptr @.str.20, ptr %469, align 8, !tbaa !9
  %470 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %471 = getelementptr inbounds %struct.s2n_debug_info, ptr %470, i32 0, i32 0
  %472 = load ptr, ptr %471, align 8, !tbaa !9
  %473 = getelementptr inbounds i8, ptr %472, i64 21
  %474 = call ptr @strrchr(ptr noundef %473, i32 noundef 47) #7
  %475 = icmp ne ptr %474, null
  br i1 %475, label %476, label %483

476:                                              ; preds = %467
  %477 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %478 = getelementptr inbounds %struct.s2n_debug_info, ptr %477, i32 0, i32 0
  %479 = load ptr, ptr %478, align 8, !tbaa !9
  %480 = getelementptr inbounds i8, ptr %479, i64 21
  %481 = call ptr @strrchr(ptr noundef %480, i32 noundef 47) #7
  %482 = getelementptr inbounds i8, ptr %481, i64 1
  br label %488

483:                                              ; preds = %467
  %484 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %485 = getelementptr inbounds %struct.s2n_debug_info, ptr %484, i32 0, i32 0
  %486 = load ptr, ptr %485, align 8, !tbaa !9
  %487 = getelementptr inbounds i8, ptr %486, i64 21
  br label %488

488:                                              ; preds = %483, %476
  %489 = phi ptr [ %482, %476 ], [ %487, %483 ]
  %490 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  %491 = getelementptr inbounds %struct.s2n_debug_info, ptr %490, i32 0, i32 1
  store ptr %489, ptr %491, align 8, !tbaa !11
  %492 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 335544386, ptr %492, align 4, !tbaa !12
  %493 = call i32 @s2n_calculate_stacktrace()
  br label %494

494:                                              ; preds = %488
  br label %495

495:                                              ; preds = %494
  %496 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 -1, ptr %496, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %502

497:                                              ; No predecessors!
  br label %498

498:                                              ; preds = %497
  br label %499

499:                                              ; preds = %498, %451
  br label %500

500:                                              ; preds = %499
  br label %501

501:                                              ; preds = %500
  store i32 0, ptr %8, align 4
  br label %502

502:                                              ; preds = %501, %495
  call void @llvm.lifetime.end.p0(i64 32, ptr %15) #8
  br label %503

503:                                              ; preds = %502, %443, %429
  %504 = call i32 @s2n_free(ptr noundef %14)
  call void @llvm.lifetime.end.p0(i64 24, ptr %14) #8
  call void @llvm.lifetime.end.p0(i64 2, ptr %13) #8
  %505 = load i32, ptr %8, align 4
  switch i32 %505, label %509 [
    i32 0, label %506
  ]

506:                                              ; preds = %503
  br label %507

507:                                              ; preds = %506, %413
  %508 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  store i32 0, ptr %508, align 4, !tbaa !14
  store i32 1, ptr %8, align 4
  br label %509

509:                                              ; preds = %507, %503, %409, %399, %388, %374, %335
  call void @llvm.lifetime.end.p0(i64 2, ptr %12) #8
  br label %510

510:                                              ; preds = %509, %326, %315, %302
  call void @llvm.lifetime.end.p0(i64 24, ptr %11) #8
  call void @llvm.lifetime.end.p0(i64 255, ptr %10) #8
  br label %511

511:                                              ; preds = %510, %291
  call void @llvm.lifetime.end.p0(i64 1, ptr %9) #8
  br label %512

512:                                              ; preds = %511, %282, %270, %261, %223
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #8
  br label %513

513:                                              ; preds = %512, %214, %203, %164, %124, %85, %48
  %514 = getelementptr inbounds %struct.s2n_result, ptr %3, i32 0, i32 0
  %515 = load i32, ptr %514, align 4
  ret i32 %515
}

declare i32 @s2n_stuffer_read_uint8(ptr noundef, ptr noundef) #0

declare i32 @s2n_stuffer_read_bytes(ptr noundef, ptr noundef, i32 noundef) #0

declare i32 @s2n_extension_list_recv(i32 noundef, ptr noundef, ptr noundef) #0

attributes #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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #3 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #5 = { 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 #6 = { 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 #7 = { nounwind willreturn memory(read) }
attributes #8 = { 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, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !6, i64 0}
!10 = !{!"s2n_debug_info", !6, i64 0, !6, i64 8}
!11 = !{!10, !6, i64 8}
!12 = !{!13, !13, i64 0}
!13 = !{!"int", !7, i64 0}
!14 = !{!15, !13, i64 0}
!15 = !{!"", !13, i64 0}
!16 = !{!17, !6, i64 8}
!17 = !{!"s2n_connection", !13, i64 0, !13, i64 0, !13, i64 0, !13, i64 0, !13, i64 0, !13, i64 0, !13, i64 0, !13, i64 0, !13, i64 1, !13, i64 1, !13, i64 1, !13, i64 1, !13, i64 1, !13, i64 1, !13, i64 1, !13, i64 1, !13, i64 2, !13, i64 2, !13, i64 2, !13, i64 2, !13, i64 2, !13, i64 2, !13, 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, !13, i64 148, !13, i64 152, !18, i64 160, !19, i64 168, !19, 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, !28, i64 1144, !31, i64 1688, !6, i64 1752, !7, i64 1760, !13, i64 1764, !7, i64 1768, !34, i64 1776, !34, i64 1816, !34, i64 1856, !34, i64 1896, !13, i64 1936, !19, i64 1944, !7, i64 1952, !34, i64 1960, !7, i64 2000, !7, i64 2001, !7, i64 2002, !27, i64 2003, !15, i64 2004, !15, i64 2008, !35, i64 2016, !33, i64 2208, !13, i64 2212, !33, i64 2216, !19, i64 2224, !7, i64 2232, !19, i64 2240, !19, i64 2248, !19, i64 2256, !15, i64 2264, !15, i64 2268, !7, i64 2272, !7, i64 2528, !13, i64 2784, !26, i64 2792, !13, 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, !13, i64 3780, !26, i64 3784, !13, i64 3808, !41, i64 3816, !7, i64 3848, !34, i64 3992, !26, i64 4032, !26, i64 4056, !27, i64 4080, !27, i64 4081, !27, i64 4082, !33, i64 4084, !33, i64 4086, !13, i64 4088, !13, i64 4092, !26, i64 4096, !13, i64 4120, !42, i64 4128, !15, i64 4176, !7, i64 4180, !7, i64 4181}
!18 = !{!"s2n_timer", !19, i64 0}
!19 = !{!"long", !7, i64 0}
!20 = !{!"s2n_secrets", !7, i64 0, !13, 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, !27, i64 80}
!26 = !{!"s2n_blob", !6, i64 0, !13, i64 8, !13, i64 12, !13, i64 16}
!27 = !{!"_Bool", !7, i64 0}
!28 = !{!"s2n_handshake_parameters", !29, i64 0, !29, i64 48, !26, i64 96, !13, i64 120, !30, 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}
!29 = !{!"s2n_pkey", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40}
!30 = !{!"s2n_sig_scheme_list", !7, i64 0, !7, i64 256}
!31 = !{!"s2n_psk_parameters", !13, i64 0, !32, i64 8, !33, i64 40, !33, i64 42, !6, i64 48, !13, i64 56}
!32 = !{!"s2n_array", !26, i64 0, !13, i64 24, !13, i64 28}
!33 = !{!"short", !7, i64 0}
!34 = !{!"s2n_stuffer", !26, i64 0, !13, i64 24, !13, i64 28, !13, i64 32, !13, i64 36, !13, i64 36, !13, i64 36}
!35 = !{!"s2n_handshake", !34, i64 0, !6, i64 40, !7, i64 48, !7, i64 56, !7, i64 104, !7, i64 152, !13, i64 156, !13, i64 160, !13, i64 164, !13, i64 168, !36, i64 176, !13, i64 184, !13, i64 184, !13, i64 184, !13, i64 184, !13, 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, !13, i64 802, !13, i64 802, !13, i64 802, !13, i64 802, !13, i64 802, !13, i64 802, !13, i64 802}
!38 = !{!"", !7, i64 0, !26, i64 672, !33, i64 696}
!39 = !{!"s2n_x509_validator", !6, i64 0, !6, i64 8, !7, i64 16, !7, i64 17, !33, i64 18, !6, i64 24, !13, i64 32, !6, i64 40, !40, i64 48, !27, i64 52}
!40 = !{!"s2n_cert_validation_info", !13, i64 0, !13, i64 0}
!41 = !{!"s2n_ticket_fields", !26, i64 0, !13, i64 24}
!42 = !{!"s2n_post_handshake", !34, i64 0, !7, i64 40}
!43 = !{!17, !7, i64 220}
!44 = !{!17, !13, i64 148}
!45 = !{!17, !13, i64 3808}
!46 = !{!7, !7, i64 0}
!47 = !{!26, !6, i64 0}
!48 = !{!33, !33, i64 0}
!49 = !{!50, !6, i64 368}
!50 = !{!"s2n_config", !13, i64 0, !13, i64 0, !13, i64 0, !13, i64 0, !13, i64 0, !13, i64 0, !13, i64 0, !13, i64 0, !13, i64 1, !13, i64 1, !13, i64 1, !13, i64 1, !13, i64 1, !13, i64 1, !13, i64 1, !13, i64 1, !13, i64 2, !13, i64 2, !13, i64 2, !13, i64 2, !6, i64 8, !6, i64 16, !51, i64 24, !26, i64 56, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120, !13, i64 128, !13, i64 132, !6, i64 136, !19, i64 144, !6, i64 152, !19, i64 160, !19, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !6, i64 208, !6, i64 216, !13, i64 224, !7, i64 228, !13, i64 232, !13, i64 236, !6, i64 240, !6, i64 248, !6, i64 256, !6, i64 264, !6, i64 272, !6, i64 280, !6, i64 288, !7, i64 296, !7, i64 297, !52, i64 304, !33, i64 320, !6, i64 328, !6, i64 336, !6, i64 344, !6, i64 352, !6, i64 360, !6, i64 368, !6, i64 376, !6, i64 384, !13, i64 392, !13, i64 396, !13, i64 400, !6, i64 408, !13, i64 416, !13, i64 420, !6, i64 424, !6, i64 432, !13, i64 440, !26, i64 448}
!51 = !{!"certs_by_type", !7, i64 0}
!52 = !{!"s2n_x509_trust_store", !6, i64 0, !13, i64 8}
!53 = !{!26, !13, i64 8}
!54 = !{i64 0, i64 8, !5, i64 8, i64 4, !12, i64 12, i64 4, !12, i64 16, i64 1, !46}
!55 = !{!56, !13, i64 24}
!56 = !{!"s2n_session_ticket", !26, i64 0, !13, i64 24}
!57 = !{!50, !6, i64 376}


; 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"

%struct.s2n_debug_info = type { ptr, ptr }
%struct.s2n_blob = type { ptr, i32, i32, i8 }
%struct.s2n_session_ticket = type { %struct.s2n_blob, i32 }

@_s2n_debug_info = external thread_local local_unnamed_addr global %struct.s2n_debug_info, align 8
@s2n_errno = external thread_local local_unnamed_addr global i32, align 4
@.str.13 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [106 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [106 x i8], align 1

declare i32 @s2n_stuffer_read_uint32(ptr noundef, ptr noundef) local_unnamed_addr #0

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

declare i32 @s2n_stuffer_read_uint16(ptr noundef, ptr noundef) local_unnamed_addr #0

declare i32 @s2n_realloc(ptr noundef, i32 noundef) local_unnamed_addr #0

declare i32 @s2n_stuffer_read(ptr noundef, ptr noundef) local_unnamed_addr #0

declare i32 @s2n_connection_get_session_length(ptr noundef) local_unnamed_addr #0

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

declare i32 @s2n_free(ptr noundef) local_unnamed_addr #0

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

; Function Attrs: mustprogress 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) #3

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

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: read)
declare ptr @strrchr(ptr noundef, i32 noundef) local_unnamed_addr #5

declare i32 @s2n_calculate_stacktrace() local_unnamed_addr #0

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

declare i32 @s2n_blob_init(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
declare hidden i32 @s2n_generate_session_secret(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #6

; Function Attrs: nounwind uwtable
define dso_local range(i32 -1, 1) i32 @s2n_tls13_server_nst_recv(ptr noundef %0, ptr noundef %1) local_unnamed_addr #6 {
  %3 = alloca i32, align 4
  %4 = alloca i8, align 1
  %5 = alloca [255 x i8], align 16
  %6 = alloca %struct.s2n_blob, align 8
  %7 = alloca i16, align 2
  %8 = alloca %struct.s2n_blob, align 8
  %9 = alloca %struct.s2n_session_ticket, align 8
  %.not = icmp eq ptr %0, null
  br i1 %.not, label %10, label %18

10:                                               ; preds = %2
  %11 = tail call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  store ptr @.str.13, ptr %11, align 8, !tbaa !5
  %12 = tail call ptr @strrchr(ptr noundef nonnull dereferenceable(1) getelementptr inbounds (i8, ptr @.str.13, i64 21), i32 noundef 47) #7
  %.not41 = icmp eq ptr %12, null
  %13 = getelementptr inbounds i8, ptr %12, i64 1
  %14 = select i1 %.not41, ptr getelementptr inbounds (i8, ptr @.str.13, i64 21), ptr %13
  %15 = getelementptr inbounds i8, ptr %11, i64 8
  store ptr %14, ptr %15, align 8, !tbaa !10
  %16 = tail call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 402653193, ptr %16, align 4, !tbaa !11
  %17 = tail call i32 @s2n_calculate_stacktrace() #8
  br label %169

18:                                               ; preds = %2
  %.not42 = icmp eq ptr %1, null
  br i1 %.not42, label %19, label %27

19:                                               ; preds = %18
  %20 = tail call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  store ptr @.str.14, ptr %20, align 8, !tbaa !5
  %21 = tail call ptr @strrchr(ptr noundef nonnull dereferenceable(1) getelementptr inbounds (i8, ptr @.str.14, i64 21), i32 noundef 47) #7
  %.not43 = icmp eq ptr %21, null
  %22 = getelementptr inbounds i8, ptr %21, i64 1
  %23 = select i1 %.not43, ptr getelementptr inbounds (i8, ptr @.str.14, i64 21), ptr %22
  %24 = getelementptr inbounds i8, ptr %20, i64 8
  store ptr %23, ptr %24, align 8, !tbaa !10
  %25 = tail call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 402653193, ptr %25, align 4, !tbaa !11
  %26 = tail call i32 @s2n_calculate_stacktrace() #8
  br label %169

27:                                               ; preds = %18
  %28 = getelementptr inbounds i8, ptr %0, i64 8
  %29 = load ptr, ptr %28, align 8, !tbaa !13
  %.not44 = icmp eq ptr %29, null
  br i1 %.not44, label %30, label %38

30:                                               ; preds = %27
  %31 = tail call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  store ptr @.str.15, ptr %31, align 8, !tbaa !5
  %32 = tail call ptr @strrchr(ptr noundef nonnull dereferenceable(1) getelementptr inbounds (i8, ptr @.str.15, i64 21), i32 noundef 47) #7
  %.not45 = icmp eq ptr %32, null
  %33 = getelementptr inbounds i8, ptr %32, i64 1
  %34 = select i1 %.not45, ptr getelementptr inbounds (i8, ptr @.str.15, i64 21), ptr %33
  %35 = getelementptr inbounds i8, ptr %31, i64 8
  store ptr %34, ptr %35, align 8, !tbaa !10
  %36 = tail call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 402653193, ptr %36, align 4, !tbaa !11
  %37 = tail call i32 @s2n_calculate_stacktrace() #8
  br label %169

38:                                               ; preds = %27
  %39 = getelementptr inbounds i8, ptr %0, i64 220
  %40 = load i8, ptr %39, align 4, !tbaa !41
  %41 = icmp ugt i8 %40, 33
  br i1 %41, label %50, label %42

42:                                               ; preds = %38
  %43 = tail call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  store ptr @.str.16, ptr %43, align 8, !tbaa !5
  %44 = tail call ptr @strrchr(ptr noundef nonnull dereferenceable(1) getelementptr inbounds (i8, ptr @.str.16, i64 21), i32 noundef 47) #7
  %.not46 = icmp eq ptr %44, null
  %45 = getelementptr inbounds i8, ptr %44, i64 1
  %46 = select i1 %.not46, ptr getelementptr inbounds (i8, ptr @.str.16, i64 21), ptr %45
  %47 = getelementptr inbounds i8, ptr %43, i64 8
  store ptr %46, ptr %47, align 8, !tbaa !10
  %48 = tail call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 335544322, ptr %48, align 4, !tbaa !11
  %49 = tail call i32 @s2n_calculate_stacktrace() #8
  br label %169

50:                                               ; preds = %38
  %51 = getelementptr inbounds i8, ptr %0, i64 148
  %52 = load i32, ptr %51, align 4, !tbaa !42
  %53 = icmp eq i32 %52, 1
  br i1 %53, label %62, label %54

54:                                               ; preds = %50
  %55 = tail call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  store ptr @.str.17, ptr %55, align 8, !tbaa !5
  %56 = tail call ptr @strrchr(ptr noundef nonnull dereferenceable(1) getelementptr inbounds (i8, ptr @.str.17, i64 21), i32 noundef 47) #7
  %.not47 = icmp eq ptr %56, null
  %57 = getelementptr inbounds i8, ptr %56, i64 1
  %58 = select i1 %.not47, ptr getelementptr inbounds (i8, ptr @.str.17, i64 21), ptr %57
  %59 = getelementptr inbounds i8, ptr %55, i64 8
  store ptr %58, ptr %59, align 8, !tbaa !10
  %60 = tail call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 335544322, ptr %60, align 4, !tbaa !11
  %61 = tail call i32 @s2n_calculate_stacktrace() #8
  br label %169

62:                                               ; preds = %50
  %63 = load i32, ptr %29, align 8
  %64 = and i32 %63, 1
  %.not48 = icmp eq i32 %64, 0
  br i1 %.not48, label %169, label %65

65:                                               ; preds = %62
  %66 = getelementptr inbounds i8, ptr %0, i64 3816
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #8
  store i32 0, ptr %3, align 4, !tbaa !11
  %67 = call i32 @s2n_stuffer_read_uint32(ptr noundef nonnull %1, ptr noundef nonnull %3) #8
  %68 = icmp sgt i32 %67, -1
  br i1 %68, label %69, label %168

69:                                               ; preds = %65
  %70 = load i32, ptr %3, align 4, !tbaa !11
  %71 = icmp ult i32 %70, 604801
  br i1 %71, label %80, label %72

72:                                               ; preds = %69
  %73 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  store ptr @.str.18, ptr %73, align 8, !tbaa !5
  %74 = call ptr @strrchr(ptr noundef nonnull dereferenceable(1) getelementptr inbounds (i8, ptr @.str.18, i64 21), i32 noundef 47) #7
  %.not49 = icmp eq ptr %74, null
  %75 = getelementptr inbounds i8, ptr %74, i64 1
  %76 = select i1 %.not49, ptr getelementptr inbounds (i8, ptr @.str.18, i64 21), ptr %75
  %77 = getelementptr inbounds i8, ptr %73, i64 8
  store ptr %76, ptr %77, align 8, !tbaa !10
  %78 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 335544322, ptr %78, align 4, !tbaa !11
  %79 = call i32 @s2n_calculate_stacktrace() #8
  br label %168

80:                                               ; preds = %69
  %81 = icmp eq i32 %70, 0
  br i1 %81, label %168, label %82

82:                                               ; preds = %80
  %83 = getelementptr inbounds i8, ptr %0, i64 3808
  store i32 %70, ptr %83, align 8, !tbaa !43
  %84 = getelementptr inbounds i8, ptr %0, i64 3840
  %85 = call i32 @s2n_stuffer_read_uint32(ptr noundef nonnull %1, ptr noundef nonnull %84) #8
  %86 = icmp sgt i32 %85, -1
  br i1 %86, label %87, label %168

87:                                               ; preds = %82
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %4) #8
  store i8 0, ptr %4, align 1, !tbaa !44
  %88 = call i32 @s2n_stuffer_read_uint8(ptr noundef nonnull %1, ptr noundef nonnull %4) #8
  %89 = icmp sgt i32 %88, -1
  br i1 %89, label %90, label %167

90:                                               ; preds = %87
  call void @llvm.lifetime.start.p0(i64 255, ptr nonnull %5) #8
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(255) %5, i8 0, i64 255, i1 false)
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %6) #8
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %6, i8 0, i64 24, i1 false)
  %91 = load i8, ptr %4, align 1, !tbaa !44
  %92 = zext i8 %91 to i32
  %93 = call i32 @s2n_blob_init(ptr noundef nonnull %6, ptr noundef nonnull %5, i32 noundef %92) #8
  %94 = icmp sgt i32 %93, -1
  br i1 %94, label %95, label %166

95:                                               ; preds = %90
  %96 = load ptr, ptr %6, align 8, !tbaa !45
  %97 = load i8, ptr %4, align 1, !tbaa !44
  %98 = zext i8 %97 to i32
  %99 = call i32 @s2n_stuffer_read_bytes(ptr noundef nonnull %1, ptr noundef %96, i32 noundef %98) #8
  %100 = icmp sgt i32 %99, -1
  br i1 %100, label %101, label %166

101:                                              ; preds = %95
  %102 = call i32 @s2n_generate_session_secret(ptr noundef nonnull %0, ptr noundef nonnull %6, ptr noundef nonnull %66)
  %103 = icmp sgt i32 %102, -1
  br i1 %103, label %104, label %166

104:                                              ; preds = %101
  call void @llvm.lifetime.start.p0(i64 2, ptr nonnull %7) #8
  store i16 0, ptr %7, align 2, !tbaa !46
  %105 = call i32 @s2n_stuffer_read_uint16(ptr noundef nonnull %1, ptr noundef nonnull %7) #8
  %106 = icmp sgt i32 %105, -1
  br i1 %106, label %107, label %165

107:                                              ; preds = %104
  %108 = load i16, ptr %7, align 2, !tbaa !46
  %.not50 = icmp eq i16 %108, 0
  br i1 %.not50, label %109, label %117

109:                                              ; preds = %107
  %110 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  store ptr @.str.19, ptr %110, align 8, !tbaa !5
  %111 = call ptr @strrchr(ptr noundef nonnull dereferenceable(1) getelementptr inbounds (i8, ptr @.str.19, i64 21), i32 noundef 47) #7
  %.not51 = icmp eq ptr %111, null
  %112 = getelementptr inbounds i8, ptr %111, i64 1
  %113 = select i1 %.not51, ptr getelementptr inbounds (i8, ptr @.str.19, i64 21), ptr %112
  %114 = getelementptr inbounds i8, ptr %110, i64 8
  store ptr %113, ptr %114, align 8, !tbaa !10
  %115 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 402653194, ptr %115, align 4, !tbaa !11
  %116 = call i32 @s2n_calculate_stacktrace() #8
  br label %165

117:                                              ; preds = %107
  %118 = zext i16 %108 to i32
  %119 = getelementptr inbounds i8, ptr %0, i64 3784
  %120 = call i32 @s2n_realloc(ptr noundef nonnull %119, i32 noundef %118) #8
  %121 = icmp sgt i32 %120, -1
  br i1 %121, label %122, label %165

122:                                              ; preds = %117
  %123 = call i32 @s2n_stuffer_read(ptr noundef nonnull %1, ptr noundef nonnull %119) #8
  %124 = icmp sgt i32 %123, -1
  br i1 %124, label %125, label %165

125:                                              ; preds = %122
  %126 = call i32 @s2n_extension_list_recv(i32 noundef 7, ptr noundef nonnull %0, ptr noundef nonnull %1) #8
  %127 = icmp sgt i32 %126, -1
  br i1 %127, label %128, label %165

128:                                              ; preds = %125
  %129 = load ptr, ptr %28, align 8, !tbaa !13
  %130 = getelementptr inbounds i8, ptr %129, i64 368
  %131 = load ptr, ptr %130, align 8, !tbaa !47
  %.not52 = icmp eq ptr %131, null
  br i1 %.not52, label %165, label %132

132:                                              ; preds = %128
  %133 = call i32 @s2n_connection_get_session_length(ptr noundef nonnull %0) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #8
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %8, i8 0, i64 24, i1 false)
  %134 = and i32 %133, 65535
  %135 = call i32 @s2n_realloc(ptr noundef nonnull %8, i32 noundef %134) #8
  %136 = icmp sgt i32 %135, -1
  br i1 %136, label %137, label %.critedge

137:                                              ; preds = %132
  %138 = load ptr, ptr %8, align 8, !tbaa !45
  %139 = getelementptr inbounds i8, ptr %8, i64 8
  %140 = load i32, ptr %139, align 8, !tbaa !51
  %141 = zext i32 %140 to i64
  %142 = call i32 @s2n_connection_get_session(ptr noundef nonnull %0, ptr noundef %138, i64 noundef %141) #8
  %143 = icmp sgt i32 %142, -1
  br i1 %143, label %144, label %.critedge

144:                                              ; preds = %137
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %9) #8
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %9, ptr noundef nonnull align 8 dereferenceable(24) %8, i64 24, i1 false), !tbaa.struct !52
  %145 = getelementptr inbounds i8, ptr %9, i64 24
  %146 = load i32, ptr %3, align 4, !tbaa !11
  store i32 %146, ptr %145, align 8, !tbaa !54
  %147 = load ptr, ptr %28, align 8, !tbaa !13
  %148 = getelementptr inbounds i8, ptr %147, i64 368
  %149 = load ptr, ptr %148, align 8, !tbaa !47
  %150 = getelementptr inbounds i8, ptr %147, i64 376
  %151 = load ptr, ptr %150, align 8, !tbaa !56
  %152 = call i32 %149(ptr noundef nonnull %0, ptr noundef %151, ptr noundef nonnull %9) #8
  %153 = icmp sgt i32 %152, -1
  br i1 %153, label %.critedge55, label %154

154:                                              ; preds = %144
  %155 = call align 8 ptr @llvm.threadlocal.address.p0(ptr align 8 @_s2n_debug_info)
  store ptr @.str.20, ptr %155, align 8, !tbaa !5
  %156 = call ptr @strrchr(ptr noundef nonnull dereferenceable(1) getelementptr inbounds (i8, ptr @.str.20, i64 21), i32 noundef 47) #7
  %.not53 = icmp eq ptr %156, null
  %157 = getelementptr inbounds i8, ptr %156, i64 1
  %158 = select i1 %.not53, ptr getelementptr inbounds (i8, ptr @.str.20, i64 21), ptr %157
  %159 = getelementptr inbounds i8, ptr %155, i64 8
  store ptr %158, ptr %159, align 8, !tbaa !10
  %160 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  store i32 335544386, ptr %160, align 4, !tbaa !11
  %161 = call i32 @s2n_calculate_stacktrace() #8
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %9) #8
  %162 = call i32 @s2n_free(ptr noundef nonnull %8) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #8
  br label %165

.critedge55:                                      ; preds = %144
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %9) #8
  %163 = call i32 @s2n_free(ptr noundef nonnull %8) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #8
  br label %165

.critedge:                                        ; preds = %137, %132
  %164 = call i32 @s2n_free(ptr noundef nonnull %8) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #8
  br label %165

165:                                              ; preds = %128, %.critedge55, %154, %.critedge, %125, %122, %117, %104, %109
  %.sroa.0.2 = phi i32 [ -1, %154 ], [ -1, %109 ], [ -1, %104 ], [ -1, %117 ], [ -1, %122 ], [ -1, %125 ], [ -1, %.critedge ], [ 0, %.critedge55 ], [ 0, %128 ]
  call void @llvm.lifetime.end.p0(i64 2, ptr nonnull %7) #8
  br label %166

166:                                              ; preds = %101, %95, %90, %165
  %.sroa.0.3 = phi i32 [ %.sroa.0.2, %165 ], [ -1, %90 ], [ -1, %95 ], [ -1, %101 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #8
  call void @llvm.lifetime.end.p0(i64 255, ptr nonnull %5) #8
  br label %167

167:                                              ; preds = %87, %166
  %.sroa.0.4 = phi i32 [ %.sroa.0.3, %166 ], [ -1, %87 ]
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %4) #8
  br label %168

168:                                              ; preds = %82, %80, %65, %167, %72
  %.sroa.0.5 = phi i32 [ %.sroa.0.4, %167 ], [ -1, %72 ], [ -1, %65 ], [ 0, %80 ], [ -1, %82 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #8
  br label %169

169:                                              ; preds = %62, %168, %54, %42, %30, %19, %10
  %.sroa.0.6 = phi i32 [ %.sroa.0.5, %168 ], [ -1, %54 ], [ -1, %42 ], [ -1, %30 ], [ -1, %19 ], [ -1, %10 ], [ 0, %62 ]
  ret i32 %.sroa.0.6
}

declare i32 @s2n_stuffer_read_uint8(ptr noundef, ptr noundef) local_unnamed_addr #0

declare i32 @s2n_stuffer_read_bytes(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #0

declare i32 @s2n_extension_list_recv(i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #0

attributes #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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #3 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #5 = { mustprogress nofree nounwind willreturn memory(argmem: 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 #6 = { 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 #7 = { nounwind willreturn memory(read) }
attributes #8 = { 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, !7, i64 0}
!6 = !{!"s2n_debug_info", !7, i64 0, !7, i64 8}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!6, !7, i64 8}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !8, i64 0}
!13 = !{!14, !7, i64 8}
!14 = !{!"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, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !7, i64 56, !7, i64 64, !7, i64 72, !8, i64 80, !8, i64 102, !8, i64 124, !12, i64 148, !12, i64 152, !15, i64 160, !16, i64 168, !16, 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, !7, i64 224, !7, i64 232, !17, i64 240, !7, i64 632, !7, i64 640, !18, i64 648, !25, i64 1144, !28, i64 1688, !7, i64 1752, !8, i64 1760, !12, i64 1764, !8, i64 1768, !31, i64 1776, !31, i64 1816, !31, i64 1856, !31, i64 1896, !12, i64 1936, !16, i64 1944, !8, i64 1952, !31, i64 1960, !8, i64 2000, !8, i64 2001, !8, i64 2002, !24, i64 2003, !32, i64 2004, !32, i64 2008, !33, i64 2016, !30, i64 2208, !12, i64 2212, !30, i64 2216, !16, i64 2224, !8, i64 2232, !16, i64 2240, !16, i64 2248, !16, i64 2256, !32, i64 2264, !32, i64 2268, !8, i64 2272, !8, i64 2528, !12, i64 2784, !23, i64 2792, !12, i64 2816, !23, i64 2824, !23, i64 2848, !23, i64 2872, !35, i64 2896, !37, i64 3704, !7, i64 3760, !7, i64 3768, !8, i64 3776, !12, i64 3780, !23, i64 3784, !12, i64 3808, !39, i64 3816, !8, i64 3848, !31, i64 3992, !23, i64 4032, !23, i64 4056, !24, i64 4080, !24, i64 4081, !24, i64 4082, !30, i64 4084, !30, i64 4086, !12, i64 4088, !12, i64 4092, !23, i64 4096, !12, i64 4120, !40, i64 4128, !32, i64 4176, !8, i64 4180, !8, i64 4181}
!15 = !{!"s2n_timer", !16, i64 0}
!16 = !{!"long", !8, i64 0}
!17 = !{!"s2n_secrets", !8, i64 0, !12, i64 388}
!18 = !{!"s2n_kex_parameters", !19, i64 0, !20, i64 8, !8, i64 24, !20, i64 56, !21, i64 72, !21, i64 184, !8, i64 296, !22, i64 360, !23, i64 448, !23, i64 472}
!19 = !{!"s2n_dh_params", !7, i64 0}
!20 = !{!"s2n_ecc_evp_params", !7, i64 0, !7, i64 8}
!21 = !{!"s2n_kem_group_params", !7, i64 0, !22, i64 8, !20, i64 96}
!22 = !{!"s2n_kem_params", !7, i64 0, !23, i64 8, !23, i64 32, !23, i64 56, !24, i64 80}
!23 = !{!"s2n_blob", !7, i64 0, !12, i64 8, !12, i64 12, !12, i64 16}
!24 = !{!"_Bool", !8, i64 0}
!25 = !{!"s2n_handshake_parameters", !26, i64 0, !26, i64 48, !23, i64 96, !12, i64 120, !27, i64 124, !7, i64 384, !7, i64 392, !7, i64 400, !8, i64 408, !8, i64 440, !8, i64 472, !8, i64 473, !8, i64 474, !8, i64 506}
!26 = !{!"s2n_pkey", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40}
!27 = !{!"s2n_sig_scheme_list", !8, i64 0, !8, i64 256}
!28 = !{!"s2n_psk_parameters", !12, i64 0, !29, i64 8, !30, i64 40, !30, i64 42, !7, i64 48, !12, i64 56}
!29 = !{!"s2n_array", !23, i64 0, !12, i64 24, !12, i64 28}
!30 = !{!"short", !8, i64 0}
!31 = !{!"s2n_stuffer", !23, i64 0, !12, i64 24, !12, i64 28, !12, i64 32, !12, i64 36, !12, i64 36, !12, i64 36}
!32 = !{!"", !12, i64 0}
!33 = !{!"s2n_handshake", !31, i64 0, !7, i64 40, !8, i64 48, !8, i64 56, !8, i64 104, !8, i64 152, !12, i64 156, !12, i64 160, !12, i64 164, !12, i64 168, !34, i64 176, !12, i64 184, !12, i64 184, !12, i64 184, !12, i64 184, !12, i64 188}
!34 = !{!"s2n_offered_early_data", !7, i64 0}
!35 = !{!"s2n_client_hello", !23, i64 0, !36, i64 24, !23, i64 728, !23, i64 752, !23, i64 776, !8, i64 800, !8, i64 801, !12, i64 802, !12, i64 802, !12, i64 802, !12, i64 802, !12, i64 802, !12, i64 802, !12, i64 802}
!36 = !{!"", !8, i64 0, !23, i64 672, !30, i64 696}
!37 = !{!"s2n_x509_validator", !7, i64 0, !7, i64 8, !8, i64 16, !8, i64 17, !30, i64 18, !7, i64 24, !12, i64 32, !7, i64 40, !38, i64 48, !24, i64 52}
!38 = !{!"s2n_cert_validation_info", !12, i64 0, !12, i64 0}
!39 = !{!"s2n_ticket_fields", !23, i64 0, !12, i64 24}
!40 = !{!"s2n_post_handshake", !31, i64 0, !8, i64 40}
!41 = !{!14, !8, i64 220}
!42 = !{!14, !12, i64 148}
!43 = !{!14, !12, i64 3808}
!44 = !{!8, !8, i64 0}
!45 = !{!23, !7, i64 0}
!46 = !{!30, !30, i64 0}
!47 = !{!48, !7, i64 368}
!48 = !{!"s2n_config", !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, !7, i64 8, !7, i64 16, !49, i64 24, !23, i64 56, !7, i64 80, !7, i64 88, !7, i64 96, !7, i64 104, !7, i64 112, !7, i64 120, !12, i64 128, !12, i64 132, !7, i64 136, !16, i64 144, !7, i64 152, !16, i64 160, !16, i64 168, !7, i64 176, !7, i64 184, !7, i64 192, !7, i64 200, !7, i64 208, !7, i64 216, !12, i64 224, !8, i64 228, !12, i64 232, !12, i64 236, !7, i64 240, !7, i64 248, !7, i64 256, !7, i64 264, !7, i64 272, !7, i64 280, !7, i64 288, !8, i64 296, !8, i64 297, !50, i64 304, !30, i64 320, !7, i64 328, !7, i64 336, !7, i64 344, !7, i64 352, !7, i64 360, !7, i64 368, !7, i64 376, !7, i64 384, !12, i64 392, !12, i64 396, !12, i64 400, !7, i64 408, !12, i64 416, !12, i64 420, !7, i64 424, !7, i64 432, !12, i64 440, !23, i64 448}
!49 = !{!"certs_by_type", !8, i64 0}
!50 = !{!"s2n_x509_trust_store", !7, i64 0, !12, i64 8}
!51 = !{!23, !12, i64 8}
!52 = !{i64 0, i64 8, !53, i64 8, i64 4, !11, i64 12, i64 4, !11, i64 16, i64 1, !44}
!53 = !{!7, !7, i64 0}
!54 = !{!55, !12, i64 24}
!55 = !{!"s2n_session_ticket", !23, i64 0, !12, i64 24}
!56 = !{!48, !7, i64 376}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,SROAPass,SimplifyCFGPass,TailCallElimPass