; LLVM IR from specinfo-ua/UAPKI :: library/uapkic/src (dstu8845)

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

@.str = external hidden unnamed_addr constant [18 x i8], align 1
@dstu8845_self_test.k256_1_iv_1 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k256_2_iv_1 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k256_1_iv_2 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k256_2_iv_2 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k512_1_iv_1 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k512_2_iv_1 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k512_1_iv_2 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k512_2_iv_2 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.ba_iv_1 = external hidden constant %struct.ByteArray_st, align 8
@dstu8845_self_test.ba_iv_2 = external hidden constant %struct.ByteArray_st, align 8
@dstu8845_self_test.ba_k256_1 = external hidden constant %struct.ByteArray_st, align 8
@dstu8845_self_test.ba_k256_2 = external hidden constant %struct.ByteArray_st, align 8
@dstu8845_self_test.ba_k512_1 = external hidden constant %struct.ByteArray_st, align 8
@dstu8845_self_test.ba_k512_2 = external hidden constant %struct.ByteArray_st, align 8

; Function Attrs: nounwind uwtable
declare dso_local ptr @dstu8845_alloc() #0

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

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

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

declare void @stacktrace_create(ptr noundef, i64 noundef, i32 noundef, ptr noundef) #3

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

declare void @stacktrace_add(ptr noundef, i64 noundef, i32 noundef) #3

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

; Function Attrs: nounwind uwtable
declare dso_local void @dstu8845_free(ptr noundef) #0

declare ptr @ba_alloc_by_len(i64 noundef) #3

declare void @ba_free(ptr noundef) #3

; Function Attrs: nounwind uwtable
define dso_local i32 @dstu8845_self_test() #0 {
  %1 = alloca i32, align 4
  %2 = alloca ptr, align 8
  %3 = alloca ptr, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %1) #5
  store i32 0, ptr %1, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %2) #5
  store ptr null, ptr %2, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %3) #5
  store ptr null, ptr %3, align 8, !tbaa !9
  br label %4

4:                                                ; preds = %0
  %5 = call ptr @ba_alloc_by_len(i64 noundef 64)
  store ptr %5, ptr %3, align 8, !tbaa !9
  %6 = icmp eq ptr null, %5
  br i1 %6, label %7, label %9

7:                                                ; preds = %4
  store i32 2, ptr %1, align 4, !tbaa !5
  %8 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1130, i32 noundef %8)
  br label %324

9:                                                ; preds = %4
  br label %10

10:                                               ; preds = %9
  br label %11

11:                                               ; preds = %10
  br label %12

12:                                               ; preds = %11
  %13 = call ptr @dstu8845_alloc()
  store ptr %13, ptr %2, align 8, !tbaa !9
  %14 = icmp eq ptr null, %13
  br i1 %14, label %15, label %17

15:                                               ; preds = %12
  store i32 2, ptr %1, align 4, !tbaa !5
  %16 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1131, i32 noundef %16)
  br label %324

17:                                               ; preds = %12
  br label %18

18:                                               ; preds = %17
  br label %19

19:                                               ; preds = %18
  %20 = load ptr, ptr %3, align 8, !tbaa !9
  %21 = getelementptr inbounds %struct.ByteArray_st, ptr %20, i32 0, i32 0
  %22 = load ptr, ptr %21, align 8, !tbaa !11
  %23 = load ptr, ptr %3, align 8, !tbaa !9
  %24 = getelementptr inbounds %struct.ByteArray_st, ptr %23, i32 0, i32 1
  %25 = load i64, ptr %24, align 8, !tbaa !14
  call void @llvm.memset.p0.i64(ptr align 1 %22, i8 0, i64 %25, i1 false)
  br label %26

26:                                               ; preds = %19
  %27 = load ptr, ptr %2, align 8, !tbaa !9
  %28 = call i32 @dstu8845_init(ptr noundef %27, ptr noundef @dstu8845_self_test.ba_k256_1, ptr noundef @dstu8845_self_test.ba_iv_1)
  store i32 %28, ptr %1, align 4, !tbaa !5
  %29 = load i32, ptr %1, align 4, !tbaa !5
  %30 = icmp ne i32 %29, 0
  br i1 %30, label %31, label %33

31:                                               ; preds = %26
  %32 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1134, i32 noundef %32)
  br label %324

33:                                               ; preds = %26
  br label %34

34:                                               ; preds = %33
  br label %35

35:                                               ; preds = %34
  br label %36

36:                                               ; preds = %35
  %37 = load ptr, ptr %2, align 8, !tbaa !9
  %38 = load ptr, ptr %3, align 8, !tbaa !9
  %39 = call i32 @dstu8845_crypt(ptr noundef %37, ptr noundef %38)
  store i32 %39, ptr %1, align 4, !tbaa !5
  %40 = load i32, ptr %1, align 4, !tbaa !5
  %41 = icmp ne i32 %40, 0
  br i1 %41, label %42, label %44

42:                                               ; preds = %36
  %43 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1135, i32 noundef %43)
  br label %324

44:                                               ; preds = %36
  br label %45

45:                                               ; preds = %44
  br label %46

46:                                               ; preds = %45
  %47 = load ptr, ptr %3, align 8, !tbaa !9
  %48 = getelementptr inbounds %struct.ByteArray_st, ptr %47, i32 0, i32 0
  %49 = load ptr, ptr %48, align 8, !tbaa !11
  %50 = call i32 @memcmp(ptr noundef %49, ptr noundef @dstu8845_self_test.k256_1_iv_1, i64 noundef 64) #6
  %51 = icmp ne i32 %50, 0
  br i1 %51, label %52, label %57

