; LLVM IR from yourtion/LearningMasteringAlgorithms-C :: Example/chtbl (main)

; 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.CHTbl_ = type { i32, ptr, ptr, ptr, i32, ptr }

@stdout = external global ptr, align 8
@.str = external hidden unnamed_addr constant [44 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [44 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [44 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [44 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [33 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [27 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local i32 @main(i32 noundef %0, ptr noundef %1) #0 {
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca %struct.CHTbl_, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i8, align 1
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  store i32 0, ptr %3, align 4
  store i32 %0, ptr %4, align 4, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 48, ptr %6) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr %8) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  %12 = call i32 @chtbl_init(ptr noundef %6, i32 noundef 11, ptr noundef @h_char, ptr noundef @match_char, ptr noundef @free)
  %13 = icmp ne i32 %12, 0
  br i1 %13, label %14, label %15

14:                                               ; preds = %2
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

15:                                               ; preds = %2
  store i32 0, ptr %10, align 4, !tbaa !5
  br label %16

16:                                               ; preds = %36, %15
  %17 = load i32, ptr %10, align 4, !tbaa !5
  %18 = icmp slt i32 %17, 11
  br i1 %18, label %19, label %39

19:                                               ; preds = %16
  %20 = call noalias ptr @malloc(i64 noundef 1) #6
  store ptr %20, ptr %7, align 8, !tbaa !9
  %21 = icmp eq ptr %20, null
  br i1 %21, label %22, label %23

22:                                               ; preds = %19
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

23:                                               ; preds = %19
  %24 = load i32, ptr %10, align 4, !tbaa !5
  %25 = mul nsw i32 %24, 6
  %26 = add nsw i32 5, %25
  %27 = srem i32 %26, 23
  %28 = add nsw i32 %27, 65
  %29 = trunc i32 %28 to i8
  %30 = load ptr, ptr %7, align 8, !tbaa !9
  store i8 %29, ptr %30, align 1, !tbaa !11
  %31 = load ptr, ptr %7, align 8, !tbaa !9
  %32 = call i32 @chtbl_insert(ptr noundef %6, ptr noundef %31)
  %33 = icmp ne i32 %32, 0
  br i1 %33, label %34, label %35

34:                                               ; preds = %23
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

35:                                               ; preds = %23
  call void @print_table(ptr noundef %6)
  br label %36

36:                                               ; preds = %35
  %37 = load i32, ptr %10, align 4, !tbaa !5
  %38 = add nsw i32 %37, 1
  store i32 %38, ptr %10, align 4, !tbaa !5
  br label %16, !llvm.loop !12

39:                                               ; preds = %16
  store i32 0, ptr %10, align 4, !tbaa !5
  br label %40

40:                                               ; preds = %60, %39
  %41 = load i32, ptr %10, align 4, !tbaa !5
  %42 = icmp slt i32 %41, 11
  br i1 %42, label %43, label %63

43:                                               ; preds = %40
  %44 = call noalias ptr @malloc(i64 noundef 1) #6
  store ptr %44, ptr %7, align 8, !tbaa !9
  %45 = icmp eq ptr %44, null
  br i1 %45, label %46, label %47

46:                                               ; preds = %43
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

47:                                               ; preds = %43
  %48 = load i32, ptr %10, align 4, !tbaa !5
  %49 = mul nsw i32 %48, 4
  %50 = add nsw i32 3, %49
  %51 = srem i32 %50, 23
  %52 = add nsw i32 %51, 97
  %53 = trunc i32 %52 to i8
  %54 = load ptr, ptr %7, align 8, !tbaa !9
  store i8 %53, ptr %54, align 1, !tbaa !11
  %55 = load ptr, ptr %7, align 8, !tbaa !9
  %56 = call i32 @chtbl_insert(ptr noundef %6, ptr noundef %55)
  %57 = icmp ne i32 %56, 0
  br i1 %57, label %58, label %59

58:                                               ; preds = %47
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

59:                                               ; preds = %47
  call void @print_table(ptr noundef %6)
  br label %60

60:                                               ; preds = %59
  %61 = load i32, ptr %10, align 4, !tbaa !5
  %62 = add nsw i32 %61, 1
  store i32 %62, ptr %10, align 4, !tbaa !5
  br label %40, !llvm.loop !14

63:                                               ; preds = %40
  %64 = call noalias ptr @malloc(i64 noundef 1) #6
  store ptr %64, ptr %7, align 8, !tbaa !9
  %65 = icmp eq ptr %64, null
  br i1 %65, label %66, label %67

66:                                               ; preds = %63
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

67:                                               ; preds = %63
  %68 = load ptr, ptr %7, align 8, !tbaa !9
  store i8 100, ptr %68, align 1, !tbaa !11
  %69 = load ptr, ptr %7, align 8, !tbaa !9
  %70 = call i32 @chtbl_insert(ptr noundef %6, ptr noundef %69)
  store i32 %70, ptr %9, align 4, !tbaa !5
  %71 = icmp ne i32 %70, 0
  br i1 %71, label %72, label %74

72:                                               ; preds = %67
  %73 = load ptr, ptr %7, align 8, !tbaa !9
  call void @free(ptr noundef %73) #5
  br label %74

74:                                               ; preds = %72, %67
  %75 = load ptr, ptr @stdout, align 8, !tbaa !9
  %76 = load i32, ptr %9, align 4, !tbaa !5
  %77 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %75, ptr noundef @.str, i32 noundef %76) #5
  %78 = call noalias ptr @malloc(i64 noundef 1) #6
  store ptr %78, ptr %7, align 8, !tbaa !9
  %79 = icmp eq ptr %78, null
  br i1 %79, label %80, label %81

80:                                               ; preds = %74
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

81:                                               ; preds = %74
  %82 = load ptr, ptr %7, align 8, !tbaa !9
  store i8 71, ptr %82, align 1, !tbaa !11
  %83 = load ptr, ptr %7, align 8, !tbaa !9
  %84 = call i32 @chtbl_insert(ptr noundef %6, ptr noundef %83)
  store i32 %84, ptr %9, align 4, !tbaa !5
  %85 = icmp ne i32 %84, 0
  br i1 %85, label %86, label %88

86:                                               ; preds = %81
  %87 = load ptr, ptr %7, align 8, !tbaa !9
  call void @free(ptr noundef %87) #5
  br label %88

88:                                               ; preds = %86, %81
  %89 = load ptr, ptr @stdout, align 8, !tbaa !9
  %90 = load i32, ptr %9, align 4, !tbaa !5
  %91 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %89, ptr noundef @.str.1, i32 noundef %90) #5
  %92 = load ptr, ptr @stdout, align 8, !tbaa !9
  %93 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %92, ptr noundef @.str.2) #5
  store i8 100, ptr %8, align 1, !tbaa !11
  store ptr %8, ptr %7, align 8, !tbaa !9
  %94 = call i32 @chtbl_remove(ptr noundef %6, ptr noundef %7)
  %95 = icmp eq i32 %94, 0
  br i1 %95, label %96, label %98

96:                                               ; preds = %88
  %97 = load ptr, ptr %7, align 8, !tbaa !9
  call void @free(ptr noundef %97) #5
  br label %98

98:                                               ; preds = %96, %88
  store i8 71, ptr %8, align 1, !tbaa !11
  store ptr %8, ptr %7, align 8, !tbaa !9
  %99 = call i32 @chtbl_remove(ptr noundef %6, ptr noundef %7)
  %100 = icmp eq i32 %99, 0
  br i1 %100, label %101, label %103

101:                                              ; preds = %98
  %102 = load ptr, ptr %7, align 8, !tbaa !9
  call void @free(ptr noundef %102) #5
  br label %103

103:                                              ; preds = %101, %98
  store i8 83, ptr %8, align 1, !tbaa !11
  store ptr %8, ptr %7, align 8, !tbaa !9
  %104 = call i32 @chtbl_remove(ptr noundef %6, ptr noundef %7)
  %105 = icmp eq i32 %104, 0
  br i1 %105, label %106, label %108

106:                                              ; preds = %103
  %107 = load ptr, ptr %7, align 8, !tbaa !9
  call void @free(ptr noundef %107) #5
  br label %108

108:                                              ; preds = %106, %103
  call void @print_table(ptr noundef %6)
  %109 = call noalias ptr @malloc(i64 noundef 1) #6
  store ptr %109, ptr %7, align 8, !tbaa !9
  %110 = icmp eq ptr %109, null
  br i1 %110, label %111, label %112

111:                                              ; preds = %108
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

112:                                              ; preds = %108
  %113 = load ptr, ptr %7, align 8, !tbaa !9
  store i8 100, ptr %113, align 1, !tbaa !11
  %114 = load ptr, ptr %7, align 8, !tbaa !9
  %115 = call i32 @chtbl_insert(ptr noundef %6, ptr noundef %114)
  store i32 %115, ptr %9, align 4, !tbaa !5
  %116 = icmp ne i32 %115, 0
  br i1 %116, label %117, label %119

117:                                              ; preds = %112
  %118 = load ptr, ptr %7, align 8, !tbaa !9
  call void @free(ptr noundef %118) #5
  br label %119

119:                                              ; preds = %117, %112
  %120 = load ptr, ptr @stdout, align 8, !tbaa !9
  %121 = load i32, ptr %9, align 4, !tbaa !5
  %122 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %120, ptr noundef @.str.3, i32 noundef %121) #5
  %123 = call noalias ptr @malloc(i64 noundef 1) #6
  store ptr %123, ptr %7, align 8, !tbaa !9
  %124 = icmp eq ptr %123, null
  br i1 %124, label %125, label %126

