; 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.session_cache_entry = type { [32 x i8], i8, [255 x i8], i8, i8 }

@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.6 = external hidden unnamed_addr constant [31 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 uwtable
define dso_local i32 @cache_retrieve_callback(ptr noundef %0, ptr noundef %1, ptr noundef %2, i64 noundef %3, ptr noundef %4, ptr noundef %5) #7 {
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i64, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca i8, align 1
  %17 = alloca i8, align 1
  %18 = alloca i32, align 4
  store ptr %0, ptr %8, align 8, !tbaa !5
  store ptr %1, ptr %9, align 8, !tbaa !5
  store ptr %2, ptr %10, align 8, !tbaa !5
  store i64 %3, ptr %11, align 8, !tbaa !9
  store ptr %4, ptr %12, align 8, !tbaa !5
  store ptr %5, ptr %13, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #9
  %19 = load ptr, ptr %9, align 8, !tbaa !5
  store ptr %19, ptr %14, align 8, !tbaa !5
  %20 = load i64, ptr %11, align 8, !tbaa !9
  %21 = icmp eq i64 %20, 0
  br i1 %21, label %25, label %22

22:                                               ; preds = %6
  %23 = load i64, ptr %11, align 8, !tbaa !9
  %24 = icmp ugt i64 %23, 32
  br i1 %24, label %25, label %26

25:                                               ; preds = %22, %6
  store i32 -1, ptr %7, align 4
  store i32 1, ptr %15, align 4
  br label %165

26:                                               ; preds = %22
  call void @llvm.lifetime.start.p0(i64 1, ptr %16) #9
  %27 = load ptr, ptr %10, align 8, !tbaa !5
  %28 = getelementptr inbounds i8, ptr %27, i64 0
  %29 = load i8, ptr %28, align 1, !tbaa !11
  store i8 %29, ptr %16, align 1, !tbaa !11
  %30 = load ptr, ptr %14, align 8, !tbaa !5
  %31 = load i8, ptr %16, align 1, !tbaa !11
  %32 = zext i8 %31 to i64
  %33 = getelementptr inbounds %struct.session_cache_entry, ptr %30, i64 %32
  %34 = getelementptr inbounds %struct.session_cache_entry, ptr %33, i32 0, i32 4
  %35 = load i8, ptr %34, align 1, !tbaa !12
  %36 = icmp ne i8 %35, 0
  br i1 %36, label %37, label %43

37:                                               ; preds = %26
  %38 = load ptr, ptr %14, align 8, !tbaa !5
  %39 = load i8, ptr %16, align 1, !tbaa !11
  %40 = zext i8 %39 to i64
  %41 = getelementptr inbounds %struct.session_cache_entry, ptr %38, i64 %40
  %42 = getelementptr inbounds %struct.session_cache_entry, ptr %41, i32 0, i32 4
  store i8 0, ptr %42, align 1, !tbaa !12
  store i32 -2, ptr %7, align 4
  store i32 1, ptr %15, align 4
  br label %164

43:                                               ; preds = %26
  %44 = load ptr, ptr %14, align 8, !tbaa !5
  %45 = load i8, ptr %16, align 1, !tbaa !11
  %46 = zext i8 %45 to i64
  %47 = getelementptr inbounds %struct.session_cache_entry, ptr %44, i64 %46
  %48 = getelementptr inbounds %struct.session_cache_entry, ptr %47, i32 0, i32 1
  %49 = load i8, ptr %48, align 1, !tbaa !14
  %50 = zext i8 %49 to i64
  %51 = load i64, ptr %11, align 8, !tbaa !9
  %52 = icmp ne i64 %50, %51
  br i1 %52, label %53, label %54

53:                                               ; preds = %43
  store i32 -1, ptr %7, align 4
  store i32 1, ptr %15, align 4
  br label %164

54:                                               ; preds = %43
  %55 = load ptr, ptr %14, align 8, !tbaa !5
  %56 = load i8, ptr %16, align 1, !tbaa !11
  %57 = zext i8 %56 to i64
  %58 = getelementptr inbounds %struct.session_cache_entry, ptr %55, i64 %57
  %59 = getelementptr inbounds %struct.session_cache_entry, ptr %58, i32 0, i32 0
  %60 = getelementptr inbounds [32 x i8], ptr %59, i64 0, i64 0
  %61 = load ptr, ptr %10, align 8, !tbaa !5
  %62 = load i64, ptr %11, align 8, !tbaa !9
  %63 = call i32 @memcmp(ptr noundef %60, ptr noundef %61, i64 noundef %62) #10
  %64 = icmp ne i32 %63, 0
  br i1 %64, label %65, label %66

65:                                               ; preds = %54
  store i32 -1, ptr %7, align 4
  store i32 1, ptr %15, align 4
  br label %164

66:                                               ; preds = %54
  %67 = load ptr, ptr %13, align 8, !tbaa !5
  %68 = load i64, ptr %67, align 8, !tbaa !9
  %69 = load ptr, ptr %14, align 8, !tbaa !5
  %70 = load i8, ptr %16, align 1, !tbaa !11
  %71 = zext i8 %70 to i64
  %72 = getelementptr inbounds %struct.session_cache_entry, ptr %69, i64 %71
  %73 = getelementptr inbounds %struct.session_cache_entry, ptr %72, i32 0, i32 3
  %74 = load i8, ptr %73, align 1, !tbaa !15
  %75 = zext i8 %74 to i64
  %76 = icmp ult i64 %68, %75
  br i1 %76, label %77, label %78

77:                                               ; preds = %66
  store i32 -1, ptr %7, align 4
  store i32 1, ptr %15, align 4
  br label %164

78:                                               ; preds = %66
  %79 = load ptr, ptr %14, align 8, !tbaa !5
  %80 = load i8, ptr %16, align 1, !tbaa !11
  %81 = zext i8 %80 to i64
  %82 = getelementptr inbounds %struct.session_cache_entry, ptr %79, i64 %81
  %83 = getelementptr inbounds %struct.session_cache_entry, ptr %82, i32 0, i32 3
  %84 = load i8, ptr %83, align 1, !tbaa !15
  %85 = zext i8 %84 to i64
  %86 = load ptr, ptr %13, align 8, !tbaa !5
  store i64 %85, ptr %86, align 8, !tbaa !9
  br label %87

87:                                               ; preds = %78
  call void @llvm.lifetime.start.p0(i64 1, ptr %17) #9
  %88 = load ptr, ptr %14, align 8, !tbaa !5
  %89 = load i8, ptr %16, align 1, !tbaa !11
  %90 = zext i8 %89 to i64
  %91 = getelementptr inbounds %struct.session_cache_entry, ptr %88, i64 %90
  %92 = getelementptr inbounds %struct.session_cache_entry, ptr %91, i32 0, i32 3
  %93 = load i8, ptr %92, align 1, !tbaa !15
  store i8 %93, ptr %17, align 1, !tbaa !11
  %94 = load i8, ptr %17, align 1, !tbaa !11
  %95 = icmp ne i8 %94, 0
  br i1 %95, label %96, label %161

96:                                               ; preds = %87
  %97 = load ptr, ptr %12, align 8, !tbaa !5
  %98 = load ptr, ptr %14, align 8, !tbaa !5
  %99 = load i8, ptr %16, align 1, !tbaa !11
  %100 = zext i8 %99 to i64
  %101 = getelementptr inbounds %struct.session_cache_entry, ptr %98, i64 %100
  %102 = getelementptr inbounds %struct.session_cache_entry, ptr %101, i32 0, i32 2
  %103 = getelementptr inbounds [255 x i8], ptr %102, i64 0, i64 0
  %104 = load i8, ptr %17, align 1, !tbaa !11
  %105 = zext i8 %104 to i64
  call void @llvm.memmove.p0.p0.i64(ptr align 1 %97, ptr align 1 %103, i64 %105, i1 false)
  %106 = icmp eq ptr %97, null
  br i1 %106, label %107, label %160

107:                                              ; preds = %96
  br label %108

108:                                              ; preds = %107
  br label %109

109:                                              ; preds = %108
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #9
  %110 = call ptr @__errno_location() #11
  %111 = load i32, ptr %110, align 4, !tbaa !16
  store i32 %111, ptr %18, align 4, !tbaa !16
  %112 = load ptr, ptr @stderr, align 8, !tbaa !5
  %113 = call i32 @s2n_print_stacktrace(ptr noundef %112)
  %114 = load i8, ptr @s2n_use_color_in_output, align 1, !tbaa !18, !range !20, !noundef !21
  %115 = trunc i8 %114 to i1
  br i1 %115, label %116, label %138

116:                                              ; preds = %109
  %117 = load ptr, ptr @stderr, align 8, !tbaa !5
  %118 = call i32 @fileno(ptr noundef %117) #9
  %119 = call i32 @isatty(i32 noundef %118) #9
  %120 = icmp ne i32 %119, 0
  br i1 %120, label %121, label %138

121:                                              ; preds = %116
  %122 = load i32, ptr %18, align 4, !tbaa !16
  %123 = call ptr @__errno_location() #11
  store i32 %122, ptr %123, align 4, !tbaa !16
  %124 = load ptr, ptr @stderr, align 8, !tbaa !5
  %125 = load i32, ptr @test_count, align 4, !tbaa !16
  %126 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %127 = load i32, ptr %126, align 4, !tbaa !16
  %128 = call ptr @s2n_strerror(i32 noundef %127, ptr noundef @.str.3)
  %129 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %130 = load i32, ptr %129, align 4, !tbaa !16
  %131 = call ptr @s2n_strerror_debug(i32 noundef %130, ptr noundef @.str.3)
  %132 = call ptr @__errno_location() #11
  %133 = load i32, ptr %132, align 4, !tbaa !16
  %134 = call ptr @strerror(i32 noundef %133) #9
  %135 = call ptr @__errno_location() #11
  %136 = load i32, ptr %135, align 4, !tbaa !16
  %137 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %124, ptr noundef @.str, i32 noundef %125, ptr noundef @.str.6, ptr noundef @.str.2, i32 noundef 97, ptr noundef %128, ptr noundef %131, ptr noundef %134, i32 noundef %136) #9
  br label %155