52:                                               ; preds = %46
  br label %53

53:                                               ; preds = %52
  store i32 33, ptr %1, align 4, !tbaa !5
  %54 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_create(ptr noundef @.str, i64 noundef 1137, i32 noundef %54, ptr noundef null)
  br label %324

55:                                               ; No predecessors!
  br label %56

56:                                               ; preds = %55
  br label %57

57:                                               ; preds = %56, %46
  %58 = load ptr, ptr %3, align 8, !tbaa !9
  %59 = getelementptr inbounds %struct.ByteArray_st, ptr %58, i32 0, i32 0
  %60 = load ptr, ptr %59, align 8, !tbaa !11
  %61 = load ptr, ptr %3, align 8, !tbaa !9
  %62 = getelementptr inbounds %struct.ByteArray_st, ptr %61, i32 0, i32 1
  %63 = load i64, ptr %62, align 8, !tbaa !14
  call void @llvm.memset.p0.i64(ptr align 1 %60, i8 0, i64 %63, i1 false)
  br label %64

64:                                               ; preds = %57
  %65 = load ptr, ptr %2, align 8, !tbaa !9
  %66 = call i32 @dstu8845_init(ptr noundef %65, ptr noundef @dstu8845_self_test.ba_k256_2, ptr noundef @dstu8845_self_test.ba_iv_1)
  store i32 %66, ptr %1, align 4, !tbaa !5
  %67 = load i32, ptr %1, align 4, !tbaa !5
  %68 = icmp ne i32 %67, 0
  br i1 %68, label %69, label %71

69:                                               ; preds = %64
  %70 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1141, i32 noundef %70)
  br label %324

71:                                               ; preds = %64
  br label %72

72:                                               ; preds = %71
  br label %73

73:                                               ; preds = %72
  br label %74

74:                                               ; preds = %73
  %75 = load ptr, ptr %2, align 8, !tbaa !9
  %76 = load ptr, ptr %3, align 8, !tbaa !9
  %77 = call i32 @dstu8845_crypt(ptr noundef %75, ptr noundef %76)
  store i32 %77, ptr %1, align 4, !tbaa !5
  %78 = load i32, ptr %1, align 4, !tbaa !5
  %79 = icmp ne i32 %78, 0
  br i1 %79, label %80, label %82

80:                                               ; preds = %74
  %81 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1142, i32 noundef %81)
  br label %324

82:                                               ; preds = %74
  br label %83

83:                                               ; preds = %82
  br label %84

84:                                               ; preds = %83
  %85 = load ptr, ptr %3, align 8, !tbaa !9
  %86 = getelementptr inbounds %struct.ByteArray_st, ptr %85, i32 0, i32 0
  %87 = load ptr, ptr %86, align 8, !tbaa !11
  %88 = call i32 @memcmp(ptr noundef %87, ptr noundef @dstu8845_self_test.k256_2_iv_1, i64 noundef 64) #6
  %89 = icmp ne i32 %88, 0
  br i1 %89, label %90, label %95

90:                                               ; preds = %84
  br label %91

91:                                               ; preds = %90
  store i32 33, ptr %1, align 4, !tbaa !5
  %92 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_create(ptr noundef @.str, i64 noundef 1144, i32 noundef %92, ptr noundef null)
  br label %324

93:                                               ; No predecessors!
  br label %94

94:                                               ; preds = %93
  br label %95

95:                                               ; preds = %94, %84
  %96 = load ptr, ptr %3, align 8, !tbaa !9
  %97 = getelementptr inbounds %struct.ByteArray_st, ptr %96, i32 0, i32 0
  %98 = load ptr, ptr %97, align 8, !tbaa !11
  %99 = load ptr, ptr %3, align 8, !tbaa !9
  %100 = getelementptr inbounds %struct.ByteArray_st, ptr %99, i32 0, i32 1
  %101 = load i64, ptr %100, align 8, !tbaa !14
  call void @llvm.memset.p0.i64(ptr align 1 %98, i8 0, i64 %101, i1 false)
  br label %102

102:                                              ; preds = %95
  %103 = load ptr, ptr %2, align 8, !tbaa !9
  %104 = call i32 @dstu8845_init(ptr noundef %103, ptr noundef @dstu8845_self_test.ba_k256_1, ptr noundef @dstu8845_self_test.ba_iv_2)
  store i32 %104, ptr %1, align 4, !tbaa !5
  %105 = load i32, ptr %1, align 4, !tbaa !5
  %106 = icmp ne i32 %105, 0
  br i1 %106, label %107, label %109

107:                                              ; preds = %102
  %108 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1148, i32 noundef %108)
  br label %324

109:                                              ; preds = %102
  br label %110

110:                                              ; preds = %109
  br label %111

111:                                              ; preds = %110
  br label %112

112:                                              ; preds = %111
  %113 = load ptr, ptr %2, align 8, !tbaa !9
  %114 = load ptr, ptr %3, align 8, !tbaa !9
  %115 = call i32 @dstu8845_crypt(ptr noundef %113, ptr noundef %114)
  store i32 %115, ptr %1, align 4, !tbaa !5
  %116 = load i32, ptr %1, align 4, !tbaa !5
  %117 = icmp ne i32 %116, 0
  br i1 %117, label %118, label %120

118:                                              ; preds = %112
  %119 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1149, i32 noundef %119)
  br label %324

120:                                              ; preds = %112
  br label %121

121:                                              ; preds = %120
  br label %122