125:                                              ; preds = %119
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

126:                                              ; preds = %119
  %127 = load ptr, ptr %7, align 8, !tbaa !9
  store i8 71, ptr %127, align 1, !tbaa !11
  %128 = load ptr, ptr %7, align 8, !tbaa !9
  %129 = call i32 @chtbl_insert(ptr noundef %6, ptr noundef %128)
  store i32 %129, ptr %9, align 4, !tbaa !5
  %130 = icmp ne i32 %129, 0
  br i1 %130, label %131, label %133

131:                                              ; preds = %126
  %132 = load ptr, ptr %7, align 8, !tbaa !9
  call void @free(ptr noundef %132) #5
  br label %133

133:                                              ; preds = %131, %126
  %134 = load ptr, ptr @stdout, align 8, !tbaa !9
  %135 = load i32, ptr %9, align 4, !tbaa !5
  %136 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %134, ptr noundef @.str.4, i32 noundef %135) #5
  call void @print_table(ptr noundef %6)
  %137 = load ptr, ptr @stdout, align 8, !tbaa !9
  %138 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %137, ptr noundef @.str.5) #5
  %139 = call noalias ptr @malloc(i64 noundef 1) #6
  store ptr %139, ptr %7, align 8, !tbaa !9
  %140 = icmp eq ptr %139, null
  br i1 %140, label %141, label %142

