; LLVM IR from openssl/openssl :: crypto/ec (ecp_oct)

; 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.ec_group_st = type { ptr, ptr, ptr, ptr, i32, i32, i32, i32, ptr, i64, ptr, [6 x i32], ptr, ptr, i32, ptr, ptr, ptr, ptr, i32, %union.anon, ptr, ptr }
%union.anon = type { ptr }
%struct.ec_method_st = type { i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }

@.str = external hidden unnamed_addr constant [69 x i8], align 1
@__func__.ossl_ec_GFp_simple_set_compressed_coordinates = external hidden unnamed_addr constant [46 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local i32 @ossl_ec_GFp_simple_set_compressed_coordinates(ptr noundef %0, ptr noundef %1, ptr noundef %2, i32 noundef %3, ptr noundef %4) #0 {
  %6 = alloca i32, align 4
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca ptr, align 8
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca i64, align 8
  %20 = alloca i32, align 4
  store ptr %0, ptr %7, align 8, !tbaa !5
  store ptr %1, ptr %8, align 8, !tbaa !5
  store ptr %2, ptr %9, align 8, !tbaa !5
  store i32 %3, ptr %10, align 4, !tbaa !9
  store ptr %4, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #4
  store ptr null, ptr %12, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #4
  store i32 0, ptr %17, align 4, !tbaa !9
  %21 = load ptr, ptr %11, align 8, !tbaa !5
  %22 = icmp eq ptr %21, null
  br i1 %22, label %23, label %32

23:                                               ; preds = %5
  %24 = load ptr, ptr %7, align 8, !tbaa !5
  %25 = getelementptr inbounds %struct.ec_group_st, ptr %24, i32 0, i32 21
  %26 = load ptr, ptr %25, align 8, !tbaa !11
  %27 = call ptr @BN_CTX_new_ex(ptr noundef %26)
  store ptr %27, ptr %12, align 8, !tbaa !5
  store ptr %27, ptr %11, align 8, !tbaa !5
  %28 = load ptr, ptr %11, align 8, !tbaa !5
  %29 = icmp eq ptr %28, null
  br i1 %29, label %30, label %31

30:                                               ; preds = %23
  store i32 0, ptr %6, align 4
  store i32 1, ptr %18, align 4
  br label %341

31:                                               ; preds = %23
  br label %32

32:                                               ; preds = %31, %5
  %33 = load i32, ptr %10, align 4, !tbaa !9
  %34 = icmp ne i32 %33, 0
  %35 = zext i1 %34 to i32
  store i32 %35, ptr %10, align 4, !tbaa !9
  %36 = load ptr, ptr %11, align 8, !tbaa !5
  call void @BN_CTX_start(ptr noundef %36)
  %37 = load ptr, ptr %11, align 8, !tbaa !5
  %38 = call ptr @BN_CTX_get(ptr noundef %37)
  store ptr %38, ptr %13, align 8, !tbaa !5
  %39 = load ptr, ptr %11, align 8, !tbaa !5
  %40 = call ptr @BN_CTX_get(ptr noundef %39)
  store ptr %40, ptr %14, align 8, !tbaa !5
  %41 = load ptr, ptr %11, align 8, !tbaa !5
  %42 = call ptr @BN_CTX_get(ptr noundef %41)
  store ptr %42, ptr %15, align 8, !tbaa !5
  %43 = load ptr, ptr %11, align 8, !tbaa !5
  %44 = call ptr @BN_CTX_get(ptr noundef %43)
  store ptr %44, ptr %16, align 8, !tbaa !5
  %45 = load ptr, ptr %16, align 8, !tbaa !5
  %46 = icmp eq ptr %45, null
  br i1 %46, label %47, label %48

47:                                               ; preds = %32
  br label %337

48:                                               ; preds = %32
  %49 = load ptr, ptr %15, align 8, !tbaa !5
  %50 = load ptr, ptr %9, align 8, !tbaa !5
  %51 = load ptr, ptr %7, align 8, !tbaa !5
  %52 = getelementptr inbounds %struct.ec_group_st, ptr %51, i32 0, i32 10
  %53 = load ptr, ptr %52, align 8, !tbaa !14
  %54 = load ptr, ptr %11, align 8, !tbaa !5
  %55 = call i32 @BN_nnmod(ptr noundef %49, ptr noundef %50, ptr noundef %53, ptr noundef %54)
  %56 = icmp ne i32 %55, 0
  br i1 %56, label %58, label %57

57:                                               ; preds = %48
  br label %337

58:                                               ; preds = %48
  %59 = load ptr, ptr %7, align 8, !tbaa !5
  %60 = getelementptr inbounds %struct.ec_group_st, ptr %59, i32 0, i32 0
  %61 = load ptr, ptr %60, align 8, !tbaa !15
  %62 = getelementptr inbounds %struct.ec_method_st, ptr %61, i32 0, i32 37
  %63 = load ptr, ptr %62, align 8, !tbaa !16
  %64 = icmp eq ptr %63, null
  br i1 %64, label %65, label %93

65:                                               ; preds = %58
  %66 = load ptr, ptr %7, align 8, !tbaa !5
  %67 = getelementptr inbounds %struct.ec_group_st, ptr %66, i32 0, i32 0
  %68 = load ptr, ptr %67, align 8, !tbaa !15
  %69 = getelementptr inbounds %struct.ec_method_st, ptr %68, i32 0, i32 33
  %70 = load ptr, ptr %69, align 8, !tbaa !18
  %71 = load ptr, ptr %7, align 8, !tbaa !5
  %72 = load ptr, ptr %14, align 8, !tbaa !5
  %73 = load ptr, ptr %9, align 8, !tbaa !5
  %74 = load ptr, ptr %11, align 8, !tbaa !5
  %75 = call i32 %70(ptr noundef %71, ptr noundef %72, ptr noundef %73, ptr noundef %74)
  %76 = icmp ne i32 %75, 0
  br i1 %76, label %78, label %77

77:                                               ; preds = %65
  br label %337

78:                                               ; preds = %65
  %79 = load ptr, ptr %7, align 8, !tbaa !5
  %80 = getelementptr inbounds %struct.ec_group_st, ptr %79, i32 0, i32 0
  %81 = load ptr, ptr %80, align 8, !tbaa !15
  %82 = getelementptr inbounds %struct.ec_method_st, ptr %81, i32 0, i32 32
  %83 = load ptr, ptr %82, align 8, !tbaa !19
  %84 = load ptr, ptr %7, align 8, !tbaa !5
  %85 = load ptr, ptr %13, align 8, !tbaa !5
  %86 = load ptr, ptr %14, align 8, !tbaa !5
  %87 = load ptr, ptr %9, align 8, !tbaa !5
  %88 = load ptr, ptr %11, align 8, !tbaa !5
  %89 = call i32 %83(ptr noundef %84, ptr noundef %85, ptr noundef %86, ptr noundef %87, ptr noundef %88)
  %90 = icmp ne i32 %89, 0
  br i1 %90, label %92, label %91

91:                                               ; preds = %78
  br label %337

92:                                               ; preds = %78
  br label %115

93:                                               ; preds = %58
  %94 = load ptr, ptr %14, align 8, !tbaa !5
  %95 = load ptr, ptr %9, align 8, !tbaa !5
  %96 = load ptr, ptr %7, align 8, !tbaa !5
  %97 = getelementptr inbounds %struct.ec_group_st, ptr %96, i32 0, i32 10
  %98 = load ptr, ptr %97, align 8, !tbaa !14
  %99 = load ptr, ptr %11, align 8, !tbaa !5
  %100 = call i32 @BN_mod_sqr(ptr noundef %94, ptr noundef %95, ptr noundef %98, ptr noundef %99)
  %101 = icmp ne i32 %100, 0
  br i1 %101, label %103, label %102

102:                                              ; preds = %93
  br label %337

103:                                              ; preds = %93
  %104 = load ptr, ptr %13, align 8, !tbaa !5
  %105 = load ptr, ptr %14, align 8, !tbaa !5
  %106 = load ptr, ptr %9, align 8, !tbaa !5
  %107 = load ptr, ptr %7, align 8, !tbaa !5
  %108 = getelementptr inbounds %struct.ec_group_st, ptr %107, i32 0, i32 10
  %109 = load ptr, ptr %108, align 8, !tbaa !14
  %110 = load ptr, ptr %11, align 8, !tbaa !5
  %111 = call i32 @BN_mod_mul(ptr noundef %104, ptr noundef %105, ptr noundef %106, ptr noundef %109, ptr noundef %110)
  %112 = icmp ne i32 %111, 0
  br i1 %112, label %114, label %113

113:                                              ; preds = %103
  br label %337

114:                                              ; preds = %103
  br label %115

115:                                              ; preds = %114, %92
  %116 = load ptr, ptr %7, align 8, !tbaa !5
  %117 = getelementptr inbounds %struct.ec_group_st, ptr %116, i32 0, i32 14
  %118 = load i32, ptr %117, align 8, !tbaa !20
  %119 = icmp ne i32 %118, 0
  br i1 %119, label %120, label %150

120:                                              ; preds = %115
  %121 = load ptr, ptr %14, align 8, !tbaa !5
  %122 = load ptr, ptr %15, align 8, !tbaa !5
  %123 = load ptr, ptr %7, align 8, !tbaa !5
  %124 = getelementptr inbounds %struct.ec_group_st, ptr %123, i32 0, i32 10
  %125 = load ptr, ptr %124, align 8, !tbaa !14
  %126 = call i32 @BN_mod_lshift1_quick(ptr noundef %121, ptr noundef %122, ptr noundef %125)
  %127 = icmp ne i32 %126, 0
  br i1 %127, label %129, label %128

128:                                              ; preds = %120
  br label %337

129:                                              ; preds = %120
  %130 = load ptr, ptr %14, align 8, !tbaa !5
  %131 = load ptr, ptr %14, align 8, !tbaa !5
  %132 = load ptr, ptr %15, align 8, !tbaa !5
  %133 = load ptr, ptr %7, align 8, !tbaa !5
  %134 = getelementptr inbounds %struct.ec_group_st, ptr %133, i32 0, i32 10
  %135 = load ptr, ptr %134, align 8, !tbaa !14
  %136 = call i32 @BN_mod_add_quick(ptr noundef %130, ptr noundef %131, ptr noundef %132, ptr noundef %135)
  %137 = icmp ne i32 %136, 0
  br i1 %137, label %139, label %138

138:                                              ; preds = %129
  br label %337

139:                                              ; preds = %129
  %140 = load ptr, ptr %13, align 8, !tbaa !5
  %141 = load ptr, ptr %13, align 8, !tbaa !5
  %142 = load ptr, ptr %14, align 8, !tbaa !5
  %143 = load ptr, ptr %7, align 8, !tbaa !5
  %144 = getelementptr inbounds %struct.ec_group_st, ptr %143, i32 0, i32 10
  %145 = load ptr, ptr %144, align 8, !tbaa !14
  %146 = call i32 @BN_mod_sub_quick(ptr noundef %140, ptr noundef %141, ptr noundef %142, ptr noundef %145)
  %147 = icmp ne i32 %146, 0
  br i1 %147, label %149, label %148

148:                                              ; preds = %139
  br label %337

149:                                              ; preds = %139
  br label %212

150:                                              ; preds = %115
  %151 = load ptr, ptr %7, align 8, !tbaa !5
  %152 = getelementptr inbounds %struct.ec_group_st, ptr %151, i32 0, i32 0
  %153 = load ptr, ptr %152, align 8, !tbaa !15
  %154 = getelementptr inbounds %struct.ec_method_st, ptr %153, i32 0, i32 37
  %155 = load ptr, ptr %154, align 8, !tbaa !16
  %156 = icmp ne ptr %155, null
  br i1 %156, label %157, label %184

157:                                              ; preds = %150
  %158 = load ptr, ptr %7, align 8, !tbaa !5
  %159 = getelementptr inbounds %struct.ec_group_st, ptr %158, i32 0, i32 0
  %160 = load ptr, ptr %159, align 8, !tbaa !15
  %161 = getelementptr inbounds %struct.ec_method_st, ptr %160, i32 0, i32 37
  %162 = load ptr, ptr %161, align 8, !tbaa !16
  %163 = load ptr, ptr %7, align 8, !tbaa !5
  %164 = load ptr, ptr %14, align 8, !tbaa !5
  %165 = load ptr, ptr %7, align 8, !tbaa !5
  %166 = getelementptr inbounds %struct.ec_group_st, ptr %165, i32 0, i32 12
  %167 = load ptr, ptr %166, align 8, !tbaa !21
  %168 = load ptr, ptr %11, align 8, !tbaa !5
  %169 = call i32 %162(ptr noundef %163, ptr noundef %164, ptr noundef %167, ptr noundef %168)
  %170 = icmp ne i32 %169, 0
  br i1 %170, label %172, label %171

171:                                              ; preds = %157
  br label %337

172:                                              ; preds = %157
  %173 = load ptr, ptr %14, align 8, !tbaa !5
  %174 = load ptr, ptr %14, align 8, !tbaa !5
  %175 = load ptr, ptr %15, align 8, !tbaa !5
  %176 = load ptr, ptr %7, align 8, !tbaa !5
  %177 = getelementptr inbounds %struct.ec_group_st, ptr %176, i32 0, i32 10
  %178 = load ptr, ptr %177, align 8, !tbaa !14
  %179 = load ptr, ptr %11, align 8, !tbaa !5
  %180 = call i32 @BN_mod_mul(ptr noundef %173, ptr noundef %174, ptr noundef %175, ptr noundef %178, ptr noundef %179)
  %181 = icmp ne i32 %180, 0
  br i1 %181, label %183, label %182

182:                                              ; preds = %172
  br label %337

183:                                              ; preds = %172
  br label %201

184:                                              ; preds = %150
  %185 = load ptr, ptr %7, align 8, !tbaa !5
  %186 = getelementptr inbounds %struct.ec_group_st, ptr %185, i32 0, i32 0
  %187 = load ptr, ptr %186, align 8, !tbaa !15
  %188 = getelementptr inbounds %struct.ec_method_st, ptr %187, i32 0, i32 32
  %189 = load ptr, ptr %188, align 8, !tbaa !19
  %190 = load ptr, ptr %7, align 8, !tbaa !5
  %191 = load ptr, ptr %14, align 8, !tbaa !5
  %192 = load ptr, ptr %7, align 8, !tbaa !5
  %193 = getelementptr inbounds %struct.ec_group_st, ptr %192, i32 0, i32 12
  %194 = load ptr, ptr %193, align 8, !tbaa !21
  %195 = load ptr, ptr %15, align 8, !tbaa !5
  %196 = load ptr, ptr %11, align 8, !tbaa !5
  %197 = call i32 %189(ptr noundef %190, ptr noundef %191, ptr noundef %194, ptr noundef %195, ptr noundef %196)
  %198 = icmp ne i32 %197, 0
  br i1 %198, label %200, label %199

199:                                              ; preds = %184
  br label %337

200:                                              ; preds = %184
  br label %201

201:                                              ; preds = %200, %183
  %202 = load ptr, ptr %13, align 8, !tbaa !5
  %203 = load ptr, ptr %13, align 8, !tbaa !5
  %204 = load ptr, ptr %14, align 8, !tbaa !5
  %205 = load ptr, ptr %7, align 8, !tbaa !5
  %206 = getelementptr inbounds %struct.ec_group_st, ptr %205, i32 0, i32 10
  %207 = load ptr, ptr %206, align 8, !tbaa !14
  %208 = call i32 @BN_mod_add_quick(ptr noundef %202, ptr noundef %203, ptr noundef %204, ptr noundef %207)
  %209 = icmp ne i32 %208, 0
  br i1 %209, label %211, label %210

210:                                              ; preds = %201
  br label %337

211:                                              ; preds = %201
  br label %212

212:                                              ; preds = %211, %149
  %213 = load ptr, ptr %7, align 8, !tbaa !5
  %214 = getelementptr inbounds %struct.ec_group_st, ptr %213, i32 0, i32 0
  %215 = load ptr, ptr %214, align 8, !tbaa !15
  %216 = getelementptr inbounds %struct.ec_method_st, ptr %215, i32 0, i32 37
  %217 = load ptr, ptr %216, align 8, !tbaa !16
  %218 = icmp ne ptr %217, null
  br i1 %218, label %219, label %245

219:                                              ; preds = %212
  %220 = load ptr, ptr %7, align 8, !tbaa !5
  %221 = getelementptr inbounds %struct.ec_group_st, ptr %220, i32 0, i32 0
  %222 = load ptr, ptr %221, align 8, !tbaa !15
  %223 = getelementptr inbounds %struct.ec_method_st, ptr %222, i32 0, i32 37
  %224 = load ptr, ptr %223, align 8, !tbaa !16
  %225 = load ptr, ptr %7, align 8, !tbaa !5
  %226 = load ptr, ptr %14, align 8, !tbaa !5
  %227 = load ptr, ptr %7, align 8, !tbaa !5
  %228 = getelementptr inbounds %struct.ec_group_st, ptr %227, i32 0, i32 13
  %229 = load ptr, ptr %228, align 8, !tbaa !22
  %230 = load ptr, ptr %11, align 8, !tbaa !5
  %231 = call i32 %224(ptr noundef %225, ptr noundef %226, ptr noundef %229, ptr noundef %230)
  %232 = icmp ne i32 %231, 0
  br i1 %232, label %234, label %233

233:                                              ; preds = %219
  br label %337

234:                                              ; preds = %219
  %235 = load ptr, ptr %13, align 8, !tbaa !5
  %236 = load ptr, ptr %13, align 8, !tbaa !5
  %237 = load ptr, ptr %14, align 8, !tbaa !5
  %238 = load ptr, ptr %7, align 8, !tbaa !5
  %239 = getelementptr inbounds %struct.ec_group_st, ptr %238, i32 0, i32 10
  %240 = load ptr, ptr %239, align 8, !tbaa !14
  %241 = call i32 @BN_mod_add_quick(ptr noundef %235, ptr noundef %236, ptr noundef %237, ptr noundef %240)
  %242 = icmp ne i32 %241, 0
  br i1 %242, label %244, label %243

243:                                              ; preds = %234
  br label %337

244:                                              ; preds = %234
  br label %258

245:                                              ; preds = %212
  %246 = load ptr, ptr %13, align 8, !tbaa !5
  %247 = load ptr, ptr %13, align 8, !tbaa !5
  %248 = load ptr, ptr %7, align 8, !tbaa !5
  %249 = getelementptr inbounds %struct.ec_group_st, ptr %248, i32 0, i32 13
  %250 = load ptr, ptr %249, align 8, !tbaa !22
  %251 = load ptr, ptr %7, align 8, !tbaa !5
  %252 = getelementptr inbounds %struct.ec_group_st, ptr %251, i32 0, i32 10
  %253 = load ptr, ptr %252, align 8, !tbaa !14
  %254 = call i32 @BN_mod_add_quick(ptr noundef %246, ptr noundef %247, ptr noundef %250, ptr noundef %253)
  %255 = icmp ne i32 %254, 0
  br i1 %255, label %257, label %256

256:                                              ; preds = %245
  br label %337

257:                                              ; preds = %245
  br label %258

258:                                              ; preds = %257, %244
  %259 = call i32 @ERR_set_mark()
  %260 = load ptr, ptr %16, align 8, !tbaa !5
  %261 = load ptr, ptr %13, align 8, !tbaa !5
  %262 = load ptr, ptr %7, align 8, !tbaa !5
  %263 = getelementptr inbounds %struct.ec_group_st, ptr %262, i32 0, i32 10
  %264 = load ptr, ptr %263, align 8, !tbaa !14
  %265 = load ptr, ptr %11, align 8, !tbaa !5
  %266 = call ptr @BN_mod_sqrt(ptr noundef %260, ptr noundef %261, ptr noundef %264, ptr noundef %265)
  %267 = icmp ne ptr %266, null
  br i1 %267, label %283, label %268

268:                                              ; preds = %258
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #4
  %269 = call i64 @ERR_peek_last_error()
  store i64 %269, ptr %19, align 8, !tbaa !23
  %270 = load i64, ptr %19, align 8, !tbaa !23
  %271 = call i32 @ERR_GET_LIB(i64 noundef %270)
  %272 = icmp eq i32 %271, 3
  br i1 %272, label %273, label %279

273:                                              ; preds = %268
  %274 = load i64, ptr %19, align 8, !tbaa !23
  %275 = call i32 @ERR_GET_REASON(i64 noundef %274)
  %276 = icmp eq i32 %275, 111
  br i1 %276, label %277, label %279

277:                                              ; preds = %273
  %278 = call i32 @ERR_pop_to_mark()
  call void @ERR_new()
  call void @ERR_set_debug(ptr noundef @.str, i32 noundef 112, ptr noundef @__func__.ossl_ec_GFp_simple_set_compressed_coordinates)
  call void (i32, i32, ptr, ...) @ERR_set_error(i32 noundef 16, i32 noundef 110, ptr noundef null)
  br label %281

279:                                              ; preds = %273, %268
  %280 = call i32 @ERR_clear_last_mark()
  call void @ERR_new()
  call void @ERR_set_debug(ptr noundef @.str, i32 noundef 117, ptr noundef @__func__.ossl_ec_GFp_simple_set_compressed_coordinates)
  call void (i32, i32, ptr, ...) @ERR_set_error(i32 noundef 16, i32 noundef 524291, ptr noundef null)
  br label %281

281:                                              ; preds = %279, %277
  store i32 2, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #4
  %282 = load i32, ptr %18, align 4
  switch i32 %282, label %341 [
    i32 2, label %337
  ]

283:                                              ; preds = %258
  %284 = call i32 @ERR_clear_last_mark()
  %285 = load i32, ptr %10, align 4, !tbaa !9
  %286 = load ptr, ptr %16, align 8, !tbaa !5
  %287 = call i32 @BN_is_odd(ptr noundef %286)
  %288 = icmp ne i32 %285, %287
  br i1 %288, label %289, label %321

289:                                              ; preds = %283
  %290 = load ptr, ptr %16, align 8, !tbaa !5
  %291 = call i32 @BN_is_zero(ptr noundef %290)
  %292 = icmp ne i32 %291, 0
  br i1 %292, label %293, label %311

293:                                              ; preds = %289
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #4
  %294 = load ptr, ptr %15, align 8, !tbaa !5
  %295 = load ptr, ptr %7, align 8, !tbaa !5
  %296 = getelementptr inbounds %struct.ec_group_st, ptr %295, i32 0, i32 10
  %297 = load ptr, ptr %296, align 8, !tbaa !14
  %298 = load ptr, ptr %11, align 8, !tbaa !5
  %299 = call i32 @BN_kronecker(ptr noundef %294, ptr noundef %297, ptr noundef %298)
  store i32 %299, ptr %20, align 4, !tbaa !9
  %300 = load i32, ptr %20, align 4, !tbaa !9
  %301 = icmp eq i32 %300, -2
  br i1 %301, label %302, label %303

302:                                              ; preds = %293
  store i32 2, ptr %18, align 4
  br label %309

303:                                              ; preds = %293
  %304 = load i32, ptr %20, align 4, !tbaa !9
  %305 = icmp eq i32 %304, 1
  br i1 %305, label %306, label %307

306:                                              ; preds = %303
  call void @ERR_new()
  call void @ERR_set_debug(ptr noundef @.str, i32 noundef 132, ptr noundef @__func__.ossl_ec_GFp_simple_set_compressed_coordinates)
  call void (i32, i32, ptr, ...) @ERR_set_error(i32 noundef 16, i32 noundef 109, ptr noundef null)
  br label %308

307:                                              ; preds = %303
  call void @ERR_new()
  call void @ERR_set_debug(ptr noundef @.str, i32 noundef 137, ptr noundef @__func__.ossl_ec_GFp_simple_set_compressed_coordinates)
  call void (i32, i32, ptr, ...) @ERR_set_error(i32 noundef 16, i32 noundef 110, ptr noundef null)
  br label %308

308:                                              ; preds = %307, %306
  store i32 2, ptr %18, align 4
  br label %309

309:                                              ; preds = %308, %302
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #4
  %310 = load i32, ptr %18, align 4
  switch i32 %310, label %341 [
    i32 2, label %337
  ]

311:                                              ; preds = %289
  %312 = load ptr, ptr %16, align 8, !tbaa !5
  %313 = load ptr, ptr %7, align 8, !tbaa !5
  %314 = getelementptr inbounds %struct.ec_group_st, ptr %313, i32 0, i32 10
  %315 = load ptr, ptr %314, align 8, !tbaa !14
  %316 = load ptr, ptr %16, align 8, !tbaa !5
  %317 = call i32 @BN_usub(ptr noundef %312, ptr noundef %315, ptr noundef %316)
  %318 = icmp ne i32 %317, 0
  br i1 %318, label %320, label %319

319:                                              ; preds = %311
  br label %337

320:                                              ; preds = %311
  br label %321

321:                                              ; preds = %320, %283
  %322 = load i32, ptr %10, align 4, !tbaa !9
  %323 = load ptr, ptr %16, align 8, !tbaa !5
  %324 = call i32 @BN_is_odd(ptr noundef %323)
  %325 = icmp ne i32 %322, %324
  br i1 %325, label %326, label %327

326:                                              ; preds = %321
  call void @ERR_new()
  call void @ERR_set_debug(ptr noundef @.str, i32 noundef 144, ptr noundef @__func__.ossl_ec_GFp_simple_set_compressed_coordinates)
  call void (i32, i32, ptr, ...) @ERR_set_error(i32 noundef 16, i32 noundef 786691, ptr noundef null)
  br label %337

327:                                              ; preds = %321
  %328 = load ptr, ptr %7, align 8, !tbaa !5
  %329 = load ptr, ptr %8, align 8, !tbaa !5
  %330 = load ptr, ptr %15, align 8, !tbaa !5
  %331 = load ptr, ptr %16, align 8, !tbaa !5
  %332 = load ptr, ptr %11, align 8, !tbaa !5
  %333 = call i32 @EC_POINT_set_affine_coordinates(ptr noundef %328, ptr noundef %329, ptr noundef %330, ptr noundef %331, ptr noundef %332)
  %334 = icmp ne i32 %333, 0
  br i1 %334, label %336, label %335

335:                                              ; preds = %327
  br label %337

336:                                              ; preds = %327
  store i32 1, ptr %17, align 4, !tbaa !9
  br label %337

337:                                              ; preds = %336, %335, %326, %319, %309, %281, %256, %243, %233, %210, %199, %182, %171, %148, %138, %128, %113, %102, %91, %77, %57, %47
  %338 = load ptr, ptr %11, align 8, !tbaa !5
  call void @BN_CTX_end(ptr noundef %338)
  %339 = load ptr, ptr %12, align 8, !tbaa !5
  call void @BN_CTX_free(ptr noundef %339)
  %340 = load i32, ptr %17, align 4, !tbaa !9
  store i32 %340, ptr %6, align 4
  store i32 1, ptr %18, align 4
  br label %341

341:                                              ; preds = %337, %309, %281, %30
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #4
  %342 = load i32, ptr %6, align 4
  ret i32 %342
}

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