122:                                              ; preds = %121
  %123 = load ptr, ptr %3, align 8, !tbaa !9
  %124 = getelementptr inbounds %struct.ByteArray_st, ptr %123, i32 0, i32 0
  %125 = load ptr, ptr %124, align 8, !tbaa !11
  %126 = call i32 @memcmp(ptr noundef %125, ptr noundef @dstu8845_self_test.k256_1_iv_2, i64 noundef 64) #6
  %127 = icmp ne i32 %126, 0
  br i1 %127, label %128, label %133

128:                                              ; preds = %122
  br label %129

129:                                              ; preds = %128
  store i32 33, ptr %1, align 4, !tbaa !5
  %130 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_create(ptr noundef @.str, i64 noundef 1151, i32 noundef %130, ptr noundef null)
  br label %324

131:                                              ; No predecessors!
  br label %132

132:                                              ; preds = %131
  br label %133

133:                                              ; preds = %132, %122
  %134 = load ptr, ptr %3, align 8, !tbaa !9
  %135 = getelementptr inbounds %struct.ByteArray_st, ptr %134, i32 0, i32 0
  %136 = load ptr, ptr %135, align 8, !tbaa !11
  %137 = load ptr, ptr %3, align 8, !tbaa !9
  %138 = getelementptr inbounds %struct.ByteArray_st, ptr %137, i32 0, i32 1
  %139 = load i64, ptr %138, align 8, !tbaa !14
  call void @llvm.memset.p0.i64(ptr align 1 %136, i8 0, i64 %139, i1 false)
  br label %140

140:                                              ; preds = %133
  %141 = load ptr, ptr %2, align 8, !tbaa !9
  %142 = call i32 @dstu8845_init(ptr noundef %141, ptr noundef @dstu8845_self_test.ba_k256_2, ptr noundef @dstu8845_self_test.ba_iv_2)
  store i32 %142, ptr %1, align 4, !tbaa !5
  %143 = load i32, ptr %1, align 4, !tbaa !5
  %144 = icmp ne i32 %143, 0
  br i1 %144, label %145, label %147

145:                                              ; preds = %140
  %146 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1155, i32 noundef %146)
  br label %324

147:                                              ; preds = %140
  br label %148

148:                                              ; preds = %147
  br label %149

149:                                              ; preds = %148
  br label %150

150:                                              ; preds = %149
  %151 = load ptr, ptr %2, align 8, !tbaa !9
  %152 = load ptr, ptr %3, align 8, !tbaa !9
  %153 = call i32 @dstu8845_crypt(ptr noundef %151, ptr noundef %152)
  store i32 %153, ptr %1, align 4, !tbaa !5
  %154 = load i32, ptr %1, align 4, !tbaa !5
  %155 = icmp ne i32 %154, 0
  br i1 %155, label %156, label %158

156:                                              ; preds = %150
  %157 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1156, i32 noundef %157)
  br label %324

158:                                              ; preds = %150
  br label %159

159:                                              ; preds = %158
  br label %160

160:                                              ; preds = %159
  %161 = load ptr, ptr %3, align 8, !tbaa !9
  %162 = getelementptr inbounds %struct.ByteArray_st, ptr %161, i32 0, i32 0
  %163 = load ptr, ptr %162, align 8, !tbaa !11
  %164 = call i32 @memcmp(ptr noundef %163, ptr noundef @dstu8845_self_test.k256_2_iv_2, i64 noundef 64) #6
  %165 = icmp ne i32 %164, 0
  br i1 %165, label %166, label %171

166:                                              ; preds = %160
  br label %167

167:                                              ; preds = %166
  store i32 33, ptr %1, align 4, !tbaa !5
  %168 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_create(ptr noundef @.str, i64 noundef 1158, i32 noundef %168, ptr noundef null)
  br label %324

169:                                              ; No predecessors!
  br label %170

170:                                              ; preds = %169
  br label %171

171:                                              ; preds = %170, %160
  %172 = load ptr, ptr %3, align 8, !tbaa !9
  %173 = getelementptr inbounds %struct.ByteArray_st, ptr %172, i32 0, i32 0
  %174 = load ptr, ptr %173, align 8, !tbaa !11
  %175 = load ptr, ptr %3, align 8, !tbaa !9
  %176 = getelementptr inbounds %struct.ByteArray_st, ptr %175, i32 0, i32 1
  %177 = load i64, ptr %176, align 8, !tbaa !14
  call void @llvm.memset.p0.i64(ptr align 1 %174, i8 0, i64 %177, i1 false)
  br label %178

178:                                              ; preds = %171
  %179 = load ptr, ptr %2, align 8, !tbaa !9
  %180 = call i32 @dstu8845_init(ptr noundef %179, ptr noundef @dstu8845_self_test.ba_k512_1, ptr noundef @dstu8845_self_test.ba_iv_1)
  store i32 %180, ptr %1, align 4, !tbaa !5
  %181 = load i32, ptr %1, align 4, !tbaa !5
  %182 = icmp ne i32 %181, 0
  br i1 %182, label %183, label %185

183:                                              ; preds = %178
  %184 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1162, i32 noundef %184)
  br label %324

185:                                              ; preds = %178
  br label %186

186:                                              ; preds = %185
  br label %187

187:                                              ; preds = %186
  br label %188

188:                                              ; preds = %187
  %189 = load ptr, ptr %2, align 8, !tbaa !9
  %190 = load ptr, ptr %3, align 8, !tbaa !9
  %191 = call i32 @dstu8845_crypt(ptr noundef %189, ptr noundef %190)
  store i32 %191, ptr %1, align 4, !tbaa !5
  %192 = load i32, ptr %1, align 4, !tbaa !5
  %193 = icmp ne i32 %192, 0
  br i1 %193, label %194, label %196