141:                                              ; preds = %133
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

142:                                              ; preds = %133
  %143 = load ptr, ptr %7, align 8, !tbaa !9
  store i8 88, ptr %143, align 1, !tbaa !11
  %144 = load ptr, ptr %7, align 8, !tbaa !9
  %145 = call i32 @chtbl_insert(ptr noundef %6, ptr noundef %144)
  %146 = icmp ne i32 %145, 0
  br i1 %146, label %147, label %148

147:                                              ; preds = %142
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

148:                                              ; preds = %142
  %149 = call noalias ptr @malloc(i64 noundef 1) #6
  store ptr %149, ptr %7, align 8, !tbaa !9
  %150 = icmp eq ptr %149, null
  br i1 %150, label %151, label %152

151:                                              ; preds = %148
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

152:                                              ; preds = %148
  %153 = load ptr, ptr %7, align 8, !tbaa !9
  store i8 89, ptr %153, align 1, !tbaa !11
  %154 = load ptr, ptr %7, align 8, !tbaa !9
  %155 = call i32 @chtbl_insert(ptr noundef %6, ptr noundef %154)
  %156 = icmp ne i32 %155, 0
  br i1 %156, label %157, label %158

157:                                              ; preds = %152
  store i32 1, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

158:                                              ; preds = %152
  call void @print_table(ptr noundef %6)
  store i8 88, ptr %8, align 1, !tbaa !11
  store ptr %8, ptr %7, align 8, !tbaa !9
  %159 = call i32 @chtbl_lookup(ptr noundef %6, ptr noundef %7)
  %160 = icmp eq i32 %159, 0
  br i1 %160, label %161, label %164

161:                                              ; preds = %158
  %162 = load ptr, ptr @stdout, align 8, !tbaa !9
  %163 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %162, ptr noundef @.str.6) #5
  br label %167

164:                                              ; preds = %158
  %165 = load ptr, ptr @stdout, align 8, !tbaa !9
  %166 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %165, ptr noundef @.str.7) #5
  br label %167

167:                                              ; preds = %164, %161
  store i8 90, ptr %8, align 1, !tbaa !11
  store ptr %8, ptr %7, align 8, !tbaa !9
  %168 = call i32 @chtbl_lookup(ptr noundef %6, ptr noundef %7)
  %169 = icmp eq i32 %168, 0
  br i1 %169, label %170, label %173

170:                                              ; preds = %167
  %171 = load ptr, ptr @stdout, align 8, !tbaa !9
  %172 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %171, ptr noundef @.str.6) #5
  br label %176

173:                                              ; preds = %167
  %174 = load ptr, ptr @stdout, align 8, !tbaa !9
  %175 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %174, ptr noundef @.str.7) #5
  br label %176

176:                                              ; preds = %173, %170
  %177 = load ptr, ptr @stdout, align 8, !tbaa !9
  %178 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %177, ptr noundef @.str.8) #5
  call void @chtbl_destroy(ptr noundef %6)
  store i32 0, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %179

