; LLVM IR from openssl/openssl :: fuzz (bndiv)

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

@b1 = external hidden global ptr, align 8
@b2 = external hidden global ptr, align 8
@b3 = external hidden global ptr, align 8
@b4 = external hidden global ptr, align 8
@b5 = external hidden global ptr, align 8
@ctx = external hidden global ptr, align 8
@.str = external hidden unnamed_addr constant [47 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [62 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [52 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [46 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [42 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [37 x i8], align 1
@stdout = external global ptr, align 8
@.str.6 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [26 x i8], align 1

declare void @ERR_clear_error() #0

; Function Attrs: nounwind uwtable
define dso_local i32 @FuzzerTestOneInput(ptr noundef %0, i64 noundef %1) #1 {
  %3 = alloca ptr, align 8
  %4 = alloca i64, align 8
  %5 = alloca i32, align 4
  %6 = alloca i64, align 8
  %7 = alloca i64, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  store ptr %0, ptr %3, align 8, !tbaa !5
  store i64 %1, ptr %4, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #5
  store i32 0, ptr %5, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  store i64 0, ptr %6, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  store i64 0, ptr %7, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #5
  store i32 0, ptr %8, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  store i32 0, ptr %9, align 4, !tbaa !11
  %10 = load i64, ptr %4, align 8, !tbaa !9
  %11 = icmp ugt i64 %10, 256000
  br i1 %11, label %12, label %13

12:                                               ; preds = %2
  store i64 256000, ptr %4, align 8, !tbaa !9
  br label %13

13:                                               ; preds = %12, %2
  %14 = load i64, ptr %4, align 8, !tbaa !9
  %15 = icmp ugt i64 %14, 0
  br i1 %15, label %16, label %43

16:                                               ; preds = %13
  %17 = load i64, ptr %4, align 8, !tbaa !9
  %18 = add i64 %17, -1
  store i64 %18, ptr %4, align 8, !tbaa !9
  %19 = load ptr, ptr %3, align 8, !tbaa !5
  %20 = getelementptr inbounds i8, ptr %19, i64 0
  %21 = load i8, ptr %20, align 1, !tbaa !13
  %22 = zext i8 %21 to i32
  %23 = and i32 %22, 63
  %24 = sext i32 %23 to i64
  %25 = load i64, ptr %4, align 8, !tbaa !9
  %26 = mul i64 %24, %25
  %27 = udiv i64 %26, 63
  store i64 %27, ptr %6, align 8, !tbaa !9
  %28 = load ptr, ptr %3, align 8, !tbaa !5
  %29 = getelementptr inbounds i8, ptr %28, i64 0
  %30 = load i8, ptr %29, align 1, !tbaa !13
  %31 = zext i8 %30 to i32
  %32 = and i32 %31, 64
  store i32 %32, ptr %8, align 4, !tbaa !11
  %33 = load ptr, ptr %3, align 8, !tbaa !5
  %34 = getelementptr inbounds i8, ptr %33, i64 0
  %35 = load i8, ptr %34, align 1, !tbaa !13
  %36 = zext i8 %35 to i32
  %37 = and i32 %36, 128
  store i32 %37, ptr %9, align 4, !tbaa !11
  %38 = load ptr, ptr %3, align 8, !tbaa !5
  %39 = getelementptr inbounds i8, ptr %38, i32 1
  store ptr %39, ptr %3, align 8, !tbaa !5
  %40 = load i64, ptr %4, align 8, !tbaa !9
  %41 = load i64, ptr %6, align 8, !tbaa !9
  %42 = sub i64 %40, %41
  store i64 %42, ptr %7, align 8, !tbaa !9
  br label %43

43:                                               ; preds = %16, %13
  %44 = load ptr, ptr %3, align 8, !tbaa !5
  %45 = load i64, ptr %6, align 8, !tbaa !9
  %46 = trunc i64 %45 to i32
  %47 = load ptr, ptr @b1, align 8, !tbaa !5
  %48 = call ptr @BN_bin2bn(ptr noundef %44, i32 noundef %46, ptr noundef %47)
  %49 = load ptr, ptr @b1, align 8, !tbaa !5
  %50 = icmp eq ptr %48, %49
  br i1 %50, label %51, label %52

51:                                               ; preds = %43
  br label %54

52:                                               ; preds = %43
  call void @OPENSSL_die(ptr noundef @.str, ptr noundef @.str.1, i32 noundef 72) #6
  unreachable

53:                                               ; No predecessors!
  br label %54

54:                                               ; preds = %53, %51
  %55 = phi i32 [ 0, %51 ], [ 1, %53 ]
  %56 = load ptr, ptr @b1, align 8, !tbaa !5
  %57 = load i32, ptr %8, align 4, !tbaa !11
  call void @BN_set_negative(ptr noundef %56, i32 noundef %57)
  %58 = load ptr, ptr %3, align 8, !tbaa !5
  %59 = load i64, ptr %6, align 8, !tbaa !9
  %60 = getelementptr inbounds i8, ptr %58, i64 %59
  %61 = load i64, ptr %7, align 8, !tbaa !9
  %62 = trunc i64 %61 to i32
  %63 = load ptr, ptr @b2, align 8, !tbaa !5
  %64 = call ptr @BN_bin2bn(ptr noundef %60, i32 noundef %62, ptr noundef %63)
  %65 = load ptr, ptr @b2, align 8, !tbaa !5
  %66 = icmp eq ptr %64, %65
  br i1 %66, label %67, label %68

67:                                               ; preds = %54
  br label %70

68:                                               ; preds = %54
  call void @OPENSSL_die(ptr noundef @.str.2, ptr noundef @.str.1, i32 noundef 74) #6
  unreachable

69:                                               ; No predecessors!
  br label %70

70:                                               ; preds = %69, %67
  %71 = phi i32 [ 0, %67 ], [ 1, %69 ]
  %72 = load ptr, ptr @b2, align 8, !tbaa !5
  %73 = load i32, ptr %9, align 4, !tbaa !11
  call void @BN_set_negative(ptr noundef %72, i32 noundef %73)
  %74 = load ptr, ptr @b2, align 8, !tbaa !5
  %75 = call i32 @BN_is_zero(ptr noundef %74)
  %76 = icmp ne i32 %75, 0
  br i1 %76, label %77, label %78

77:                                               ; preds = %70
  store i32 1, ptr %5, align 4, !tbaa !11
  br label %245

78:                                               ; preds = %70
  %79 = load ptr, ptr @b3, align 8, !tbaa !5
  %80 = load ptr, ptr @b4, align 8, !tbaa !5
  %81 = load ptr, ptr @b1, align 8, !tbaa !5
  %82 = load ptr, ptr @b2, align 8, !tbaa !5
  %83 = load ptr, ptr @ctx, align 8, !tbaa !5
  %84 = call i32 @BN_div(ptr noundef %79, ptr noundef %80, ptr noundef %81, ptr noundef %82, ptr noundef %83)
  %85 = icmp ne i32 %84, 0
  br i1 %85, label %86, label %87

86:                                               ; preds = %78
  br label %89

87:                                               ; preds = %78
  call void @OPENSSL_die(ptr noundef @.str.3, ptr noundef @.str.1, i32 noundef 83) #6
  unreachable

88:                                               ; No predecessors!
  br label %89

89:                                               ; preds = %88, %86
  %90 = phi i32 [ 0, %86 ], [ 1, %88 ]
  %91 = load ptr, ptr @b1, align 8, !tbaa !5
  %92 = call i32 @BN_is_zero(ptr noundef %91)
  %93 = icmp ne i32 %92, 0
  br i1 %93, label %94, label %105

94:                                               ; preds = %89
  %95 = load ptr, ptr @b3, align 8, !tbaa !5
  %96 = call i32 @BN_is_zero(ptr noundef %95)
  %97 = icmp ne i32 %96, 0
  br i1 %97, label %98, label %102

98:                                               ; preds = %94
  %99 = load ptr, ptr @b4, align 8, !tbaa !5
  %100 = call i32 @BN_is_zero(ptr noundef %99)
  %101 = icmp ne i32 %100, 0
  br label %102

102:                                              ; preds = %98, %94
  %103 = phi i1 [ false, %94 ], [ %101, %98 ]
  %104 = zext i1 %103 to i32
  store i32 %104, ptr %5, align 4, !tbaa !11
  br label %156

105:                                              ; preds = %89
  %106 = load ptr, ptr @b1, align 8, !tbaa !5
  %107 = call i32 @BN_is_negative(ptr noundef %106)
  %108 = icmp ne i32 %107, 0
  br i1 %108, label %109, label %132

109:                                              ; preds = %105
  %110 = load ptr, ptr @b3, align 8, !tbaa !5
  %111 = call i32 @BN_is_negative(ptr noundef %110)
  %112 = load ptr, ptr @b2, align 8, !tbaa !5
  %113 = call i32 @BN_is_negative(ptr noundef %112)
  %114 = icmp ne i32 %111, %113
  br i1 %114, label %119, label %115

115:                                              ; preds = %109
  %116 = load ptr, ptr @b3, align 8, !tbaa !5
  %117 = call i32 @BN_is_zero(ptr noundef %116)
  %118 = icmp ne i32 %117, 0
  br i1 %118, label %119, label %129

119:                                              ; preds = %115, %109
  %120 = load ptr, ptr @b4, align 8, !tbaa !5
  %121 = call i32 @BN_is_negative(ptr noundef %120)
  %122 = icmp ne i32 %121, 0
  br i1 %122, label %127, label %123

123:                                              ; preds = %119
  %124 = load ptr, ptr @b4, align 8, !tbaa !5
  %125 = call i32 @BN_is_zero(ptr noundef %124)
  %126 = icmp ne i32 %125, 0
  br label %127

127:                                              ; preds = %123, %119
  %128 = phi i1 [ true, %119 ], [ %126, %123 ]
  br label %129

129:                                              ; preds = %127, %115
  %130 = phi i1 [ false, %115 ], [ %128, %127 ]
  %131 = zext i1 %130 to i32
  store i32 %131, ptr %5, align 4, !tbaa !11
  br label %155

132:                                              ; preds = %105
  %133 = load ptr, ptr @b3, align 8, !tbaa !5
  %134 = call i32 @BN_is_negative(ptr noundef %133)
  %135 = load ptr, ptr @b2, align 8, !tbaa !5
  %136 = call i32 @BN_is_negative(ptr noundef %135)
  %137 = icmp eq i32 %134, %136
  br i1 %137, label %142, label %138

138:                                              ; preds = %132
  %139 = load ptr, ptr @b3, align 8, !tbaa !5
  %140 = call i32 @BN_is_zero(ptr noundef %139)
  %141 = icmp ne i32 %140, 0
  br i1 %141, label %142, label %152

142:                                              ; preds = %138, %132
  %143 = load ptr, ptr @b4, align 8, !tbaa !5
  %144 = call i32 @BN_is_negative(ptr noundef %143)
  %145 = icmp ne i32 %144, 0
  br i1 %145, label %146, label %150

146:                                              ; preds = %142
  %147 = load ptr, ptr @b4, align 8, !tbaa !5
  %148 = call i32 @BN_is_zero(ptr noundef %147)
  %149 = icmp ne i32 %148, 0
  br label %150

150:                                              ; preds = %146, %142
  %151 = phi i1 [ true, %142 ], [ %149, %146 ]
  br label %152

152:                                              ; preds = %150, %138
  %153 = phi i1 [ false, %138 ], [ %151, %150 ]
  %154 = zext i1 %153 to i32
  store i32 %154, ptr %5, align 4, !tbaa !11
  br label %155

155:                                              ; preds = %152, %129
  br label %156

156:                                              ; preds = %155, %102
  %157 = load ptr, ptr @b5, align 8, !tbaa !5
  %158 = load ptr, ptr @b3, align 8, !tbaa !5
  %159 = load ptr, ptr @b2, align 8, !tbaa !5
  %160 = load ptr, ptr @ctx, align 8, !tbaa !5
  %161 = call i32 @BN_mul(ptr noundef %157, ptr noundef %158, ptr noundef %159, ptr noundef %160)
  %162 = icmp ne i32 %161, 0
  br i1 %162, label %163, label %164

163:                                              ; preds = %156
  br label %166

164:                                              ; preds = %156
  call void @OPENSSL_die(ptr noundef @.str.4, ptr noundef @.str.1, i32 noundef 92) #6
  unreachable

165:                                              ; No predecessors!
  br label %166

166:                                              ; preds = %165, %163
  %167 = phi i32 [ 0, %163 ], [ 1, %165 ]
  %168 = load ptr, ptr @b5, align 8, !tbaa !5
  %169 = load ptr, ptr @b5, align 8, !tbaa !5
  %170 = load ptr, ptr @b4, align 8, !tbaa !5
  %171 = call i32 @BN_add(ptr noundef %168, ptr noundef %169, ptr noundef %170)
  %172 = icmp ne i32 %171, 0
  br i1 %172, label %173, label %174

173:                                              ; preds = %166
  br label %176

174:                                              ; preds = %166
  call void @OPENSSL_die(ptr noundef @.str.5, ptr noundef @.str.1, i32 noundef 93) #6
  unreachable

175:                                              ; No predecessors!
  br label %176

176:                                              ; preds = %175, %173
  %177 = phi i32 [ 0, %173 ], [ 1, %175 ]
  %178 = load i32, ptr %5, align 4, !tbaa !11
  %179 = icmp ne i32 %178, 0
  br i1 %179, label %180, label %185

180:                                              ; preds = %176
  %181 = load ptr, ptr @b5, align 8, !tbaa !5
  %182 = load ptr, ptr @b1, align 8, !tbaa !5
  %183 = call i32 @BN_cmp(ptr noundef %181, ptr noundef %182)
  %184 = icmp eq i32 %183, 0
  br label %185

185:                                              ; preds = %180, %176
  %186 = phi i1 [ false, %176 ], [ %184, %180 ]
  %187 = zext i1 %186 to i32
  store i32 %187, ptr %5, align 4, !tbaa !11
  %188 = load i32, ptr %5, align 4, !tbaa !11
  %189 = icmp ne i32 %188, 0
  br i1 %189, label %244, label %190

190:                                              ; preds = %185
  %191 = load ptr, ptr @stdout, align 8, !tbaa !5
  %192 = load ptr, ptr @b1, align 8, !tbaa !5
  %193 = call i32 @BN_print_fp(ptr noundef %191, ptr noundef %192)
  %194 = call i32 @putchar(i32 noundef 10)
  %195 = load ptr, ptr @stdout, align 8, !tbaa !5
  %196 = load ptr, ptr @b2, align 8, !tbaa !5
  %197 = call i32 @BN_print_fp(ptr noundef %195, ptr noundef %196)
  %198 = call i32 @putchar(i32 noundef 10)
  %199 = load ptr, ptr @stdout, align 8, !tbaa !5
  %200 = load ptr, ptr @b3, align 8, !tbaa !5
  %201 = call i32 @BN_print_fp(ptr noundef %199, ptr noundef %200)
  %202 = call i32 @putchar(i32 noundef 10)
  %203 = load ptr, ptr @stdout, align 8, !tbaa !5
  %204 = load ptr, ptr @b4, align 8, !tbaa !5
  %205 = call i32 @BN_print_fp(ptr noundef %203, ptr noundef %204)
  %206 = call i32 @putchar(i32 noundef 10)
  %207 = load ptr, ptr @stdout, align 8, !tbaa !5
  %208 = load ptr, ptr @b5, align 8, !tbaa !5
  %209 = call i32 @BN_print_fp(ptr noundef %207, ptr noundef %208)
  %210 = call i32 @putchar(i32 noundef 10)
  %211 = load ptr, ptr @b1, align 8, !tbaa !5
  %212 = call i32 @BN_is_negative(ptr noundef %211)
  %213 = load ptr, ptr @b2, align 8, !tbaa !5
  %214 = call i32 @BN_is_negative(ptr noundef %213)
  %215 = load ptr, ptr @b3, align 8, !tbaa !5
  %216 = call i32 @BN_is_negative(ptr noundef %215)
  %217 = load ptr, ptr @b4, align 8, !tbaa !5
  %218 = call i32 @BN_is_negative(ptr noundef %217)
  %219 = load ptr, ptr @b4, align 8, !tbaa !5
  %220 = call i32 @BN_is_zero(ptr noundef %219)
  %221 = load ptr, ptr @b3, align 8, !tbaa !5
  %222 = call i32 @BN_is_negative(ptr noundef %221)
  %223 = load ptr, ptr @b2, align 8, !tbaa !5
  %224 = call i32 @BN_is_negative(ptr noundef %223)
  %225 = icmp ne i32 %222, %224
  br i1 %225, label %226, label %236

226:                                              ; preds = %190
  %227 = load ptr, ptr @b4, align 8, !tbaa !5
  %228 = call i32 @BN_is_negative(ptr noundef %227)
  %229 = icmp ne i32 %228, 0
  br i1 %229, label %234, label %230

230:                                              ; preds = %226
  %231 = load ptr, ptr @b4, align 8, !tbaa !5
  %232 = call i32 @BN_is_zero(ptr noundef %231)
  %233 = icmp ne i32 %232, 0
  br label %234

234:                                              ; preds = %230, %226
  %235 = phi i1 [ true, %226 ], [ %233, %230 ]
  br label %236

236:                                              ; preds = %234, %190
  %237 = phi i1 [ false, %190 ], [ %235, %234 ]
  %238 = zext i1 %237 to i32
  %239 = load ptr, ptr @b5, align 8, !tbaa !5
  %240 = load ptr, ptr @b1, align 8, !tbaa !5
  %241 = call i32 @BN_cmp(ptr noundef %239, ptr noundef %240)
  %242 = call i32 (ptr, ...) @printf(ptr noundef @.str.6, i32 noundef %212, i32 noundef %214, i32 noundef %216, i32 noundef %218, i32 noundef %220, i32 noundef %238, i32 noundef %241)
  %243 = call i32 @puts(ptr noundef @.str.7)
  br label %244

244:                                              ; preds = %236, %185
  br label %245

245:                                              ; preds = %244, %77
  %246 = load i32, ptr %5, align 4, !tbaa !11
  %247 = icmp ne i32 %246, 0
  br i1 %247, label %248, label %249

248:                                              ; preds = %245
  br label %251

249:                                              ; preds = %245
  call void @OPENSSL_die(ptr noundef @.str.8, ptr noundef @.str.1, i32 noundef 117) #6
  unreachable

250:                                              ; No predecessors!
  br label %251

251:                                              ; preds = %250, %248
  %252 = phi i32 [ 0, %248 ], [ 1, %250 ]
  call void @ERR_clear_error()
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #5
  ret i32 0
}

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

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

; Function Attrs: noreturn
declare void @OPENSSL_die(ptr noundef, ptr noundef, i32 noundef) #3

declare void @BN_set_negative(ptr noundef, i32 noundef) #0

declare i32 @BN_is_zero(ptr noundef) #0

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

declare i32 @BN_is_negative(ptr noundef) #0

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

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

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

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

; Function Attrs: inlinehint nounwind uwtable
declare i32 @putchar(i32 noundef) #4

declare i32 @printf(ptr noundef, ...) #0

declare i32 @puts(ptr noundef) #0

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

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 = { 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 #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { noreturn "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 = { inlinehint 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 #5 = { nounwind }
attributes #6 = { noreturn }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!7, !7, i64 0}


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

@b1 = external hidden local_unnamed_addr global ptr, align 8
@b2 = external hidden local_unnamed_addr global ptr, align 8
@b3 = external hidden local_unnamed_addr global ptr, align 8
@b4 = external hidden local_unnamed_addr global ptr, align 8
@b5 = external hidden local_unnamed_addr global ptr, align 8
@ctx = external hidden local_unnamed_addr global ptr, align 8
@.str = external hidden unnamed_addr constant [47 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [62 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [52 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [46 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [42 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [37 x i8], align 1
@stdout = external local_unnamed_addr global ptr, align 8
@.str.6 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [26 x i8], align 1

declare void @ERR_clear_error() local_unnamed_addr #0

; Function Attrs: nounwind uwtable
define dso_local noundef i32 @FuzzerTestOneInput(ptr noundef %0, i64 noundef %1) local_unnamed_addr #1 {
  %.not = icmp eq i64 %1, 0
  br i1 %.not, label %14, label %3

3:                                                ; preds = %2
  %spec.store.select = tail call i64 @llvm.umin.i64(i64 %1, i64 256000)
  %4 = load i8, ptr %0, align 1, !tbaa !5
  %5 = zext i8 %4 to i32
  %6 = and i32 %5, 63
  %7 = trunc nuw nsw i64 %spec.store.select to i32
  %8 = add nsw i32 %7, -1
  %.lhs.trunc = mul nuw nsw i32 %6, %8
  %9 = udiv i32 %.lhs.trunc, 63
  %.zext = zext nneg i32 %9 to i64
  %10 = and i32 %5, 64
  %11 = and i32 %5, 128
  %12 = getelementptr inbounds i8, ptr %0, i64 1
  %13 = sub nsw i32 %8, %9
  br label %14

14:                                               ; preds = %3, %2
  %.023 = phi ptr [ %12, %3 ], [ %0, %2 ]
  %.021 = phi i64 [ %.zext, %3 ], [ 0, %2 ]
  %.020 = phi i32 [ %13, %3 ], [ 0, %2 ]
  %.019 = phi i32 [ %10, %3 ], [ 0, %2 ]
  %.0 = phi i32 [ %11, %3 ], [ 0, %2 ]
  %15 = trunc nuw nsw i64 %.021 to i32
  %16 = load ptr, ptr @b1, align 8, !tbaa !8
  %17 = tail call ptr @BN_bin2bn(ptr noundef %.023, i32 noundef %15, ptr noundef %16) #6
  %18 = load ptr, ptr @b1, align 8, !tbaa !8
  %19 = icmp eq ptr %17, %18
  br i1 %19, label %21, label %20

20:                                               ; preds = %14
  tail call void @OPENSSL_die(ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, i32 noundef 72) #7
  unreachable

21:                                               ; preds = %14
  tail call void @BN_set_negative(ptr noundef %18, i32 noundef %.019) #6
  %22 = getelementptr inbounds i8, ptr %.023, i64 %.021
  %23 = load ptr, ptr @b2, align 8, !tbaa !8
  %24 = tail call ptr @BN_bin2bn(ptr noundef %22, i32 noundef %.020, ptr noundef %23) #6
  %25 = load ptr, ptr @b2, align 8, !tbaa !8
  %26 = icmp eq ptr %24, %25
  br i1 %26, label %28, label %27

27:                                               ; preds = %21
  tail call void @OPENSSL_die(ptr noundef nonnull @.str.2, ptr noundef nonnull @.str.1, i32 noundef 74) #7
  unreachable

28:                                               ; preds = %21
  tail call void @BN_set_negative(ptr noundef %25, i32 noundef %.0) #6
  %29 = load ptr, ptr @b2, align 8, !tbaa !8
  %30 = tail call i32 @BN_is_zero(ptr noundef %29) #6
  %.not26 = icmp eq i32 %30, 0
  br i1 %.not26, label %31, label %.critedge

31:                                               ; preds = %28
  %32 = load ptr, ptr @b3, align 8, !tbaa !8
  %33 = load ptr, ptr @b4, align 8, !tbaa !8
  %34 = load ptr, ptr @b1, align 8, !tbaa !8
  %35 = load ptr, ptr @b2, align 8, !tbaa !8
  %36 = load ptr, ptr @ctx, align 8, !tbaa !8
  %37 = tail call i32 @BN_div(ptr noundef %32, ptr noundef %33, ptr noundef %34, ptr noundef %35, ptr noundef %36) #6
  %.not27 = icmp eq i32 %37, 0
  br i1 %.not27, label %38, label %39

38:                                               ; preds = %31
  tail call void @OPENSSL_die(ptr noundef nonnull @.str.3, ptr noundef nonnull @.str.1, i32 noundef 83) #7
  unreachable

39:                                               ; preds = %31
  %40 = load ptr, ptr @b1, align 8, !tbaa !8
  %41 = tail call i32 @BN_is_zero(ptr noundef %40) #6
  %.not28 = icmp eq i32 %41, 0
  br i1 %.not28, label %45, label %42

42:                                               ; preds = %39
  %43 = load ptr, ptr @b3, align 8, !tbaa !8
  %44 = tail call i32 @BN_is_zero(ptr noundef %43) #6
  %.not35 = icmp eq i32 %44, 0
  br i1 %.not35, label %70, label %.sink.split

45:                                               ; preds = %39
  %46 = load ptr, ptr @b1, align 8, !tbaa !8
  %47 = tail call i32 @BN_is_negative(ptr noundef %46) #6
  %.not29 = icmp eq i32 %47, 0
  %48 = load ptr, ptr @b3, align 8, !tbaa !8
  %49 = tail call i32 @BN_is_negative(ptr noundef %48) #6
  %50 = load ptr, ptr @b2, align 8, !tbaa !8
  %51 = tail call i32 @BN_is_negative(ptr noundef %50) #6
  %52 = icmp eq i32 %49, %51
  br i1 %.not29, label %60, label %53

53:                                               ; preds = %45
  br i1 %52, label %54, label %57

54:                                               ; preds = %53
  %55 = load ptr, ptr @b3, align 8, !tbaa !8
  %56 = tail call i32 @BN_is_zero(ptr noundef %55) #6
  %.not33 = icmp eq i32 %56, 0
  br i1 %.not33, label %70, label %57

57:                                               ; preds = %54, %53
  %58 = load ptr, ptr @b4, align 8, !tbaa !8
  %59 = tail call i32 @BN_is_negative(ptr noundef %58) #6
  %.not34 = icmp eq i32 %59, 0
  br i1 %.not34, label %.sink.split, label %70

60:                                               ; preds = %45
  br i1 %52, label %64, label %61

61:                                               ; preds = %60
  %62 = load ptr, ptr @b3, align 8, !tbaa !8
  %63 = tail call i32 @BN_is_zero(ptr noundef %62) #6
  %.not30 = icmp eq i32 %63, 0
  br i1 %.not30, label %70, label %64

64:                                               ; preds = %61, %60
  %65 = load ptr, ptr @b4, align 8, !tbaa !8
  %66 = tail call i32 @BN_is_negative(ptr noundef %65) #6
  %.not31 = icmp eq i32 %66, 0
  br i1 %.not31, label %70, label %.sink.split

.sink.split:                                      ; preds = %64, %57, %42
  %67 = load ptr, ptr @b4, align 8, !tbaa !8
  %68 = tail call i32 @BN_is_zero(ptr noundef %67) #6
  %69 = icmp ne i32 %68, 0
  br label %70

70:                                               ; preds = %.sink.split, %61, %64, %54, %57, %42
  %.022.shrunk = phi i1 [ false, %42 ], [ false, %54 ], [ true, %57 ], [ false, %61 ], [ true, %64 ], [ %69, %.sink.split ]
  %71 = load ptr, ptr @b5, align 8, !tbaa !8
  %72 = load ptr, ptr @b3, align 8, !tbaa !8
  %73 = load ptr, ptr @b2, align 8, !tbaa !8
  %74 = load ptr, ptr @ctx, align 8, !tbaa !8
  %75 = tail call i32 @BN_mul(ptr noundef %71, ptr noundef %72, ptr noundef %73, ptr noundef %74) #6
  %.not36 = icmp eq i32 %75, 0
  br i1 %.not36, label %76, label %77

76:                                               ; preds = %70
  tail call void @OPENSSL_die(ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.1, i32 noundef 92) #7
  unreachable

77:                                               ; preds = %70
  %78 = load ptr, ptr @b5, align 8, !tbaa !8
  %79 = load ptr, ptr @b4, align 8, !tbaa !8
  %80 = tail call i32 @BN_add(ptr noundef %78, ptr noundef %78, ptr noundef %79) #6
  %.not37 = icmp eq i32 %80, 0
  br i1 %.not37, label %81, label %82

81:                                               ; preds = %77
  tail call void @OPENSSL_die(ptr noundef nonnull @.str.5, ptr noundef nonnull @.str.1, i32 noundef 93) #7
  unreachable

82:                                               ; preds = %77
  br i1 %.022.shrunk, label %83, label %.thread

83:                                               ; preds = %82
  %84 = load ptr, ptr @b5, align 8, !tbaa !8
  %85 = load ptr, ptr @b1, align 8, !tbaa !8
  %86 = tail call i32 @BN_cmp(ptr noundef %84, ptr noundef %85) #6
  %87 = icmp eq i32 %86, 0
  br i1 %87, label %.critedge, label %.thread

.thread:                                          ; preds = %82, %83
  %88 = load ptr, ptr @stdout, align 8, !tbaa !8
  %89 = load ptr, ptr @b1, align 8, !tbaa !8
  %90 = tail call i32 @BN_print_fp(ptr noundef %88, ptr noundef %89) #6
  %91 = tail call i32 @putchar(i32 noundef 10)
  %92 = load ptr, ptr @stdout, align 8, !tbaa !8
  %93 = load ptr, ptr @b2, align 8, !tbaa !8
  %94 = tail call i32 @BN_print_fp(ptr noundef %92, ptr noundef %93) #6
  %95 = tail call i32 @putchar(i32 noundef 10)
  %96 = load ptr, ptr @stdout, align 8, !tbaa !8
  %97 = load ptr, ptr @b3, align 8, !tbaa !8
  %98 = tail call i32 @BN_print_fp(ptr noundef %96, ptr noundef %97) #6
  %99 = tail call i32 @putchar(i32 noundef 10)
  %100 = load ptr, ptr @stdout, align 8, !tbaa !8
  %101 = load ptr, ptr @b4, align 8, !tbaa !8
  %102 = tail call i32 @BN_print_fp(ptr noundef %100, ptr noundef %101) #6
  %103 = tail call i32 @putchar(i32 noundef 10)
  %104 = load ptr, ptr @stdout, align 8, !tbaa !8
  %105 = load ptr, ptr @b5, align 8, !tbaa !8
  %106 = tail call i32 @BN_print_fp(ptr noundef %104, ptr noundef %105) #6
  %107 = tail call i32 @putchar(i32 noundef 10)
  %108 = load ptr, ptr @b1, align 8, !tbaa !8
  %109 = tail call i32 @BN_is_negative(ptr noundef %108) #6
  %110 = load ptr, ptr @b2, align 8, !tbaa !8
  %111 = tail call i32 @BN_is_negative(ptr noundef %110) #6
  %112 = load ptr, ptr @b3, align 8, !tbaa !8
  %113 = tail call i32 @BN_is_negative(ptr noundef %112) #6
  %114 = load ptr, ptr @b4, align 8, !tbaa !8
  %115 = tail call i32 @BN_is_negative(ptr noundef %114) #6
  %116 = load ptr, ptr @b4, align 8, !tbaa !8
  %117 = tail call i32 @BN_is_zero(ptr noundef %116) #6
  %118 = load ptr, ptr @b3, align 8, !tbaa !8
  %119 = tail call i32 @BN_is_negative(ptr noundef %118) #6
  %120 = load ptr, ptr @b2, align 8, !tbaa !8
  %121 = tail call i32 @BN_is_negative(ptr noundef %120) #6
  %.not39 = icmp eq i32 %119, %121
  br i1 %.not39, label %130, label %122

122:                                              ; preds = %.thread
  %123 = load ptr, ptr @b4, align 8, !tbaa !8
  %124 = tail call i32 @BN_is_negative(ptr noundef %123) #6
  %.not40 = icmp eq i32 %124, 0
  br i1 %.not40, label %125, label %130

125:                                              ; preds = %122
  %126 = load ptr, ptr @b4, align 8, !tbaa !8
  %127 = tail call i32 @BN_is_zero(ptr noundef %126) #6
  %128 = icmp ne i32 %127, 0
  %129 = zext i1 %128 to i32
  br label %130

130:                                              ; preds = %.thread, %125, %122
  %131 = phi i32 [ 0, %.thread ], [ 1, %122 ], [ %129, %125 ]
  %132 = load ptr, ptr @b5, align 8, !tbaa !8
  %133 = load ptr, ptr @b1, align 8, !tbaa !8
  %134 = tail call i32 @BN_cmp(ptr noundef %132, ptr noundef %133) #6
  %135 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.6, i32 noundef %109, i32 noundef %111, i32 noundef %113, i32 noundef %115, i32 noundef %117, i32 noundef %131, i32 noundef %134)
  %136 = tail call i32 @puts(ptr noundef nonnull dereferenceable(1) @.str.7)
  tail call void @OPENSSL_die(ptr noundef nonnull @.str.8, ptr noundef nonnull @.str.1, i32 noundef 117) #7
  unreachable

.critedge:                                        ; preds = %83, %28
  tail call void @ERR_clear_error() #6
  ret i32 0
}

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

; Function Attrs: noreturn
declare void @OPENSSL_die(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #2

declare void @BN_set_negative(ptr noundef, i32 noundef) local_unnamed_addr #0

declare i32 @BN_is_zero(ptr noundef) local_unnamed_addr #0

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

declare i32 @BN_is_negative(ptr noundef) local_unnamed_addr #0

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

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

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

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

; Function Attrs: inlinehint nofree nounwind uwtable
declare noundef i32 @putchar(i32 noundef) local_unnamed_addr #3

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

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.umin.i64(i64, i64) #5

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 = { 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 #2 = { noreturn "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 = { inlinehint nofree 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 #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 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { nounwind }
attributes #7 = { 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, !9, i64 0}
!9 = !{!"any pointer", !6, i64 0}


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