194:                                              ; preds = %188
  %195 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1163, i32 noundef %195)
  br label %324

196:                                              ; preds = %188
  br label %197

197:                                              ; preds = %196
  br label %198

198:                                              ; preds = %197
  %199 = load ptr, ptr %3, align 8, !tbaa !9
  %200 = getelementptr inbounds %struct.ByteArray_st, ptr %199, i32 0, i32 0
  %201 = load ptr, ptr %200, align 8, !tbaa !11
  %202 = call i32 @memcmp(ptr noundef %201, ptr noundef @dstu8845_self_test.k512_1_iv_1, i64 noundef 64) #6
  %203 = icmp ne i32 %202, 0
  br i1 %203, label %204, label %209

204:                                              ; preds = %198
  br label %205

205:                                              ; preds = %204
  store i32 33, ptr %1, align 4, !tbaa !5
  %206 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_create(ptr noundef @.str, i64 noundef 1165, i32 noundef %206, ptr noundef null)
  br label %324

207:                                              ; No predecessors!
  br label %208

208:                                              ; preds = %207
  br label %209

209:                                              ; preds = %208, %198
  %210 = load ptr, ptr %3, align 8, !tbaa !9
  %211 = getelementptr inbounds %struct.ByteArray_st, ptr %210, i32 0, i32 0
  %212 = load ptr, ptr %211, align 8, !tbaa !11
  %213 = load ptr, ptr %3, align 8, !tbaa !9
  %214 = getelementptr inbounds %struct.ByteArray_st, ptr %213, i32 0, i32 1
  %215 = load i64, ptr %214, align 8, !tbaa !14
  call void @llvm.memset.p0.i64(ptr align 1 %212, i8 0, i64 %215, i1 false)
  br label %216

216:                                              ; preds = %209
  %217 = load ptr, ptr %2, align 8, !tbaa !9
  %218 = call i32 @dstu8845_init(ptr noundef %217, ptr noundef @dstu8845_self_test.ba_k512_2, ptr noundef @dstu8845_self_test.ba_iv_1)
  store i32 %218, ptr %1, align 4, !tbaa !5
  %219 = load i32, ptr %1, align 4, !tbaa !5
  %220 = icmp ne i32 %219, 0
  br i1 %220, label %221, label %223

221:                                              ; preds = %216
  %222 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1169, i32 noundef %222)
  br label %324

223:                                              ; preds = %216
  br label %224

224:                                              ; preds = %223
  br label %225

225:                                              ; preds = %224
  br label %226

226:                                              ; preds = %225
  %227 = load ptr, ptr %2, align 8, !tbaa !9
  %228 = load ptr, ptr %3, align 8, !tbaa !9
  %229 = call i32 @dstu8845_crypt(ptr noundef %227, ptr noundef %228)
  store i32 %229, ptr %1, align 4, !tbaa !5
  %230 = load i32, ptr %1, align 4, !tbaa !5
  %231 = icmp ne i32 %230, 0
  br i1 %231, label %232, label %234

232:                                              ; preds = %226
  %233 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1170, i32 noundef %233)
  br label %324

234:                                              ; preds = %226
  br label %235

235:                                              ; preds = %234
  br label %236

236:                                              ; preds = %235
  %237 = load ptr, ptr %3, align 8, !tbaa !9
  %238 = getelementptr inbounds %struct.ByteArray_st, ptr %237, i32 0, i32 0
  %239 = load ptr, ptr %238, align 8, !tbaa !11
  %240 = call i32 @memcmp(ptr noundef %239, ptr noundef @dstu8845_self_test.k512_2_iv_1, i64 noundef 64) #6
  %241 = icmp ne i32 %240, 0
  br i1 %241, label %242, label %247

242:                                              ; preds = %236
  br label %243

243:                                              ; preds = %242
  store i32 33, ptr %1, align 4, !tbaa !5
  %244 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_create(ptr noundef @.str, i64 noundef 1172, i32 noundef %244, ptr noundef null)
  br label %324

245:                                              ; No predecessors!
  br label %246

246:                                              ; preds = %245
  br label %247

247:                                              ; preds = %246, %236
  %248 = load ptr, ptr %3, align 8, !tbaa !9
  %249 = getelementptr inbounds %struct.ByteArray_st, ptr %248, i32 0, i32 0
  %250 = load ptr, ptr %249, align 8, !tbaa !11
  %251 = load ptr, ptr %3, align 8, !tbaa !9
  %252 = getelementptr inbounds %struct.ByteArray_st, ptr %251, i32 0, i32 1
  %253 = load i64, ptr %252, align 8, !tbaa !14
  call void @llvm.memset.p0.i64(ptr align 1 %250, i8 0, i64 %253, i1 false)
  br label %254

254:                                              ; preds = %247
  %255 = load ptr, ptr %2, align 8, !tbaa !9
  %256 = call i32 @dstu8845_init(ptr noundef %255, ptr noundef @dstu8845_self_test.ba_k512_1, ptr noundef @dstu8845_self_test.ba_iv_2)
  store i32 %256, ptr %1, align 4, !tbaa !5
  %257 = load i32, ptr %1, align 4, !tbaa !5
  %258 = icmp ne i32 %257, 0
  br i1 %258, label %259, label %261

259:                                              ; preds = %254
  %260 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1176, i32 noundef %260)
  br label %324

261:                                              ; preds = %254
  br label %262

262:                                              ; preds = %261
  br label %263

263:                                              ; preds = %262
  br label %264