179:                                              ; preds = %176, %157, %151, %147, %141, %125, %111, %80, %66, %58, %46, %34, %22, %14
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 48, ptr %6) #5
  %180 = load i32, ptr %3, align 4
  ret i32 %180
}

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

declare i32 @chtbl_init(ptr noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef) #2

; Function Attrs: nounwind uwtable
declare hidden i32 @h_char(ptr noundef) #0

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

; Function Attrs: nounwind
declare void @free(ptr noundef) #3

; Function Attrs: nounwind allocsize(0)
declare noalias ptr @malloc(i64 noundef) #4

declare i32 @chtbl_insert(ptr noundef, ptr noundef) #2

; Function Attrs: nounwind uwtable
declare hidden void @print_table(ptr noundef) #0

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

declare i32 @chtbl_remove(ptr noundef, ptr noundef) #2

declare i32 @chtbl_lookup(ptr noundef, ptr noundef) #2

declare void @chtbl_destroy(ptr noundef) #2

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

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { nounwind allocsize(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 #5 = { nounwind }
attributes #6 = { nounwind allocsize(0) }

!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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!7, !7, i64 0}
!12 = distinct !{!12, !13}
!13 = !{!"llvm.loop.mustprogress"}
!14 = distinct !{!14, !13}


; 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.CHTbl_ = type { i32, ptr, ptr, ptr, i32, ptr }

@stdout = external local_unnamed_addr global ptr, align 8
@.str = external hidden unnamed_addr constant [44 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [44 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [44 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [44 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [26 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [33 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [27 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local range(i32 0, 2) i32 @main(i32 noundef %0, ptr nocapture noundef readnone %1) local_unnamed_addr #0 {
  %3 = alloca %struct.CHTbl_, align 8
  %4 = alloca ptr, align 8
  %5 = alloca i8, align 1
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %3) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %5) #6
  %6 = call i32 @chtbl_init(ptr noundef nonnull %3, i32 noundef 11, ptr noundef nonnull @h_char, ptr noundef nonnull @match_char, ptr noundef nonnull @free) #6
  %.not = icmp eq i32 %6, 0
  br i1 %.not, label %.preheader30.preheader, label %.loopexit

.preheader30.preheader:                           ; preds = %2
  %7 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %8 = icmp eq ptr %7, null
  br i1 %8, label %.loopexit, label %9

9:                                                ; preds = %.preheader30.preheader
  store i8 70, ptr %7, align 1, !tbaa !5
  %10 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %7) #6
  %.not27 = icmp eq i32 %10, 0
  br i1 %.not27, label %.preheader30.1, label %.loopexit

.preheader30.1:                                   ; preds = %9
  call void @print_table(ptr noundef nonnull %3)
  %11 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %12 = icmp eq ptr %11, null
  br i1 %12, label %.loopexit, label %13

13:                                               ; preds = %.preheader30.1
  store i8 76, ptr %11, align 1, !tbaa !5
  %14 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %11) #6
  %.not27.1 = icmp eq i32 %14, 0
  br i1 %.not27.1, label %.preheader30.2, label %.loopexit

.preheader30.2:                                   ; preds = %13
  call void @print_table(ptr noundef nonnull %3)
  %15 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %16 = icmp eq ptr %15, null
  br i1 %16, label %.loopexit, label %17

17:                                               ; preds = %.preheader30.2
  store i8 82, ptr %15, align 1, !tbaa !5
  %18 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %15) #6
  %.not27.2 = icmp eq i32 %18, 0
  br i1 %.not27.2, label %.preheader30.3, label %.loopexit

.preheader30.3:                                   ; preds = %17
  call void @print_table(ptr noundef nonnull %3)
  %19 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %20 = icmp eq ptr %19, null
  br i1 %20, label %.loopexit, label %21

21:                                               ; preds = %.preheader30.3
  store i8 65, ptr %19, align 1, !tbaa !5
  %22 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %19) #6
  %.not27.3 = icmp eq i32 %22, 0
  br i1 %.not27.3, label %.preheader30.4, label %.loopexit

.preheader30.4:                                   ; preds = %21
  call void @print_table(ptr noundef nonnull %3)
  %23 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %24 = icmp eq ptr %23, null
  br i1 %24, label %.loopexit, label %25

25:                                               ; preds = %.preheader30.4
  store i8 71, ptr %23, align 1, !tbaa !5
  %26 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %23) #6
  %.not27.4 = icmp eq i32 %26, 0
  br i1 %.not27.4, label %.preheader30.5, label %.loopexit

.preheader30.5:                                   ; preds = %25
  call void @print_table(ptr noundef nonnull %3)
  %27 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  store ptr %27, ptr %4, align 8, !tbaa !8
  %28 = icmp eq ptr %27, null
  br i1 %28, label %.loopexit, label %29

29:                                               ; preds = %.preheader30.5
  store i8 77, ptr %27, align 1, !tbaa !5
  %30 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %27) #6
  %.not27.5 = icmp eq i32 %30, 0
  br i1 %.not27.5, label %.preheader30.6, label %.loopexit