138:                                              ; preds = %116, %109
  %139 = load i32, ptr %18, align 4, !tbaa !16
  %140 = call ptr @__errno_location() #11
  store i32 %139, ptr %140, align 4, !tbaa !16
  %141 = load ptr, ptr @stderr, align 8, !tbaa !5
  %142 = load i32, ptr @test_count, align 4, !tbaa !16
  %143 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %144 = load i32, ptr %143, align 4, !tbaa !16
  %145 = call ptr @s2n_strerror(i32 noundef %144, ptr noundef @.str.3)
  %146 = call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %147 = load i32, ptr %146, align 4, !tbaa !16
  %148 = call ptr @s2n_strerror_debug(i32 noundef %147, ptr noundef @.str.3)
  %149 = call ptr @__errno_location() #11
  %150 = load i32, ptr %149, align 4, !tbaa !16
  %151 = call ptr @strerror(i32 noundef %150) #9
  %152 = call ptr @__errno_location() #11
  %153 = load i32, ptr %152, align 4, !tbaa !16
  %154 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %141, ptr noundef @.str.4, i32 noundef %142, ptr noundef @.str.6, ptr noundef @.str.2, i32 noundef 97, ptr noundef %145, ptr noundef %148, ptr noundef %151, i32 noundef %153) #9
  br label %155