264:                                              ; preds = %263
  %265 = load ptr, ptr %2, align 8, !tbaa !9
  %266 = load ptr, ptr %3, align 8, !tbaa !9
  %267 = call i32 @dstu8845_crypt(ptr noundef %265, ptr noundef %266)
  store i32 %267, ptr %1, align 4, !tbaa !5
  %268 = load i32, ptr %1, align 4, !tbaa !5
  %269 = icmp ne i32 %268, 0
  br i1 %269, label %270, label %272

270:                                              ; preds = %264
  %271 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1177, i32 noundef %271)
  br label %324

272:                                              ; preds = %264
  br label %273

273:                                              ; preds = %272
  br label %274

274:                                              ; preds = %273
  %275 = load ptr, ptr %3, align 8, !tbaa !9
  %276 = getelementptr inbounds %struct.ByteArray_st, ptr %275, i32 0, i32 0
  %277 = load ptr, ptr %276, align 8, !tbaa !11
  %278 = call i32 @memcmp(ptr noundef %277, ptr noundef @dstu8845_self_test.k512_1_iv_2, i64 noundef 64) #6
  %279 = icmp ne i32 %278, 0
  br i1 %279, label %280, label %285

280:                                              ; preds = %274
  br label %281

281:                                              ; preds = %280
  store i32 33, ptr %1, align 4, !tbaa !5
  %282 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_create(ptr noundef @.str, i64 noundef 1179, i32 noundef %282, ptr noundef null)
  br label %324

283:                                              ; No predecessors!
  br label %284

284:                                              ; preds = %283
  br label %285

285:                                              ; preds = %284, %274
  %286 = load ptr, ptr %3, align 8, !tbaa !9
  %287 = getelementptr inbounds %struct.ByteArray_st, ptr %286, i32 0, i32 0
  %288 = load ptr, ptr %287, align 8, !tbaa !11
  %289 = load ptr, ptr %3, align 8, !tbaa !9
  %290 = getelementptr inbounds %struct.ByteArray_st, ptr %289, i32 0, i32 1
  %291 = load i64, ptr %290, align 8, !tbaa !14
  call void @llvm.memset.p0.i64(ptr align 1 %288, i8 0, i64 %291, i1 false)
  br label %292

292:                                              ; preds = %285
  %293 = load ptr, ptr %2, align 8, !tbaa !9
  %294 = call i32 @dstu8845_init(ptr noundef %293, ptr noundef @dstu8845_self_test.ba_k512_2, ptr noundef @dstu8845_self_test.ba_iv_2)
  store i32 %294, ptr %1, align 4, !tbaa !5
  %295 = load i32, ptr %1, align 4, !tbaa !5
  %296 = icmp ne i32 %295, 0
  br i1 %296, label %297, label %299

297:                                              ; preds = %292
  %298 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1183, i32 noundef %298)
  br label %324

299:                                              ; preds = %292
  br label %300

300:                                              ; preds = %299
  br label %301

301:                                              ; preds = %300
  br label %302

302:                                              ; preds = %301
  %303 = load ptr, ptr %2, align 8, !tbaa !9
  %304 = load ptr, ptr %3, align 8, !tbaa !9
  %305 = call i32 @dstu8845_crypt(ptr noundef %303, ptr noundef %304)
  store i32 %305, ptr %1, align 4, !tbaa !5
  %306 = load i32, ptr %1, align 4, !tbaa !5
  %307 = icmp ne i32 %306, 0
  br i1 %307, label %308, label %310

308:                                              ; preds = %302
  %309 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_add(ptr noundef @.str, i64 noundef 1184, i32 noundef %309)
  br label %324

310:                                              ; preds = %302
  br label %311

311:                                              ; preds = %310
  br label %312

312:                                              ; preds = %311
  %313 = load ptr, ptr %3, align 8, !tbaa !9
  %314 = getelementptr inbounds %struct.ByteArray_st, ptr %313, i32 0, i32 0
  %315 = load ptr, ptr %314, align 8, !tbaa !11
  %316 = call i32 @memcmp(ptr noundef %315, ptr noundef @dstu8845_self_test.k512_2_iv_2, i64 noundef 64) #6
  %317 = icmp ne i32 %316, 0
  br i1 %317, label %318, label %323

318:                                              ; preds = %312
  br label %319

319:                                              ; preds = %318
  store i32 33, ptr %1, align 4, !tbaa !5
  %320 = load i32, ptr %1, align 4, !tbaa !5
  call void @stacktrace_create(ptr noundef @.str, i64 noundef 1186, i32 noundef %320, ptr noundef null)
  br label %324

321:                                              ; No predecessors!
  br label %322

322:                                              ; preds = %321
  br label %323

323:                                              ; preds = %322, %312
  br label %324

324:                                              ; preds = %323, %319, %308, %297, %281, %270, %259, %243, %232, %221, %205, %194, %183, %167, %156, %145, %129, %118, %107, %91, %80, %69, %53, %42, %31, %15, %7
  %325 = load ptr, ptr %3, align 8, !tbaa !9
  call void @ba_free(ptr noundef %325)
  %326 = load ptr, ptr %2, align 8, !tbaa !9
  call void @dstu8845_free(ptr noundef %326)
  %327 = load i32, ptr %1, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %3) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %2) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %1) #5
  ret i32 %327
}

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

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 = { nocallback nofree nounwind willreturn memory(argmem: write) }
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 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 #5 = { nounwind }
attributes #6 = { nounwind willreturn memory(read) }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"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 = !{!12, !10, i64 0}
!12 = !{!"ByteArray_st", !10, i64 0, !13, i64 8}
!13 = !{!"long", !7, i64 0}
!14 = !{!12, !13, i64 8}


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