.preheader30.6:                                   ; preds = %29
  call void @print_table(ptr noundef nonnull %3)
  %31 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %32 = icmp eq ptr %31, null
  br i1 %32, label %.loopexit, label %33

33:                                               ; preds = %.preheader30.6
  store i8 83, ptr %31, align 1, !tbaa !5
  %34 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %31) #6
  %.not27.6 = icmp eq i32 %34, 0
  br i1 %.not27.6, label %.preheader30.7, label %.loopexit

.preheader30.7:                                   ; preds = %33
  call void @print_table(ptr noundef nonnull %3)
  %35 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %36 = icmp eq ptr %35, null
  br i1 %36, label %.loopexit, label %37

37:                                               ; preds = %.preheader30.7
  store i8 66, ptr %35, align 1, !tbaa !5
  %38 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %35) #6
  %.not27.7 = icmp eq i32 %38, 0
  br i1 %.not27.7, label %.preheader30.8, label %.loopexit

.preheader30.8:                                   ; preds = %37
  call void @print_table(ptr noundef nonnull %3)
  %39 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %40 = icmp eq ptr %39, null
  br i1 %40, label %.loopexit, label %41

41:                                               ; preds = %.preheader30.8
  store i8 72, ptr %39, align 1, !tbaa !5
  %42 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %39) #6
  %.not27.8 = icmp eq i32 %42, 0
  br i1 %.not27.8, label %.preheader30.9, label %.loopexit

.preheader30.9:                                   ; preds = %41
  call void @print_table(ptr noundef nonnull %3)
  %43 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  store ptr %43, ptr %4, align 8, !tbaa !8
  %44 = icmp eq ptr %43, null
  br i1 %44, label %.loopexit, label %45

45:                                               ; preds = %.preheader30.9
  store i8 78, ptr %43, align 1, !tbaa !5
  %46 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %43) #6
  %.not27.9 = icmp eq i32 %46, 0
  br i1 %.not27.9, label %.preheader30.10, label %.loopexit

.preheader30.10:                                  ; preds = %45
  call void @print_table(ptr noundef nonnull %3)
  %47 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %48 = icmp eq ptr %47, null
  br i1 %48, label %.loopexit, label %49

49:                                               ; preds = %.preheader30.10
  store i8 84, ptr %47, align 1, !tbaa !5
  %50 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %47) #6
  %.not27.10 = icmp eq i32 %50, 0
  br i1 %.not27.10, label %.preheader.preheader, label %.loopexit

.preheader.preheader:                             ; preds = %49
  call void @print_table(ptr noundef nonnull %3)
  %51 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %52 = icmp eq ptr %51, null
  br i1 %52, label %.loopexit, label %53

53:                                               ; preds = %.preheader.preheader
  store i8 100, ptr %51, align 1, !tbaa !5
  %54 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %51) #6
  %.not26 = icmp eq i32 %54, 0
  br i1 %.not26, label %.preheader.1, label %.loopexit

.preheader.1:                                     ; preds = %53
  call void @print_table(ptr noundef nonnull %3)
  %55 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %56 = icmp eq ptr %55, null
  br i1 %56, label %.loopexit, label %57

57:                                               ; preds = %.preheader.1
  store i8 104, ptr %55, align 1, !tbaa !5
  %58 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %55) #6
  %.not26.1 = icmp eq i32 %58, 0
  br i1 %.not26.1, label %.preheader.2, label %.loopexit

.preheader.2:                                     ; preds = %57
  call void @print_table(ptr noundef nonnull %3)
  %59 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  store ptr %59, ptr %4, align 8, !tbaa !8
  %60 = icmp eq ptr %59, null
  br i1 %60, label %.loopexit, label %61

61:                                               ; preds = %.preheader.2
  store i8 108, ptr %59, align 1, !tbaa !5
  %62 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %59) #6
  %.not26.2 = icmp eq i32 %62, 0
  br i1 %.not26.2, label %.preheader.3, label %.loopexit

.preheader.3:                                     ; preds = %61
  call void @print_table(ptr noundef nonnull %3)
  %63 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %64 = icmp eq ptr %63, null
  br i1 %64, label %.loopexit, label %65

65:                                               ; preds = %.preheader.3
  store i8 112, ptr %63, align 1, !tbaa !5
  %66 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %63) #6
  %.not26.3 = icmp eq i32 %66, 0
  br i1 %.not26.3, label %.preheader.4, label %.loopexit