155:                                              ; preds = %138, %121
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #9
  br label %156

156:                                              ; preds = %155
  br label %157

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

158:                                              ; No predecessors!
  br label %159

159:                                              ; preds = %158
  br label %160

160:                                              ; preds = %159, %96
  br label %161

161:                                              ; preds = %160, %87
  call void @llvm.lifetime.end.p0(i64 1, ptr %17) #9
  br label %162

162:                                              ; preds = %161
  br label %163

163:                                              ; preds = %162
  store i32 0, ptr %7, align 4
  store i32 1, ptr %15, align 4
  br label %164

164:                                              ; preds = %163, %77, %65, %53, %37
  call void @llvm.lifetime.end.p0(i64 1, ptr %16) #9
  br label %165

165:                                              ; preds = %164, %25
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #9
  %166 = load i32, ptr %7, align 4
  ret i32 %166
}

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

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 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 = { 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 #9 = { nounwind }
attributes #10 = { nounwind willreturn memory(read) }
attributes #11 = { nounwind willreturn memory(none) }
attributes #12 = { 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, !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 = !{!7, !7, i64 0}
!12 = !{!13, !7, i64 289}
!13 = !{!"session_cache_entry", !7, i64 0, !7, i64 32, !7, i64 33, !7, i64 288, !7, i64 289}
!14 = !{!13, !7, i64 32}
!15 = !{!13, !7, i64 288}
!16 = !{!17, !17, i64 0}
!17 = !{!"int", !7, i64 0}
!18 = !{!19, !19, i64 0}
!19 = !{!"_Bool", !7, i64 0}
!20 = !{i8 0, i8 2}
!21 = !{}


; 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.session_cache_entry = type { [32 x i8], i8, [255 x i8], i8, i8 }

@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.6 = external hidden unnamed_addr constant [31 x i8], align 1

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memmove.p0.p0.i64(ptr nocapture writeonly, ptr nocapture readonly, i64, i1 immarg) #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: nounwind uwtable
define dso_local range(i32 -2, 1) i32 @cache_retrieve_callback(ptr nocapture noundef readnone %0, ptr nocapture noundef %1, ptr nocapture noundef readonly %2, i64 noundef %3, ptr noundef writeonly %4, ptr nocapture noundef %5) local_unnamed_addr #7 {
  %7 = add i64 %3, -33
  %or.cond = icmp ult i64 %7, -32
  br i1 %or.cond, label %54, label %8

8:                                                ; preds = %6
  %9 = load i8, ptr %2, align 1, !tbaa !5
  %10 = zext i8 %9 to i64
  %11 = getelementptr inbounds %struct.session_cache_entry, ptr %1, i64 %10
  %12 = getelementptr inbounds i8, ptr %11, i64 289
  %13 = load i8, ptr %12, align 1, !tbaa !8
  %.not = icmp eq i8 %13, 0
  br i1 %.not, label %15, label %14

14:                                               ; preds = %8
  store i8 0, ptr %12, align 1, !tbaa !8
  br label %54

15:                                               ; preds = %8
  %16 = getelementptr inbounds i8, ptr %11, i64 32
  %17 = load i8, ptr %16, align 1, !tbaa !10
  %18 = zext i8 %17 to i64
  %.not34 = icmp eq i64 %18, %3
  br i1 %.not34, label %19, label %54

19:                                               ; preds = %15
  %bcmp = tail call i32 @bcmp(ptr nonnull %11, ptr nonnull %2, i64 %3)
  %.not35 = icmp eq i32 %bcmp, 0
  br i1 %.not35, label %20, label %54

20:                                               ; preds = %19
  %21 = load i64, ptr %5, align 8, !tbaa !11
  %22 = getelementptr inbounds i8, ptr %11, i64 288
  %23 = load i8, ptr %22, align 1, !tbaa !13
  %24 = zext i8 %23 to i64
  %25 = icmp ult i64 %21, %24
  br i1 %25, label %54, label %26

26:                                               ; preds = %20
  store i64 %24, ptr %5, align 8, !tbaa !11
  %.not36 = icmp eq i8 %23, 0
  br i1 %.not36, label %54, label %27

27:                                               ; preds = %26
  %28 = getelementptr inbounds i8, ptr %11, i64 33
  tail call void @llvm.memmove.p0.p0.i64(ptr align 1 %4, ptr nonnull align 1 %28, i64 %24, i1 false)
  %29 = icmp eq ptr %4, null
  br i1 %29, label %30, label %54

30:                                               ; preds = %27
  %31 = tail call ptr @__errno_location() #9
  %32 = load i32, ptr %31, align 4, !tbaa !14
  %33 = load ptr, ptr @stderr, align 8, !tbaa !16
  %34 = tail call i32 @s2n_print_stacktrace(ptr noundef %33) #10
  %35 = load i8, ptr @s2n_use_color_in_output, align 1, !tbaa !18, !range !20, !noundef !21
  %36 = trunc nuw i8 %35 to i1
  br i1 %36, label %37, label %41

37:                                               ; preds = %30
  %38 = load ptr, ptr @stderr, align 8, !tbaa !16
  %39 = tail call i32 @fileno(ptr noundef %38) #10
  %40 = tail call i32 @isatty(i32 noundef %39) #10
  %.not37 = icmp eq i32 %40, 0
  br i1 %.not37, label %41, label %42

41:                                               ; preds = %37, %30
  br label %42

42:                                               ; preds = %37, %41
  %.str.4.sink = phi ptr [ @.str.4, %41 ], [ @.str, %37 ]
  store i32 %32, ptr %31, align 4, !tbaa !14
  %43 = load ptr, ptr @stderr, align 8, !tbaa !16
  %44 = load i32, ptr @test_count, align 4, !tbaa !14
  %45 = tail call align 4 ptr @llvm.threadlocal.address.p0(ptr align 4 @s2n_errno)
  %46 = load i32, ptr %45, align 4, !tbaa !14
  %47 = tail call ptr @s2n_strerror(i32 noundef %46, ptr noundef nonnull @.str.3) #10
  %48 = load i32, ptr %45, align 4, !tbaa !14
  %49 = tail call ptr @s2n_strerror_debug(i32 noundef %48, ptr noundef nonnull @.str.3) #10
  %50 = load i32, ptr %31, align 4, !tbaa !14
  %51 = tail call ptr @strerror(i32 noundef %50) #10
  %52 = load i32, ptr %31, align 4, !tbaa !14
  %53 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %43, ptr noundef nonnull %.str.4.sink, i32 noundef %44, ptr noundef nonnull @.str.6, ptr noundef nonnull @.str.2, i32 noundef 97, ptr noundef %47, ptr noundef %49, ptr noundef %51, i32 noundef %52) #11
  tail call void @exit(i32 noundef 1) #12
  unreachable