@.str = external hidden unnamed_addr constant [18 x i8], align 1
@dstu8845_self_test.k256_1_iv_1 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k256_2_iv_1 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k256_1_iv_2 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k256_2_iv_2 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k512_1_iv_1 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k512_2_iv_1 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k512_1_iv_2 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.k512_2_iv_2 = external hidden constant [8 x i64], align 16
@dstu8845_self_test.ba_iv_1 = external hidden constant %struct.ByteArray_st, align 8
@dstu8845_self_test.ba_iv_2 = external hidden constant %struct.ByteArray_st, align 8
@dstu8845_self_test.ba_k256_1 = external hidden constant %struct.ByteArray_st, align 8
@dstu8845_self_test.ba_k256_2 = external hidden constant %struct.ByteArray_st, align 8
@dstu8845_self_test.ba_k512_1 = external hidden constant %struct.ByteArray_st, align 8
@dstu8845_self_test.ba_k512_2 = external hidden constant %struct.ByteArray_st, align 8

; Function Attrs: nounwind uwtable
declare dso_local ptr @dstu8845_alloc() local_unnamed_addr #0

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

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

; Function Attrs: nounwind uwtable
declare dso_local i32 @dstu8845_init(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #0

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

; Function Attrs: nounwind uwtable
declare dso_local i32 @dstu8845_crypt(ptr noundef, ptr noundef) local_unnamed_addr #0

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

declare ptr @ba_alloc_by_len(i64 noundef) local_unnamed_addr #2

declare void @ba_free(ptr noundef) local_unnamed_addr #2

; Function Attrs: nounwind uwtable
define dso_local i32 @dstu8845_self_test() local_unnamed_addr #0 {
  %1 = tail call ptr @ba_alloc_by_len(i64 noundef 64) #4
  %2 = icmp eq ptr %1, null
  br i1 %2, label %3, label %4

3:                                                ; preds = %0
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1130, i32 noundef 2) #4
  br label %90

4:                                                ; preds = %0
  %5 = tail call ptr @dstu8845_alloc()
  %6 = icmp eq ptr %5, null
  br i1 %6, label %7, label %8

7:                                                ; preds = %4
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1131, i32 noundef 2) #4
  br label %90

8:                                                ; preds = %4
  %9 = load ptr, ptr %1, align 8, !tbaa !5
  %10 = getelementptr inbounds i8, ptr %1, i64 8
  %11 = load i64, ptr %10, align 8, !tbaa !11
  tail call void @llvm.memset.p0.i64(ptr align 1 %9, i8 0, i64 %11, i1 false)
  %12 = tail call i32 @dstu8845_init(ptr noundef nonnull %5, ptr noundef nonnull @dstu8845_self_test.ba_k256_1, ptr noundef nonnull @dstu8845_self_test.ba_iv_1)
  %.not = icmp eq i32 %12, 0
  br i1 %.not, label %14, label %13

13:                                               ; preds = %8
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1134, i32 noundef %12) #4
  br label %90

14:                                               ; preds = %8
  %15 = tail call i32 @dstu8845_crypt(ptr noundef nonnull %5, ptr noundef nonnull %1)
  %.not112 = icmp eq i32 %15, 0
  br i1 %.not112, label %17, label %16

16:                                               ; preds = %14
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1135, i32 noundef %15) #4
  br label %90

17:                                               ; preds = %14
  %18 = load ptr, ptr %1, align 8, !tbaa !5
  %bcmp = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(64) %18, ptr noundef nonnull dereferenceable(64) @dstu8845_self_test.k256_1_iv_1, i64 64)
  %.not113 = icmp eq i32 %bcmp, 0
  br i1 %.not113, label %20, label %19

19:                                               ; preds = %17
  tail call void @stacktrace_create(ptr noundef nonnull @.str, i64 noundef 1137, i32 noundef 33, ptr noundef null) #4
  br label %90

20:                                               ; preds = %17
  %21 = load i64, ptr %10, align 8, !tbaa !11
  tail call void @llvm.memset.p0.i64(ptr align 1 %18, i8 0, i64 %21, i1 false)
  %22 = tail call i32 @dstu8845_init(ptr noundef nonnull %5, ptr noundef nonnull @dstu8845_self_test.ba_k256_2, ptr noundef nonnull @dstu8845_self_test.ba_iv_1)
  %.not114 = icmp eq i32 %22, 0
  br i1 %.not114, label %24, label %23

23:                                               ; preds = %20
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1141, i32 noundef %22) #4
  br label %90

24:                                               ; preds = %20
  %25 = tail call i32 @dstu8845_crypt(ptr noundef nonnull %5, ptr noundef nonnull %1)
  %.not115 = icmp eq i32 %25, 0
  br i1 %.not115, label %27, label %26

26:                                               ; preds = %24
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1142, i32 noundef %25) #4
  br label %90

27:                                               ; preds = %24
  %28 = load ptr, ptr %1, align 8, !tbaa !5
  %bcmp116 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(64) %28, ptr noundef nonnull dereferenceable(64) @dstu8845_self_test.k256_2_iv_1, i64 64)
  %.not117 = icmp eq i32 %bcmp116, 0
  br i1 %.not117, label %30, label %29

29:                                               ; preds = %27
  tail call void @stacktrace_create(ptr noundef nonnull @.str, i64 noundef 1144, i32 noundef 33, ptr noundef null) #4
  br label %90