.preheader.4:                                     ; preds = %65
  call void @print_table(ptr noundef nonnull %3)
  %67 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %68 = icmp eq ptr %67, null
  br i1 %68, label %.loopexit, label %69

69:                                               ; preds = %.preheader.4
  store i8 116, ptr %67, align 1, !tbaa !5
  %70 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %67) #6
  %.not26.4 = icmp eq i32 %70, 0
  br i1 %.not26.4, label %.preheader.5, label %.loopexit

.preheader.5:                                     ; preds = %69
  call void @print_table(ptr noundef nonnull %3)
  %71 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %72 = icmp eq ptr %71, null
  br i1 %72, label %.loopexit, label %73

73:                                               ; preds = %.preheader.5
  store i8 97, ptr %71, align 1, !tbaa !5
  %74 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %71) #6
  %.not26.5 = icmp eq i32 %74, 0
  br i1 %.not26.5, label %.preheader.6, label %.loopexit

.preheader.6:                                     ; preds = %73
  call void @print_table(ptr noundef nonnull %3)
  %75 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  store ptr %75, ptr %4, align 8, !tbaa !8
  %76 = icmp eq ptr %75, null
  br i1 %76, label %.loopexit, label %77

77:                                               ; preds = %.preheader.6
  store i8 101, ptr %75, align 1, !tbaa !5
  %78 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %75) #6
  %.not26.6 = icmp eq i32 %78, 0
  br i1 %.not26.6, label %.preheader.7, label %.loopexit

.preheader.7:                                     ; preds = %77
  call void @print_table(ptr noundef nonnull %3)
  %79 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %80 = icmp eq ptr %79, null
  br i1 %80, label %.loopexit, label %81

81:                                               ; preds = %.preheader.7
  store i8 105, ptr %79, align 1, !tbaa !5
  %82 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %79) #6
  %.not26.7 = icmp eq i32 %82, 0
  br i1 %.not26.7, label %.preheader.8, label %.loopexit

.preheader.8:                                     ; preds = %81
  call void @print_table(ptr noundef nonnull %3)
  %83 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %84 = icmp eq ptr %83, null
  br i1 %84, label %.loopexit, label %85

85:                                               ; preds = %.preheader.8
  store i8 109, ptr %83, align 1, !tbaa !5
  %86 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %83) #6
  %.not26.8 = icmp eq i32 %86, 0
  br i1 %.not26.8, label %.preheader.9, label %.loopexit

.preheader.9:                                     ; preds = %85
  call void @print_table(ptr noundef nonnull %3)
  %87 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %88 = icmp eq ptr %87, null
  br i1 %88, label %.loopexit, label %89

89:                                               ; preds = %.preheader.9
  store i8 113, ptr %87, align 1, !tbaa !5
  %90 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %87) #6
  %.not26.9 = icmp eq i32 %90, 0
  br i1 %.not26.9, label %.preheader.10, label %.loopexit

.preheader.10:                                    ; preds = %89
  call void @print_table(ptr noundef nonnull %3)
  %91 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  store ptr %91, ptr %4, align 8, !tbaa !8
  %92 = icmp eq ptr %91, null
  br i1 %92, label %.loopexit, label %93

93:                                               ; preds = %.preheader.10
  store i8 117, ptr %91, align 1, !tbaa !5
  %94 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %91) #6
  %.not26.10 = icmp eq i32 %94, 0
  br i1 %.not26.10, label %95, label %.loopexit

95:                                               ; preds = %93
  call void @print_table(ptr noundef nonnull %3)
  %96 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %97 = icmp eq ptr %96, null
  br i1 %97, label %.loopexit, label %98

98:                                               ; preds = %95
  store i8 100, ptr %96, align 1, !tbaa !5
  %99 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %96) #6
  %.not20 = icmp eq i32 %99, 0
  br i1 %.not20, label %101, label %100

100:                                              ; preds = %98
  call void @free(ptr noundef nonnull %96) #6
  br label %101

101:                                              ; preds = %100, %98
  %102 = load ptr, ptr @stdout, align 8, !tbaa !8
  %103 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %102, ptr noundef nonnull @.str, i32 noundef %99) #6
  %104 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  %105 = icmp eq ptr %104, null
  br i1 %105, label %.loopexit, label %106

106:                                              ; preds = %101
  store i8 71, ptr %104, align 1, !tbaa !5
  %107 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %104) #6
  %.not21 = icmp eq i32 %107, 0
  br i1 %.not21, label %109, label %108

108:                                              ; preds = %106
  call void @free(ptr noundef nonnull %104) #6
  br label %109