54:                                               ; preds = %14, %15, %19, %20, %27, %26, %6
  %.1 = phi i32 [ -1, %6 ], [ -2, %14 ], [ -1, %15 ], [ -1, %19 ], [ -1, %20 ], [ 0, %27 ], [ 0, %26 ]
  ret i32 %.1
}

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

attributes #0 = { mustprogress nocallback nofree 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 = { 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 = { nofree nounwind willreturn memory(argmem: read) }
attributes #9 = { nounwind willreturn memory(none) }
attributes #10 = { nounwind }
attributes #11 = { cold nounwind }
attributes #12 = { 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, !6, i64 0}
!6 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C/C++ TBAA"}
!8 = !{!9, !6, i64 289}
!9 = !{!"session_cache_entry", !6, i64 0, !6, i64 32, !6, i64 33, !6, i64 288, !6, i64 289}
!10 = !{!9, !6, i64 32}
!11 = !{!12, !12, i64 0}
!12 = !{!"long", !6, i64 0}
!13 = !{!9, !6, i64 288}
!14 = !{!15, !15, i64 0}
!15 = !{!"int", !6, i64 0}
!16 = !{!17, !17, i64 0}
!17 = !{!"any pointer", !6, i64 0}
!18 = !{!19, !19, i64 0}
!19 = !{!"_Bool", !6, i64 0}
!20 = !{i8 0, i8 2}
!21 = !{}


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