30:                                               ; preds = %27
  %31 = load i64, ptr %10, align 8, !tbaa !11
  tail call void @llvm.memset.p0.i64(ptr align 1 %28, i8 0, i64 %31, i1 false)
  %32 = tail call i32 @dstu8845_init(ptr noundef nonnull %5, ptr noundef nonnull @dstu8845_self_test.ba_k256_1, ptr noundef nonnull @dstu8845_self_test.ba_iv_2)
  %.not118 = icmp eq i32 %32, 0
  br i1 %.not118, label %34, label %33

33:                                               ; preds = %30
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1148, i32 noundef %32) #4
  br label %90

34:                                               ; preds = %30
  %35 = tail call i32 @dstu8845_crypt(ptr noundef nonnull %5, ptr noundef nonnull %1)
  %.not119 = icmp eq i32 %35, 0
  br i1 %.not119, label %37, label %36

36:                                               ; preds = %34
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1149, i32 noundef %35) #4
  br label %90

37:                                               ; preds = %34
  %38 = load ptr, ptr %1, align 8, !tbaa !5
  %bcmp120 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(64) %38, ptr noundef nonnull dereferenceable(64) @dstu8845_self_test.k256_1_iv_2, i64 64)
  %.not121 = icmp eq i32 %bcmp120, 0
  br i1 %.not121, label %40, label %39

39:                                               ; preds = %37
  tail call void @stacktrace_create(ptr noundef nonnull @.str, i64 noundef 1151, i32 noundef 33, ptr noundef null) #4
  br label %90

40:                                               ; preds = %37
  %41 = load i64, ptr %10, align 8, !tbaa !11
  tail call void @llvm.memset.p0.i64(ptr align 1 %38, i8 0, i64 %41, i1 false)
  %42 = tail call i32 @dstu8845_init(ptr noundef nonnull %5, ptr noundef nonnull @dstu8845_self_test.ba_k256_2, ptr noundef nonnull @dstu8845_self_test.ba_iv_2)
  %.not122 = icmp eq i32 %42, 0
  br i1 %.not122, label %44, label %43

43:                                               ; preds = %40
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1155, i32 noundef %42) #4
  br label %90

44:                                               ; preds = %40
  %45 = tail call i32 @dstu8845_crypt(ptr noundef nonnull %5, ptr noundef nonnull %1)
  %.not123 = icmp eq i32 %45, 0
  br i1 %.not123, label %47, label %46

46:                                               ; preds = %44
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1156, i32 noundef %45) #4
  br label %90

47:                                               ; preds = %44
  %48 = load ptr, ptr %1, align 8, !tbaa !5
  %bcmp124 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(64) %48, ptr noundef nonnull dereferenceable(64) @dstu8845_self_test.k256_2_iv_2, i64 64)
  %.not125 = icmp eq i32 %bcmp124, 0
  br i1 %.not125, label %50, label %49

49:                                               ; preds = %47
  tail call void @stacktrace_create(ptr noundef nonnull @.str, i64 noundef 1158, i32 noundef 33, ptr noundef null) #4
  br label %90

50:                                               ; preds = %47
  %51 = load i64, ptr %10, align 8, !tbaa !11
  tail call void @llvm.memset.p0.i64(ptr align 1 %48, i8 0, i64 %51, i1 false)
  %52 = tail call i32 @dstu8845_init(ptr noundef nonnull %5, ptr noundef nonnull @dstu8845_self_test.ba_k512_1, ptr noundef nonnull @dstu8845_self_test.ba_iv_1)
  %.not126 = icmp eq i32 %52, 0
  br i1 %.not126, label %54, label %53

53:                                               ; preds = %50
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1162, i32 noundef %52) #4
  br label %90

54:                                               ; preds = %50
  %55 = tail call i32 @dstu8845_crypt(ptr noundef nonnull %5, ptr noundef nonnull %1)
  %.not127 = icmp eq i32 %55, 0
  br i1 %.not127, label %57, label %56

56:                                               ; preds = %54
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1163, i32 noundef %55) #4
  br label %90

57:                                               ; preds = %54
  %58 = load ptr, ptr %1, align 8, !tbaa !5
  %bcmp128 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(64) %58, ptr noundef nonnull dereferenceable(64) @dstu8845_self_test.k512_1_iv_1, i64 64)
  %.not129 = icmp eq i32 %bcmp128, 0
  br i1 %.not129, label %60, label %59

59:                                               ; preds = %57
  tail call void @stacktrace_create(ptr noundef nonnull @.str, i64 noundef 1165, i32 noundef 33, ptr noundef null) #4
  br label %90

60:                                               ; preds = %57
  %61 = load i64, ptr %10, align 8, !tbaa !11
  tail call void @llvm.memset.p0.i64(ptr align 1 %58, i8 0, i64 %61, i1 false)
  %62 = tail call i32 @dstu8845_init(ptr noundef nonnull %5, ptr noundef nonnull @dstu8845_self_test.ba_k512_2, ptr noundef nonnull @dstu8845_self_test.ba_iv_1)
  %.not130 = icmp eq i32 %62, 0
  br i1 %.not130, label %64, label %63

63:                                               ; preds = %60
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1169, i32 noundef %62) #4
  br label %90

64:                                               ; preds = %60
  %65 = tail call i32 @dstu8845_crypt(ptr noundef nonnull %5, ptr noundef nonnull %1)
  %.not131 = icmp eq i32 %65, 0
  br i1 %.not131, label %67, label %66

66:                                               ; preds = %64
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1170, i32 noundef %65) #4
  br label %90