109:                                              ; preds = %108, %106
  %110 = load ptr, ptr @stdout, align 8, !tbaa !8
  %111 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %110, ptr noundef nonnull @.str.1, i32 noundef %107) #6
  %112 = load ptr, ptr @stdout, align 8, !tbaa !8
  %113 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %112, ptr noundef nonnull @.str.2) #6
  store i8 100, ptr %5, align 1, !tbaa !5
  store ptr %5, ptr %4, align 8, !tbaa !8
  %114 = call i32 @chtbl_remove(ptr noundef nonnull %3, ptr noundef nonnull %4) #6
  %115 = icmp eq i32 %114, 0
  br i1 %115, label %116, label %118

116:                                              ; preds = %109
  %117 = load ptr, ptr %4, align 8, !tbaa !8
  call void @free(ptr noundef %117) #6
  br label %118

118:                                              ; preds = %116, %109
  store i8 71, ptr %5, align 1, !tbaa !5
  store ptr %5, ptr %4, align 8, !tbaa !8
  %119 = call i32 @chtbl_remove(ptr noundef nonnull %3, ptr noundef nonnull %4) #6
  %120 = icmp eq i32 %119, 0
  br i1 %120, label %121, label %123

121:                                              ; preds = %118
  %122 = load ptr, ptr %4, align 8, !tbaa !8
  call void @free(ptr noundef %122) #6
  br label %123

123:                                              ; preds = %121, %118
  store i8 83, ptr %5, align 1, !tbaa !5
  store ptr %5, ptr %4, align 8, !tbaa !8
  %124 = call i32 @chtbl_remove(ptr noundef nonnull %3, ptr noundef nonnull %4) #6
  %125 = icmp eq i32 %124, 0
  br i1 %125, label %126, label %128

126:                                              ; preds = %123
  %127 = load ptr, ptr %4, align 8, !tbaa !8
  call void @free(ptr noundef %127) #6
  br label %128

128:                                              ; preds = %126, %123
  call void @print_table(ptr noundef nonnull %3)
  %129 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  store ptr %129, ptr %4, align 8, !tbaa !8
  %130 = icmp eq ptr %129, null
  br i1 %130, label %.loopexit, label %131

131:                                              ; preds = %128
  store i8 100, ptr %129, align 1, !tbaa !5
  %132 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %129) #6
  %.not22 = icmp eq i32 %132, 0
  br i1 %.not22, label %135, label %133

133:                                              ; preds = %131
  %134 = load ptr, ptr %4, align 8, !tbaa !8
  call void @free(ptr noundef %134) #6
  br label %135

135:                                              ; preds = %133, %131
  %136 = load ptr, ptr @stdout, align 8, !tbaa !8
  %137 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %136, ptr noundef nonnull @.str.3, i32 noundef %132) #6
  %138 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  store ptr %138, ptr %4, align 8, !tbaa !8
  %139 = icmp eq ptr %138, null
  br i1 %139, label %.loopexit, label %140

140:                                              ; preds = %135
  store i8 71, ptr %138, align 1, !tbaa !5
  %141 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %138) #6
  %.not23 = icmp eq i32 %141, 0
  br i1 %.not23, label %144, label %142

142:                                              ; preds = %140
  %143 = load ptr, ptr %4, align 8, !tbaa !8
  call void @free(ptr noundef %143) #6
  br label %144

144:                                              ; preds = %142, %140
  %145 = load ptr, ptr @stdout, align 8, !tbaa !8
  %146 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %145, ptr noundef nonnull @.str.4, i32 noundef %141) #6
  call void @print_table(ptr noundef nonnull %3)
  %147 = load ptr, ptr @stdout, align 8, !tbaa !8
  %148 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %147, ptr noundef nonnull @.str.5) #6
  %149 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  store ptr %149, ptr %4, align 8, !tbaa !8
  %150 = icmp eq ptr %149, null
  br i1 %150, label %.loopexit, label %151

151:                                              ; preds = %144
  store i8 88, ptr %149, align 1, !tbaa !5
  %152 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %149) #6
  %.not24 = icmp eq i32 %152, 0
  br i1 %.not24, label %153, label %.loopexit

153:                                              ; preds = %151
  %154 = call noalias dereferenceable_or_null(1) ptr @malloc(i64 noundef 1) #7
  store ptr %154, ptr %4, align 8, !tbaa !8
  %155 = icmp eq ptr %154, null
  br i1 %155, label %.loopexit, label %156

156:                                              ; preds = %153
  store i8 89, ptr %154, align 1, !tbaa !5
  %157 = call i32 @chtbl_insert(ptr noundef nonnull %3, ptr noundef nonnull %154) #6
  %.not25 = icmp eq i32 %157, 0
  br i1 %.not25, label %158, label %.loopexit