declare ptr @BN_CTX_new_ex(ptr noundef) #2

declare void @BN_CTX_start(ptr noundef) #2

declare ptr @BN_CTX_get(ptr noundef) #2

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

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

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

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

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

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

declare i32 @ERR_set_mark() #2

declare ptr @BN_mod_sqrt(ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

declare i64 @ERR_peek_last_error() #2

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @ERR_GET_LIB(i64 noundef) #3

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @ERR_GET_REASON(i64 noundef) #3

declare i32 @ERR_pop_to_mark() #2

declare void @ERR_new() #2

declare void @ERR_set_debug(ptr noundef, i32 noundef, ptr noundef) #2

declare void @ERR_set_error(i32 noundef, i32 noundef, ptr noundef, ...) #2

declare i32 @ERR_clear_last_mark() #2

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

declare i32 @BN_is_odd(ptr noundef) #2

declare i32 @BN_is_zero(ptr noundef) #2

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

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

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

declare void @BN_CTX_end(ptr noundef) #2

declare void @BN_CTX_free(ptr noundef) #2

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 = { 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 #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, !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 = !{!"int", !7, i64 0}
!11 = !{!12, !6, i64 168}
!12 = !{!"ec_group_st", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !10, i64 32, !10, i64 36, !10, i64 40, !10, i64 44, !6, i64 48, !13, i64 56, !6, i64 64, !7, i64 72, !6, i64 96, !6, i64 104, !10, i64 112, !6, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !10, i64 152, !7, i64 160, !6, i64 168, !6, i64 176}
!13 = !{!"long", !7, i64 0}
!14 = !{!12, !6, i64 64}
!15 = !{!12, !6, i64 0}
!16 = !{!17, !6, i64 288}
!17 = !{!"ec_method_st", !10, i64 0, !10, i64 4, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !6, i64 208, !6, i64 216, !6, i64 224, !6, i64 232, !6, i64 240, !6, i64 248, !6, i64 256, !6, i64 264, !6, i64 272, !6, i64 280, !6, i64 288, !6, i64 296, !6, i64 304, !6, i64 312, !6, i64 320, !6, i64 328, !6, i64 336, !6, i64 344, !6, i64 352, !6, i64 360, !6, i64 368, !6, i64 376, !6, i64 384, !6, i64 392, !6, i64 400, !6, i64 408, !6, i64 416, !6, i64 424, !6, i64 432, !6, i64 440}
!18 = !{!17, !6, i64 256}
!19 = !{!17, !6, i64 248}
!20 = !{!12, !10, i64 112}
!21 = !{!12, !6, i64 96}
!22 = !{!12, !6, i64 104}
!23 = !{!13, !13, 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"

@.str = external hidden unnamed_addr constant [69 x i8], align 1
@__func__.ossl_ec_GFp_simple_set_compressed_coordinates = external hidden unnamed_addr constant [46 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local range(i32 0, 2) i32 @ossl_ec_GFp_simple_set_compressed_coordinates(ptr noundef %0, ptr noundef %1, ptr noundef %2, i32 noundef %3, ptr noundef %4) local_unnamed_addr #0 {
  %6 = icmp eq ptr %4, null
  br i1 %6, label %7, label %12

7:                                                ; preds = %5
  %8 = getelementptr inbounds i8, ptr %0, i64 168
  %9 = load ptr, ptr %8, align 8, !tbaa !5
  %10 = tail call ptr @BN_CTX_new_ex(ptr noundef %9) #3
  %11 = icmp eq ptr %10, null
  br i1 %11, label %123, label %12

12:                                               ; preds = %7, %5
  %.0115 = phi ptr [ %10, %7 ], [ null, %5 ]
  %.0114 = phi ptr [ %10, %7 ], [ %4, %5 ]
  %13 = icmp ne i32 %3, 0
  %14 = zext i1 %13 to i32
  tail call void @BN_CTX_start(ptr noundef nonnull %.0114) #3
  %15 = tail call ptr @BN_CTX_get(ptr noundef nonnull %.0114) #3
  %16 = tail call ptr @BN_CTX_get(ptr noundef nonnull %.0114) #3
  %17 = tail call ptr @BN_CTX_get(ptr noundef nonnull %.0114) #3
  %18 = tail call ptr @BN_CTX_get(ptr noundef nonnull %.0114) #3
  %19 = icmp eq ptr %18, null
  br i1 %19, label %122, label %20

20:                                               ; preds = %12
  %21 = getelementptr inbounds i8, ptr %0, i64 64
  %22 = load ptr, ptr %21, align 8, !tbaa !12
  %23 = tail call i32 @BN_nnmod(ptr noundef %17, ptr noundef %2, ptr noundef %22, ptr noundef nonnull %.0114) #3
  %.not = icmp eq i32 %23, 0
  br i1 %.not, label %122, label %24

24:                                               ; preds = %20
  %25 = load ptr, ptr %0, align 8, !tbaa !13
  %26 = getelementptr inbounds i8, ptr %25, i64 288
  %27 = load ptr, ptr %26, align 8, !tbaa !14
  %28 = icmp eq ptr %27, null
  br i1 %28, label %29, label %38

29:                                               ; preds = %24
  %30 = getelementptr inbounds i8, ptr %25, i64 256
  %31 = load ptr, ptr %30, align 8, !tbaa !16
  %32 = tail call i32 %31(ptr noundef nonnull %0, ptr noundef %16, ptr noundef %2, ptr noundef nonnull %.0114) #3
  %.not124 = icmp eq i32 %32, 0
  br i1 %.not124, label %122, label %33

33:                                               ; preds = %29
  %34 = load ptr, ptr %0, align 8, !tbaa !13
  %35 = getelementptr inbounds i8, ptr %34, i64 248
  %36 = load ptr, ptr %35, align 8, !tbaa !17
  %37 = tail call i32 %36(ptr noundef nonnull %0, ptr noundef %15, ptr noundef %16, ptr noundef %2, ptr noundef nonnull %.0114) #3
  %.not125 = icmp eq i32 %37, 0
  br i1 %.not125, label %122, label %44

38:                                               ; preds = %24
  %39 = load ptr, ptr %21, align 8, !tbaa !12
  %40 = tail call i32 @BN_mod_sqr(ptr noundef %16, ptr noundef %2, ptr noundef %39, ptr noundef nonnull %.0114) #3
  %.not122 = icmp eq i32 %40, 0
  br i1 %.not122, label %122, label %41

41:                                               ; preds = %38
  %42 = load ptr, ptr %21, align 8, !tbaa !12
  %43 = tail call i32 @BN_mod_mul(ptr noundef %15, ptr noundef %16, ptr noundef %2, ptr noundef %42, ptr noundef nonnull %.0114) #3
  %.not123 = icmp eq i32 %43, 0
  br i1 %.not123, label %122, label %44

44:                                               ; preds = %41, %33
  %45 = getelementptr inbounds i8, ptr %0, i64 112
  %46 = load i32, ptr %45, align 8, !tbaa !18
  %.not126 = icmp eq i32 %46, 0
  br i1 %.not126, label %56, label %47

47:                                               ; preds = %44
  %48 = load ptr, ptr %21, align 8, !tbaa !12
  %49 = tail call i32 @BN_mod_lshift1_quick(ptr noundef %16, ptr noundef %17, ptr noundef %48) #3
  %.not132 = icmp eq i32 %49, 0
  br i1 %.not132, label %122, label %50

50:                                               ; preds = %47
  %51 = load ptr, ptr %21, align 8, !tbaa !12
  %52 = tail call i32 @BN_mod_add_quick(ptr noundef %16, ptr noundef %16, ptr noundef %17, ptr noundef %51) #3
  %.not133 = icmp eq i32 %52, 0
  br i1 %.not133, label %122, label %53

53:                                               ; preds = %50
  %54 = load ptr, ptr %21, align 8, !tbaa !12
  %55 = tail call i32 @BN_mod_sub_quick(ptr noundef %15, ptr noundef %15, ptr noundef %16, ptr noundef %54) #3
  %.not134 = icmp eq i32 %55, 0
  br i1 %.not134, label %122, label %76

56:                                               ; preds = %44
  %57 = load ptr, ptr %0, align 8, !tbaa !13
  %58 = getelementptr inbounds i8, ptr %57, i64 288
  %59 = load ptr, ptr %58, align 8, !tbaa !14
  %.not127 = icmp eq ptr %59, null
  br i1 %.not127, label %67, label %60

60:                                               ; preds = %56
  %61 = getelementptr inbounds i8, ptr %0, i64 96
  %62 = load ptr, ptr %61, align 8, !tbaa !19
  %63 = tail call i32 %59(ptr noundef nonnull %0, ptr noundef %16, ptr noundef %62, ptr noundef nonnull %.0114) #3
  %.not129 = icmp eq i32 %63, 0
  br i1 %.not129, label %122, label %64

64:                                               ; preds = %60
  %65 = load ptr, ptr %21, align 8, !tbaa !12
  %66 = tail call i32 @BN_mod_mul(ptr noundef %16, ptr noundef %16, ptr noundef %17, ptr noundef %65, ptr noundef nonnull %.0114) #3
  %.not130 = icmp eq i32 %66, 0
  br i1 %.not130, label %122, label %73

67:                                               ; preds = %56
  %68 = getelementptr inbounds i8, ptr %57, i64 248
  %69 = load ptr, ptr %68, align 8, !tbaa !17
  %70 = getelementptr inbounds i8, ptr %0, i64 96
  %71 = load ptr, ptr %70, align 8, !tbaa !19
  %72 = tail call i32 %69(ptr noundef nonnull %0, ptr noundef %16, ptr noundef %71, ptr noundef %17, ptr noundef nonnull %.0114) #3
  %.not128 = icmp eq i32 %72, 0
  br i1 %.not128, label %122, label %73

73:                                               ; preds = %67, %64
  %74 = load ptr, ptr %21, align 8, !tbaa !12
  %75 = tail call i32 @BN_mod_add_quick(ptr noundef %15, ptr noundef %15, ptr noundef %16, ptr noundef %74) #3
  %.not131 = icmp eq i32 %75, 0
  br i1 %.not131, label %122, label %76

76:                                               ; preds = %73, %53
  %77 = load ptr, ptr %0, align 8, !tbaa !13
  %78 = getelementptr inbounds i8, ptr %77, i64 288
  %79 = load ptr, ptr %78, align 8, !tbaa !14
  %.not135 = icmp eq ptr %79, null
  %80 = getelementptr inbounds i8, ptr %0, i64 104
  %81 = load ptr, ptr %80, align 8, !tbaa !20
  br i1 %.not135, label %87, label %82

82:                                               ; preds = %76
  %83 = tail call i32 %79(ptr noundef nonnull %0, ptr noundef %16, ptr noundef %81, ptr noundef nonnull %.0114) #3
  %.not137 = icmp eq i32 %83, 0
  br i1 %.not137, label %122, label %84

84:                                               ; preds = %82
  %85 = load ptr, ptr %21, align 8, !tbaa !12
  %86 = tail call i32 @BN_mod_add_quick(ptr noundef %15, ptr noundef %15, ptr noundef %16, ptr noundef %85) #3
  %.not138 = icmp eq i32 %86, 0
  br i1 %.not138, label %122, label %90

87:                                               ; preds = %76
  %88 = load ptr, ptr %21, align 8, !tbaa !12
  %89 = tail call i32 @BN_mod_add_quick(ptr noundef %15, ptr noundef %15, ptr noundef %81, ptr noundef %88) #3
  %.not136 = icmp eq i32 %89, 0
  br i1 %.not136, label %122, label %90

90:                                               ; preds = %87, %84
  %91 = tail call i32 @ERR_set_mark() #3
  %92 = load ptr, ptr %21, align 8, !tbaa !12
  %93 = tail call ptr @BN_mod_sqrt(ptr noundef nonnull %18, ptr noundef %15, ptr noundef %92, ptr noundef nonnull %.0114) #3
  %.not139 = icmp eq ptr %93, null
  br i1 %.not139, label %94, label %105

94:                                               ; preds = %90
  %95 = tail call i64 @ERR_peek_last_error() #3
  %96 = tail call i32 @ERR_GET_LIB(i64 noundef %95)
  %97 = icmp eq i32 %96, 3
  br i1 %97, label %98, label %103

98:                                               ; preds = %94
  %99 = tail call i32 @ERR_GET_REASON(i64 noundef %95)
  %100 = icmp eq i32 %99, 111
  br i1 %100, label %101, label %103

101:                                              ; preds = %98
  %102 = tail call i32 @ERR_pop_to_mark() #3
  tail call void @ERR_new() #3
  tail call void @ERR_set_debug(ptr noundef nonnull @.str, i32 noundef 112, ptr noundef nonnull @__func__.ossl_ec_GFp_simple_set_compressed_coordinates) #3
  tail call void (i32, i32, ptr, ...) @ERR_set_error(i32 noundef 16, i32 noundef 110, ptr noundef null) #3
  br label %122

103:                                              ; preds = %98, %94
  %104 = tail call i32 @ERR_clear_last_mark() #3
  tail call void @ERR_new() #3
  tail call void @ERR_set_debug(ptr noundef nonnull @.str, i32 noundef 117, ptr noundef nonnull @__func__.ossl_ec_GFp_simple_set_compressed_coordinates) #3
  tail call void (i32, i32, ptr, ...) @ERR_set_error(i32 noundef 16, i32 noundef 524291, ptr noundef null) #3
  br label %122

105:                                              ; preds = %90
  %106 = tail call i32 @ERR_clear_last_mark() #3
  %107 = tail call i32 @BN_is_odd(ptr noundef nonnull %18) #3
  %.not140 = icmp eq i32 %107, %14
  br i1 %.not140, label %117, label %108

108:                                              ; preds = %105
  %109 = tail call i32 @BN_is_zero(ptr noundef nonnull %18) #3
  %.not141 = icmp eq i32 %109, 0
  %110 = load ptr, ptr %21, align 8, !tbaa !12
  br i1 %.not141, label %115, label %111

111:                                              ; preds = %108
  %112 = tail call i32 @BN_kronecker(ptr noundef %17, ptr noundef %110, ptr noundef nonnull %.0114) #3
  switch i32 %112, label %114 [
    i32 -2, label %122
    i32 1, label %113
  ]

113:                                              ; preds = %111
  tail call void @ERR_new() #3
  tail call void @ERR_set_debug(ptr noundef nonnull @.str, i32 noundef 132, ptr noundef nonnull @__func__.ossl_ec_GFp_simple_set_compressed_coordinates) #3
  tail call void (i32, i32, ptr, ...) @ERR_set_error(i32 noundef 16, i32 noundef 109, ptr noundef null) #3
  br label %122

114:                                              ; preds = %111
  tail call void @ERR_new() #3
  tail call void @ERR_set_debug(ptr noundef nonnull @.str, i32 noundef 137, ptr noundef nonnull @__func__.ossl_ec_GFp_simple_set_compressed_coordinates) #3
  tail call void (i32, i32, ptr, ...) @ERR_set_error(i32 noundef 16, i32 noundef 110, ptr noundef null) #3
  br label %122

115:                                              ; preds = %108
  %116 = tail call i32 @BN_usub(ptr noundef nonnull %18, ptr noundef %110, ptr noundef nonnull %18) #3
  %.not142 = icmp eq i32 %116, 0
  br i1 %.not142, label %122, label %117

117:                                              ; preds = %115, %105
  %118 = tail call i32 @BN_is_odd(ptr noundef nonnull %18) #3
  %.not143 = icmp eq i32 %118, %14
  br i1 %.not143, label %120, label %119

119:                                              ; preds = %117
  tail call void @ERR_new() #3
  tail call void @ERR_set_debug(ptr noundef nonnull @.str, i32 noundef 144, ptr noundef nonnull @__func__.ossl_ec_GFp_simple_set_compressed_coordinates) #3
  tail call void (i32, i32, ptr, ...) @ERR_set_error(i32 noundef 16, i32 noundef 786691, ptr noundef null) #3
  br label %122

120:                                              ; preds = %117
  %121 = tail call i32 @EC_POINT_set_affine_coordinates(ptr noundef nonnull %0, ptr noundef %1, ptr noundef %17, ptr noundef nonnull %18, ptr noundef nonnull %.0114) #3
  %.not144 = icmp ne i32 %121, 0
  %spec.select = zext i1 %.not144 to i32
  br label %122

122:                                              ; preds = %120, %111, %114, %113, %101, %103, %115, %87, %84, %82, %73, %67, %64, %60, %53, %50, %47, %41, %38, %33, %29, %20, %12, %119
  %.0113 = phi i32 [ 0, %12 ], [ 0, %119 ], [ 0, %115 ], [ 0, %84 ], [ 0, %82 ], [ 0, %87 ], [ 0, %53 ], [ 0, %50 ], [ 0, %47 ], [ 0, %73 ], [ 0, %64 ], [ 0, %60 ], [ 0, %67 ], [ 0, %33 ], [ 0, %29 ], [ 0, %41 ], [ 0, %38 ], [ 0, %20 ], [ 0, %103 ], [ 0, %101 ], [ 0, %113 ], [ 0, %114 ], [ 0, %111 ], [ %spec.select, %120 ]
  tail call void @BN_CTX_end(ptr noundef nonnull %.0114) #3
  tail call void @BN_CTX_free(ptr noundef %.0115) #3
  br label %123

123:                                              ; preds = %7, %122
  %.0 = phi i32 [ %.0113, %122 ], [ 0, %7 ]
  ret i32 %.0
}

declare ptr @BN_CTX_new_ex(ptr noundef) local_unnamed_addr #1

declare void @BN_CTX_start(ptr noundef) local_unnamed_addr #1

declare ptr @BN_CTX_get(ptr noundef) local_unnamed_addr #1

declare i32 @BN_nnmod(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare i32 @BN_mod_sqr(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare i32 @BN_mod_mul(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare i32 @BN_mod_lshift1_quick(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare i32 @BN_mod_add_quick(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare i32 @BN_mod_sub_quick(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare i32 @ERR_set_mark() local_unnamed_addr #1

declare ptr @BN_mod_sqrt(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare i64 @ERR_peek_last_error() local_unnamed_addr #1

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @ERR_GET_LIB(i64 noundef) local_unnamed_addr #2

; Function Attrs: inlinehint nounwind uwtable
declare hidden i32 @ERR_GET_REASON(i64 noundef) local_unnamed_addr #2

declare i32 @ERR_pop_to_mark() local_unnamed_addr #1

declare void @ERR_new() local_unnamed_addr #1

declare void @ERR_set_debug(ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

declare void @ERR_set_error(i32 noundef, i32 noundef, ptr noundef, ...) local_unnamed_addr #1

declare i32 @ERR_clear_last_mark() local_unnamed_addr #1

declare i32 @BN_is_odd(ptr noundef) local_unnamed_addr #1

declare i32 @BN_is_zero(ptr noundef) local_unnamed_addr #1

declare i32 @BN_kronecker(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare i32 @BN_usub(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare i32 @EC_POINT_set_affine_coordinates(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare void @BN_CTX_end(ptr noundef) local_unnamed_addr #1

declare void @BN_CTX_free(ptr noundef) local_unnamed_addr #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 = { "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 = { 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 #3 = { 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 168}
!6 = !{!"ec_group_st", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !10, i64 32, !10, i64 36, !10, i64 40, !10, i64 44, !7, i64 48, !11, i64 56, !7, i64 64, !8, i64 72, !7, i64 96, !7, i64 104, !10, i64 112, !7, i64 120, !7, i64 128, !7, i64 136, !7, i64 144, !10, i64 152, !8, i64 160, !7, i64 168, !7, i64 176}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"int", !8, i64 0}
!11 = !{!"long", !8, i64 0}
!12 = !{!6, !7, i64 64}
!13 = !{!6, !7, i64 0}
!14 = !{!15, !7, i64 288}
!15 = !{!"ec_method_st", !10, i64 0, !10, i64 4, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !7, i64 56, !7, i64 64, !7, i64 72, !7, i64 80, !7, i64 88, !7, i64 96, !7, i64 104, !7, i64 112, !7, i64 120, !7, i64 128, !7, i64 136, !7, i64 144, !7, i64 152, !7, i64 160, !7, i64 168, !7, i64 176, !7, i64 184, !7, i64 192, !7, i64 200, !7, i64 208, !7, i64 216, !7, i64 224, !7, i64 232, !7, i64 240, !7, i64 248, !7, i64 256, !7, i64 264, !7, i64 272, !7, i64 280, !7, i64 288, !7, i64 296, !7, i64 304, !7, i64 312, !7, i64 320, !7, i64 328, !7, i64 336, !7, i64 344, !7, i64 352, !7, i64 360, !7, i64 368, !7, i64 376, !7, i64 384, !7, i64 392, !7, i64 400, !7, i64 408, !7, i64 416, !7, i64 424, !7, i64 432, !7, i64 440}
!16 = !{!15, !7, i64 256}
!17 = !{!15, !7, i64 248}
!18 = !{!6, !10, i64 112}
!19 = !{!6, !7, i64 96}
!20 = !{!6, !7, i64 104}


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