67:                                               ; preds = %64
  %68 = load ptr, ptr %1, align 8, !tbaa !5
  %bcmp132 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(64) %68, ptr noundef nonnull dereferenceable(64) @dstu8845_self_test.k512_2_iv_1, i64 64)
  %.not133 = icmp eq i32 %bcmp132, 0
  br i1 %.not133, label %70, label %69

69:                                               ; preds = %67
  tail call void @stacktrace_create(ptr noundef nonnull @.str, i64 noundef 1172, i32 noundef 33, ptr noundef null) #4
  br label %90

70:                                               ; preds = %67
  %71 = load i64, ptr %10, align 8, !tbaa !11
  tail call void @llvm.memset.p0.i64(ptr align 1 %68, i8 0, i64 %71, i1 false)
  %72 = tail call i32 @dstu8845_init(ptr noundef nonnull %5, ptr noundef nonnull @dstu8845_self_test.ba_k512_1, ptr noundef nonnull @dstu8845_self_test.ba_iv_2)
  %.not134 = icmp eq i32 %72, 0
  br i1 %.not134, label %74, label %73

73:                                               ; preds = %70
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1176, i32 noundef %72) #4
  br label %90

74:                                               ; preds = %70
  %75 = tail call i32 @dstu8845_crypt(ptr noundef nonnull %5, ptr noundef nonnull %1)
  %.not135 = icmp eq i32 %75, 0
  br i1 %.not135, label %77, label %76

76:                                               ; preds = %74
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1177, i32 noundef %75) #4
  br label %90

77:                                               ; preds = %74
  %78 = load ptr, ptr %1, align 8, !tbaa !5
  %bcmp136 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(64) %78, ptr noundef nonnull dereferenceable(64) @dstu8845_self_test.k512_1_iv_2, i64 64)
  %.not137 = icmp eq i32 %bcmp136, 0
  br i1 %.not137, label %80, label %79

79:                                               ; preds = %77
  tail call void @stacktrace_create(ptr noundef nonnull @.str, i64 noundef 1179, i32 noundef 33, ptr noundef null) #4
  br label %90

80:                                               ; preds = %77
  %81 = load i64, ptr %10, align 8, !tbaa !11
  tail call void @llvm.memset.p0.i64(ptr align 1 %78, i8 0, i64 %81, i1 false)
  %82 = tail call i32 @dstu8845_init(ptr noundef nonnull %5, ptr noundef nonnull @dstu8845_self_test.ba_k512_2, ptr noundef nonnull @dstu8845_self_test.ba_iv_2)
  %.not138 = icmp eq i32 %82, 0
  br i1 %.not138, label %84, label %83

83:                                               ; preds = %80
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1183, i32 noundef %82) #4
  br label %90

84:                                               ; preds = %80
  %85 = tail call i32 @dstu8845_crypt(ptr noundef nonnull %5, ptr noundef nonnull %1)
  %.not139 = icmp eq i32 %85, 0
  br i1 %.not139, label %87, label %86

86:                                               ; preds = %84
  tail call void @stacktrace_add(ptr noundef nonnull @.str, i64 noundef 1184, i32 noundef %85) #4
  br label %90

87:                                               ; preds = %84
  %88 = load ptr, ptr %1, align 8, !tbaa !5
  %bcmp140 = tail call i32 @bcmp(ptr noundef nonnull dereferenceable(64) %88, ptr noundef nonnull dereferenceable(64) @dstu8845_self_test.k512_2_iv_2, i64 64)
  %.not141 = icmp eq i32 %bcmp140, 0
  br i1 %.not141, label %90, label %89

89:                                               ; preds = %87
  tail call void @stacktrace_create(ptr noundef nonnull @.str, i64 noundef 1186, i32 noundef 33, ptr noundef null) #4
  br label %90

90:                                               ; preds = %87, %89, %86, %83, %79, %76, %73, %69, %66, %63, %59, %56, %53, %49, %46, %43, %39, %36, %33, %29, %26, %23, %19, %16, %13, %7, %3
  %.092 = phi i32 [ 2, %3 ], [ 2, %7 ], [ %12, %13 ], [ %15, %16 ], [ 33, %19 ], [ %22, %23 ], [ %25, %26 ], [ 33, %29 ], [ %32, %33 ], [ %35, %36 ], [ 33, %39 ], [ %42, %43 ], [ %45, %46 ], [ 33, %49 ], [ %52, %53 ], [ %55, %56 ], [ 33, %59 ], [ %62, %63 ], [ %65, %66 ], [ 33, %69 ], [ %72, %73 ], [ %75, %76 ], [ 33, %79 ], [ %82, %83 ], [ %85, %86 ], [ 33, %89 ], [ 0, %87 ]
  %.0 = phi ptr [ null, %3 ], [ null, %7 ], [ %5, %13 ], [ %5, %16 ], [ %5, %19 ], [ %5, %23 ], [ %5, %26 ], [ %5, %29 ], [ %5, %33 ], [ %5, %36 ], [ %5, %39 ], [ %5, %43 ], [ %5, %46 ], [ %5, %49 ], [ %5, %53 ], [ %5, %56 ], [ %5, %59 ], [ %5, %63 ], [ %5, %66 ], [ %5, %69 ], [ %5, %73 ], [ %5, %76 ], [ %5, %79 ], [ %5, %83 ], [ %5, %86 ], [ %5, %89 ], [ %5, %87 ]
  tail call void @ba_free(ptr noundef %1) #4
  tail call void @dstu8845_free(ptr noundef %.0)
  ret i32 %.092
}

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

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 nounwind willreturn memory(argmem: write) }
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 = { nofree nounwind willreturn memory(argmem: read) }
attributes #4 = { nounwind }

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

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


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