158:                                              ; preds = %156
  call void @print_table(ptr noundef nonnull %3)
  store i8 88, ptr %5, align 1, !tbaa !5
  store ptr %5, ptr %4, align 8, !tbaa !8
  %159 = call i32 @chtbl_lookup(ptr noundef nonnull %3, ptr noundef nonnull %4) #6
  %160 = icmp eq i32 %159, 0
  %161 = load ptr, ptr @stdout, align 8, !tbaa !8
  %.str.6..str.7 = select i1 %160, ptr @.str.6, ptr @.str.7
  %162 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %161, ptr noundef nonnull %.str.6..str.7) #6
  store i8 90, ptr %5, align 1, !tbaa !5
  store ptr %5, ptr %4, align 8, !tbaa !8
  %163 = call i32 @chtbl_lookup(ptr noundef nonnull %3, ptr noundef nonnull %4) #6
  %164 = icmp eq i32 %163, 0
  %.str.7.sink35 = select i1 %164, ptr @.str.6, ptr @.str.7
  %165 = load ptr, ptr @stdout, align 8, !tbaa !8
  %166 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %165, ptr noundef nonnull %.str.7.sink35) #6
  %167 = load ptr, ptr @stdout, align 8, !tbaa !8
  %168 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %167, ptr noundef nonnull @.str.8) #6
  call void @chtbl_destroy(ptr noundef nonnull %3) #6
  br label %.loopexit

.loopexit:                                        ; preds = %9, %.preheader30.preheader, %.preheader30.1, %13, %.preheader30.2, %17, %.preheader30.3, %21, %.preheader30.4, %25, %.preheader30.5, %29, %.preheader30.6, %33, %.preheader30.7, %37, %.preheader30.8, %41, %.preheader30.9, %45, %.preheader30.10, %49, %53, %.preheader.preheader, %.preheader.1, %57, %.preheader.2, %61, %.preheader.3, %65, %.preheader.4, %69, %.preheader.5, %73, %.preheader.6, %77, %.preheader.7, %81, %.preheader.8, %85, %.preheader.9, %89, %.preheader.10, %93, %156, %153, %151, %144, %135, %128, %101, %95, %2, %158
  %.011 = phi i32 [ 0, %158 ], [ 1, %2 ], [ 1, %95 ], [ 1, %101 ], [ 1, %128 ], [ 1, %135 ], [ 1, %144 ], [ 1, %151 ], [ 1, %153 ], [ 1, %156 ], [ 1, %93 ], [ 1, %.preheader.10 ], [ 1, %89 ], [ 1, %.preheader.9 ], [ 1, %85 ], [ 1, %.preheader.8 ], [ 1, %81 ], [ 1, %.preheader.7 ], [ 1, %77 ], [ 1, %.preheader.6 ], [ 1, %73 ], [ 1, %.preheader.5 ], [ 1, %69 ], [ 1, %.preheader.4 ], [ 1, %65 ], [ 1, %.preheader.3 ], [ 1, %61 ], [ 1, %.preheader.2 ], [ 1, %57 ], [ 1, %.preheader.1 ], [ 1, %.preheader.preheader ], [ 1, %53 ], [ 1, %49 ], [ 1, %.preheader30.10 ], [ 1, %45 ], [ 1, %.preheader30.9 ], [ 1, %41 ], [ 1, %.preheader30.8 ], [ 1, %37 ], [ 1, %.preheader30.7 ], [ 1, %33 ], [ 1, %.preheader30.6 ], [ 1, %29 ], [ 1, %.preheader30.5 ], [ 1, %25 ], [ 1, %.preheader30.4 ], [ 1, %21 ], [ 1, %.preheader30.3 ], [ 1, %17 ], [ 1, %.preheader30.2 ], [ 1, %13 ], [ 1, %.preheader30.1 ], [ 1, %.preheader30.preheader ], [ 1, %9 ]
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %5) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #6
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %3) #6
  ret i32 %.011
}

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

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

; Function Attrs: nounwind uwtable
declare hidden i32 @h_char(ptr noundef) #0

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

; Function Attrs: mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite)
declare void @free(ptr allocptr nocapture noundef) #3

; Function Attrs: mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @malloc(i64 noundef) local_unnamed_addr #4

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

; Function Attrs: nounwind uwtable
declare hidden void @print_table(ptr noundef) local_unnamed_addr #0

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

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

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

declare void @chtbl_destroy(ptr noundef) local_unnamed_addr #2

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

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite) "alloc-family"="malloc" "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 = { mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" "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 = { 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 #6 = { nounwind }
attributes #7 = { nounwind allocsize(0) }

!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, !9, i64 0}
!9 = !{!"any pointer", !6, i64 0}


; Effective O3 passes: CorrelatedValuePropagationPass,DSEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopRotatePass,LoopSimplifyPass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass