; LLVM IR from cvxgrp/scs :: test (random_socp_prob)

; 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.ScsInfo = type { i32, [128 x i8], [128 x i8], i32, i32, double, double, double, double, double, double, double, double, double, double, double, double, i32, i32, double, double, double }
%struct.ScsCone = type { i32, i32, ptr, ptr, i32, ptr, i32, ptr, i32, i32, i32, ptr, i32 }
%struct.ScsData = type { i32, i32, ptr, ptr, ptr, ptr }
%struct.ScsSolution = type { ptr, ptr, ptr }

@.str.21 = external hidden unnamed_addr constant [469 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [60 x i8], align 1
@.str.23 = external hidden unnamed_addr constant [57 x i8], align 1
@.str.24 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.25 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.26 = external hidden unnamed_addr constant [49 x i8], align 1
@.str.27 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.28 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.29 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.30 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.31 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.32 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.33 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.34 = external hidden unnamed_addr constant [67 x i8], align 1
@.str.35 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.36 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.37 = external hidden unnamed_addr constant [44 x i8], align 1
@.str.38 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.39 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.40 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.41 = external hidden unnamed_addr constant [19 x i8], align 1

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

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

; Function Attrs: nounwind uwtable
declare dso_local void @gen_random_prob_data(i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, i32 noundef) #1

; Function Attrs: nounwind allocsize(0,1)
declare noalias ptr @calloc(i64 noundef, i64 noundef) #2

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

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

declare double @_scs_dot(ptr noundef, ptr noundef, i32 noundef) #5

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

; Function Attrs: nounwind uwtable
define dso_local i32 @main(i32 noundef %0, ptr noundef %1) #1 {
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca ptr, align 8
  %17 = alloca ptr, align 8
  %18 = alloca ptr, align 8
  %19 = alloca %struct.ScsInfo, align 8
  %20 = alloca double, align 8
  %21 = alloca double, align 8
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  store i32 0, ptr %3, align 4
  store i32 %0, ptr %4, align 4, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #9
  call void @llvm.lifetime.start.p0(i64 400, ptr %19) #9
  call void @llvm.memset.p0.i64(ptr align 8 %19, i8 0, i64 400, i1 false)
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #9
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #9
  store i32 4, ptr %22, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #9
  store i32 0, ptr %23, align 4, !tbaa !5
  store double 1.000000e-01, ptr %20, align 8, !tbaa !11
  store double 3.000000e-01, ptr %21, align 8, !tbaa !11
  %26 = call i64 @time(ptr noundef null) #9
  %27 = trunc i64 %26 to i32
  store i32 %27, ptr %23, align 4, !tbaa !5
  %28 = load i32, ptr %4, align 4, !tbaa !5
  switch i32 %28, label %48 [
    i32 5, label %29
    i32 4, label %34
    i32 2, label %43
  ]

29:                                               ; preds = %2
  %30 = load ptr, ptr %5, align 8, !tbaa !9
  %31 = getelementptr inbounds ptr, ptr %30, i64 4
  %32 = load ptr, ptr %31, align 8, !tbaa !9
  %33 = call i32 @atoi(ptr noundef %32) #10
  store i32 %33, ptr %23, align 4, !tbaa !5
  br label %34

34:                                               ; preds = %29, %2
  %35 = load ptr, ptr %5, align 8, !tbaa !9
  %36 = getelementptr inbounds ptr, ptr %35, i64 2
  %37 = load ptr, ptr %36, align 8, !tbaa !9
  %38 = call double @atof(ptr noundef %37) #10
  store double %38, ptr %20, align 8, !tbaa !11
  %39 = load ptr, ptr %5, align 8, !tbaa !9
  %40 = getelementptr inbounds ptr, ptr %39, i64 3
  %41 = load ptr, ptr %40, align 8, !tbaa !9
  %42 = call double @atof(ptr noundef %41) #10
  store double %42, ptr %21, align 8, !tbaa !11
  br label %43

43:                                               ; preds = %34, %2
  %44 = load ptr, ptr %5, align 8, !tbaa !9
  %45 = getelementptr inbounds ptr, ptr %44, i64 1
  %46 = load ptr, ptr %45, align 8, !tbaa !9
  %47 = call i32 @atoi(ptr noundef %46) #10
  store i32 %47, ptr %6, align 4, !tbaa !5
  br label %61

48:                                               ; preds = %2
  %49 = load ptr, ptr %5, align 8, !tbaa !9
  %50 = getelementptr inbounds ptr, ptr %49, i64 0
  %51 = load ptr, ptr %50, align 8, !tbaa !9
  %52 = call i32 (ptr, ...) @printf(ptr noundef @.str.21, ptr noundef %51)
  %53 = load ptr, ptr %5, align 8, !tbaa !9
  %54 = getelementptr inbounds ptr, ptr %53, i64 0
  %55 = load ptr, ptr %54, align 8, !tbaa !9
  %56 = call i32 (ptr, ...) @printf(ptr noundef @.str.22, ptr noundef %55)
  %57 = load ptr, ptr %5, align 8, !tbaa !9
  %58 = getelementptr inbounds ptr, ptr %57, i64 0
  %59 = load ptr, ptr %58, align 8, !tbaa !9
  %60 = call i32 (ptr, ...) @printf(ptr noundef @.str.23, ptr noundef %59)
  store i32 0, ptr %3, align 4
  store i32 1, ptr %24, align 4
  br label %405

61:                                               ; preds = %43
  %62 = load i32, ptr %23, align 4, !tbaa !5
  %63 = call i32 (ptr, ...) @printf(ptr noundef @.str.24, i32 noundef %62)
  %64 = call noalias ptr @calloc(i64 noundef 1, i64 noundef 88) #11
  store ptr %64, ptr %14, align 8, !tbaa !9
  %65 = call noalias ptr @calloc(i64 noundef 1, i64 noundef 40) #11
  store ptr %65, ptr %15, align 8, !tbaa !9
  %66 = call noalias ptr @calloc(i64 noundef 1, i64 noundef 112) #11
  store ptr %66, ptr %16, align 8, !tbaa !9
  %67 = call noalias ptr @calloc(i64 noundef 1, i64 noundef 24) #11
  store ptr %67, ptr %17, align 8, !tbaa !9
  %68 = call noalias ptr @calloc(i64 noundef 1, i64 noundef 24) #11
  store ptr %68, ptr %18, align 8, !tbaa !9
  %69 = load i32, ptr %22, align 4, !tbaa !5
  %70 = load i32, ptr %6, align 4, !tbaa !5
  %71 = mul nsw i32 %69, %70
  store i32 %71, ptr %7, align 4, !tbaa !5
  %72 = load i32, ptr %6, align 4, !tbaa !5
  %73 = sitofp i32 %72 to double
  %74 = call double @sqrt(double noundef %73) #9
  %75 = call double @llvm.ceil.f64(double %74)
  %76 = fptosi double %75 to i32
  store i32 %76, ptr %8, align 4, !tbaa !5
  %77 = load i32, ptr %6, align 4, !tbaa !5
  %78 = load i32, ptr %8, align 4, !tbaa !5
  %79 = mul nsw i32 %77, %78
  store i32 %79, ptr %9, align 4, !tbaa !5
  %80 = load i32, ptr %22, align 4, !tbaa !5
  %81 = load i32, ptr %6, align 4, !tbaa !5
  %82 = mul nsw i32 %80, %81
  %83 = sitofp i32 %82 to double
  %84 = load i32, ptr %22, align 4, !tbaa !5
  %85 = load i32, ptr %6, align 4, !tbaa !5
  %86 = mul nsw i32 %84, %85
  %87 = sitofp i32 %86 to double
  %88 = call double @log(double noundef %87) #9
  %89 = fdiv double %83, %88
  %90 = call double @llvm.ceil.f64(double %89)
  %91 = fptosi double %90 to i32
  store i32 %91, ptr %13, align 4, !tbaa !5
  %92 = load double, ptr %20, align 8, !tbaa !11
  %93 = load double, ptr %21, align 8, !tbaa !11
  %94 = fadd double %92, %93
  %95 = fcmp ogt double %94, 1.000000e+00
  br i1 %95, label %96, label %98

96:                                               ; preds = %61
  %97 = call i32 (ptr, ...) @printf(ptr noundef @.str.25)
  store i32 1, ptr %3, align 4
  store i32 1, ptr %24, align 4
  br label %405

98:                                               ; preds = %61
  %99 = load i32, ptr %22, align 4, !tbaa !5
  %100 = load i32, ptr %6, align 4, !tbaa !5
  %101 = mul nsw i32 %99, %100
  %102 = sitofp i32 %101 to double
  %103 = load double, ptr %20, align 8, !tbaa !11
  %104 = fmul double %102, %103
  %105 = call double @llvm.floor.f64(double %104)
  %106 = fptosi double %105 to i32
  %107 = load ptr, ptr %14, align 8, !tbaa !9
  %108 = getelementptr inbounds %struct.ScsCone, ptr %107, i32 0, i32 0
  store i32 %106, ptr %108, align 8, !tbaa !13
  %109 = load i32, ptr %22, align 4, !tbaa !5
  %110 = load i32, ptr %6, align 4, !tbaa !5
  %111 = mul nsw i32 %109, %110
  %112 = sitofp i32 %111 to double
  %113 = load double, ptr %21, align 8, !tbaa !11
  %114 = fmul double %112, %113
  %115 = call double @llvm.floor.f64(double %114)
  %116 = fptosi double %115 to i32
  %117 = load ptr, ptr %14, align 8, !tbaa !9
  %118 = getelementptr inbounds %struct.ScsCone, ptr %117, i32 0, i32 1
  store i32 %116, ptr %118, align 4, !tbaa !15
  %119 = load ptr, ptr %14, align 8, !tbaa !9
  %120 = getelementptr inbounds %struct.ScsCone, ptr %119, i32 0, i32 6
  store i32 0, ptr %120, align 8, !tbaa !16
  %121 = load i32, ptr %22, align 4, !tbaa !5
  %122 = load i32, ptr %6, align 4, !tbaa !5
  %123 = mul nsw i32 %121, %122
  %124 = load ptr, ptr %14, align 8, !tbaa !9
  %125 = getelementptr inbounds %struct.ScsCone, ptr %124, i32 0, i32 0
  %126 = load i32, ptr %125, align 8, !tbaa !13
  %127 = sub nsw i32 %123, %126
  %128 = load ptr, ptr %14, align 8, !tbaa !9
  %129 = getelementptr inbounds %struct.ScsCone, ptr %128, i32 0, i32 1
  %130 = load i32, ptr %129, align 4, !tbaa !15
  %131 = sub nsw i32 %127, %130
  store i32 %131, ptr %12, align 4, !tbaa !5
  %132 = load i32, ptr %12, align 4, !tbaa !5
  %133 = sext i32 %132 to i64
  %134 = mul i64 %133, 4
  %135 = call noalias ptr @malloc(i64 noundef %134) #12
  %136 = load ptr, ptr %14, align 8, !tbaa !9
  %137 = getelementptr inbounds %struct.ScsCone, ptr %136, i32 0, i32 5
  store ptr %135, ptr %137, align 8, !tbaa !17
  br label %138

138:                                              ; preds = %142, %98
  %139 = load i32, ptr %12, align 4, !tbaa !5
  %140 = load i32, ptr %13, align 4, !tbaa !5
  %141 = icmp sgt i32 %139, %140
  br i1 %141, label %142, label %163

142:                                              ; preds = %138
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #9
  %143 = call i32 @rand() #9
  %144 = load i32, ptr %13, align 4, !tbaa !5
  %145 = srem i32 %143, %144
  %146 = add nsw i32 %145, 1
  store i32 %146, ptr %25, align 4, !tbaa !5
  %147 = load i32, ptr %25, align 4, !tbaa !5
  %148 = load ptr, ptr %14, align 8, !tbaa !9
  %149 = getelementptr inbounds %struct.ScsCone, ptr %148, i32 0, i32 5
  %150 = load ptr, ptr %149, align 8, !tbaa !17
  %151 = load ptr, ptr %14, align 8, !tbaa !9
  %152 = getelementptr inbounds %struct.ScsCone, ptr %151, i32 0, i32 6
  %153 = load i32, ptr %152, align 8, !tbaa !16
  %154 = sext i32 %153 to i64
  %155 = getelementptr inbounds i32, ptr %150, i64 %154
  store i32 %147, ptr %155, align 4, !tbaa !5
  %156 = load ptr, ptr %14, align 8, !tbaa !9
  %157 = getelementptr inbounds %struct.ScsCone, ptr %156, i32 0, i32 6
  %158 = load i32, ptr %157, align 8, !tbaa !16
  %159 = add nsw i32 %158, 1
  store i32 %159, ptr %157, align 8, !tbaa !16
  %160 = load i32, ptr %25, align 4, !tbaa !5
  %161 = load i32, ptr %12, align 4, !tbaa !5
  %162 = sub nsw i32 %161, %160
  store i32 %162, ptr %12, align 4, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #9
  br label %138, !llvm.loop !18

163:                                              ; preds = %138
  %164 = load i32, ptr %12, align 4, !tbaa !5
  %165 = icmp sgt i32 %164, 0
  br i1 %165, label %166, label %180

166:                                              ; preds = %163
  %167 = load i32, ptr %12, align 4, !tbaa !5
  %168 = load ptr, ptr %14, align 8, !tbaa !9
  %169 = getelementptr inbounds %struct.ScsCone, ptr %168, i32 0, i32 5
  %170 = load ptr, ptr %169, align 8, !tbaa !17
  %171 = load ptr, ptr %14, align 8, !tbaa !9
  %172 = getelementptr inbounds %struct.ScsCone, ptr %171, i32 0, i32 6
  %173 = load i32, ptr %172, align 8, !tbaa !16
  %174 = sext i32 %173 to i64
  %175 = getelementptr inbounds i32, ptr %170, i64 %174
  store i32 %167, ptr %175, align 4, !tbaa !5
  %176 = load ptr, ptr %14, align 8, !tbaa !9
  %177 = getelementptr inbounds %struct.ScsCone, ptr %176, i32 0, i32 6
  %178 = load i32, ptr %177, align 8, !tbaa !16
  %179 = add nsw i32 %178, 1
  store i32 %179, ptr %177, align 8, !tbaa !16
  br label %180

180:                                              ; preds = %166, %163
  store i32 0, ptr %11, align 4, !tbaa !5
  store i32 0, ptr %10, align 4, !tbaa !5
  br label %181

181:                                              ; preds = %197, %180
  %182 = load i32, ptr %10, align 4, !tbaa !5
  %183 = load ptr, ptr %14, align 8, !tbaa !9
  %184 = getelementptr inbounds %struct.ScsCone, ptr %183, i32 0, i32 6
  %185 = load i32, ptr %184, align 8, !tbaa !16
  %186 = icmp slt i32 %182, %185
  br i1 %186, label %187, label %200

187:                                              ; preds = %181
  %188 = load ptr, ptr %14, align 8, !tbaa !9
  %189 = getelementptr inbounds %struct.ScsCone, ptr %188, i32 0, i32 5
  %190 = load ptr, ptr %189, align 8, !tbaa !17
  %191 = load i32, ptr %10, align 4, !tbaa !5
  %192 = sext i32 %191 to i64
  %193 = getelementptr inbounds i32, ptr %190, i64 %192
  %194 = load i32, ptr %193, align 4, !tbaa !5
  %195 = load i32, ptr %11, align 4, !tbaa !5
  %196 = add nsw i32 %195, %194
  store i32 %196, ptr %11, align 4, !tbaa !5
  br label %197

197:                                              ; preds = %187
  %198 = load i32, ptr %10, align 4, !tbaa !5
  %199 = add nsw i32 %198, 1
  store i32 %199, ptr %10, align 4, !tbaa !5
  br label %181, !llvm.loop !20

200:                                              ; preds = %181
  %201 = load ptr, ptr %14, align 8, !tbaa !9
  %202 = getelementptr inbounds %struct.ScsCone, ptr %201, i32 0, i32 7
  store ptr null, ptr %202, align 8, !tbaa !21
  %203 = load ptr, ptr %14, align 8, !tbaa !9
  %204 = getelementptr inbounds %struct.ScsCone, ptr %203, i32 0, i32 8
  store i32 0, ptr %204, align 8, !tbaa !22
  %205 = load ptr, ptr %14, align 8, !tbaa !9
  %206 = getelementptr inbounds %struct.ScsCone, ptr %205, i32 0, i32 9
  store i32 0, ptr %206, align 4, !tbaa !23
  %207 = load ptr, ptr %14, align 8, !tbaa !9
  %208 = getelementptr inbounds %struct.ScsCone, ptr %207, i32 0, i32 10
  store i32 0, ptr %208, align 8, !tbaa !24
  %209 = load ptr, ptr %14, align 8, !tbaa !9
  %210 = getelementptr inbounds %struct.ScsCone, ptr %209, i32 0, i32 4
  store i32 0, ptr %210, align 8, !tbaa !25
  %211 = load ptr, ptr %14, align 8, !tbaa !9
  %212 = getelementptr inbounds %struct.ScsCone, ptr %211, i32 0, i32 2
  store ptr null, ptr %212, align 8, !tbaa !26
  %213 = load ptr, ptr %14, align 8, !tbaa !9
  %214 = getelementptr inbounds %struct.ScsCone, ptr %213, i32 0, i32 3
  store ptr null, ptr %214, align 8, !tbaa !27
  %215 = load i32, ptr %7, align 4, !tbaa !5
  %216 = sext i32 %215 to i64
  %217 = load i32, ptr %6, align 4, !tbaa !5
  %218 = sext i32 %217 to i64
  %219 = load i32, ptr %8, align 4, !tbaa !5
  %220 = sext i32 %219 to i64
  %221 = call i32 (ptr, ...) @printf(ptr noundef @.str.26, i64 noundef %216, i64 noundef %218, i64 noundef %220)
  %222 = load i32, ptr %9, align 4, !tbaa !5
  %223 = sext i32 %222 to i64
  %224 = load i32, ptr %8, align 4, !tbaa !5
  %225 = sitofp i32 %224 to double
  %226 = fmul double 1.000000e+02, %225
  %227 = load i32, ptr %7, align 4, !tbaa !5
  %228 = sitofp i32 %227 to double
  %229 = fdiv double %226, %228
  %230 = call i32 (ptr, ...) @printf(ptr noundef @.str.27, i64 noundef %223, double noundef %229)
  %231 = load i32, ptr %9, align 4, !tbaa !5
  %232 = sitofp i32 %231 to double
  %233 = fmul double %232, 8.000000e+00
  %234 = call double @pow(double noundef 2.000000e+00, double noundef 3.000000e+01) #9
  %235 = fdiv double %233, %234
  %236 = call i32 (ptr, ...) @printf(ptr noundef @.str.28, double noundef %235)
  %237 = load i32, ptr %9, align 4, !tbaa !5
  %238 = sitofp i32 %237 to double
  %239 = fmul double %238, 4.000000e+00
  %240 = call double @pow(double noundef 2.000000e+00, double noundef 3.000000e+01) #9
  %241 = fdiv double %239, %240
  %242 = call i32 (ptr, ...) @printf(ptr noundef @.str.29, double noundef %241)
  %243 = load i32, ptr %6, align 4, !tbaa !5
  %244 = sitofp i32 %243 to double
  %245 = fmul double %244, 4.000000e+00
  %246 = call double @pow(double noundef 2.000000e+00, double noundef 3.000000e+01) #9
  %247 = fdiv double %245, %246
  %248 = call i32 (ptr, ...) @printf(ptr noundef @.str.30, double noundef %247)
  %249 = call i32 (ptr, ...) @printf(ptr noundef @.str.31)
  %250 = load ptr, ptr %14, align 8, !tbaa !9
  %251 = getelementptr inbounds %struct.ScsCone, ptr %250, i32 0, i32 0
  %252 = load i32, ptr %251, align 8, !tbaa !13
  %253 = sext i32 %252 to i64
  %254 = call i32 (ptr, ...) @printf(ptr noundef @.str.32, i64 noundef %253)
  %255 = load ptr, ptr %14, align 8, !tbaa !9
  %256 = getelementptr inbounds %struct.ScsCone, ptr %255, i32 0, i32 1
  %257 = load i32, ptr %256, align 4, !tbaa !15
  %258 = sext i32 %257 to i64
  %259 = call i32 (ptr, ...) @printf(ptr noundef @.str.33, i64 noundef %258)
  %260 = load ptr, ptr %14, align 8, !tbaa !9
  %261 = getelementptr inbounds %struct.ScsCone, ptr %260, i32 0, i32 6
  %262 = load i32, ptr %261, align 8, !tbaa !16
  %263 = sext i32 %262 to i64
  %264 = load i32, ptr %11, align 4, !tbaa !5
  %265 = sext i32 %264 to i64
  %266 = call i32 (ptr, ...) @printf(ptr noundef @.str.34, i64 noundef %263, i64 noundef %265)
  store i32 0, ptr %10, align 4, !tbaa !5
  br label %267

267:                                              ; preds = %283, %200
  %268 = load i32, ptr %10, align 4, !tbaa !5
  %269 = load ptr, ptr %14, align 8, !tbaa !9
  %270 = getelementptr inbounds %struct.ScsCone, ptr %269, i32 0, i32 6
  %271 = load i32, ptr %270, align 8, !tbaa !16
  %272 = icmp slt i32 %268, %271
  br i1 %272, label %273, label %286

273:                                              ; preds = %267
  %274 = load ptr, ptr %14, align 8, !tbaa !9
  %275 = getelementptr inbounds %struct.ScsCone, ptr %274, i32 0, i32 5
  %276 = load ptr, ptr %275, align 8, !tbaa !17
  %277 = load i32, ptr %10, align 4, !tbaa !5
  %278 = sext i32 %277 to i64
  %279 = getelementptr inbounds i32, ptr %276, i64 %278
  %280 = load i32, ptr %279, align 4, !tbaa !5
  %281 = sext i32 %280 to i64
  %282 = call i32 (ptr, ...) @printf(ptr noundef @.str.35, i64 noundef %281)
  br label %283

283:                                              ; preds = %273
  %284 = load i32, ptr %10, align 4, !tbaa !5
  %285 = add nsw i32 %284, 1
  store i32 %285, ptr %10, align 4, !tbaa !5
  br label %267, !llvm.loop !28

286:                                              ; preds = %267
  %287 = call i32 (ptr, ...) @printf(ptr noundef @.str.36)
  %288 = load i32, ptr %11, align 4, !tbaa !5
  %289 = load ptr, ptr %14, align 8, !tbaa !9
  %290 = getelementptr inbounds %struct.ScsCone, ptr %289, i32 0, i32 0
  %291 = load i32, ptr %290, align 8, !tbaa !13
  %292 = add nsw i32 %288, %291
  %293 = load ptr, ptr %14, align 8, !tbaa !9
  %294 = getelementptr inbounds %struct.ScsCone, ptr %293, i32 0, i32 1
  %295 = load i32, ptr %294, align 4, !tbaa !15
  %296 = add nsw i32 %292, %295
  %297 = sext i32 %296 to i64
  %298 = load i32, ptr %7, align 4, !tbaa !5
  %299 = sext i32 %298 to i64
  %300 = call i32 (ptr, ...) @printf(ptr noundef @.str.37, i64 noundef %297, i64 noundef %299)
  %301 = load i32, ptr %7, align 4, !tbaa !5
  %302 = load ptr, ptr %15, align 8, !tbaa !9
  %303 = getelementptr inbounds %struct.ScsData, ptr %302, i32 0, i32 0
  store i32 %301, ptr %303, align 8, !tbaa !29
  %304 = load i32, ptr %6, align 4, !tbaa !5
  %305 = load ptr, ptr %15, align 8, !tbaa !9
  %306 = getelementptr inbounds %struct.ScsData, ptr %305, i32 0, i32 1
  store i32 %304, ptr %306, align 4, !tbaa !31
  %307 = load i32, ptr %9, align 4, !tbaa !5
  %308 = load i32, ptr %8, align 4, !tbaa !5
  %309 = load ptr, ptr %15, align 8, !tbaa !9
  %310 = load ptr, ptr %14, align 8, !tbaa !9
  %311 = load ptr, ptr %18, align 8, !tbaa !9
  %312 = load i32, ptr %23, align 4, !tbaa !5
  call void @gen_random_prob_data(i32 noundef %307, i32 noundef %308, ptr noundef %309, ptr noundef %310, ptr noundef %311, i32 noundef %312)
  %313 = load ptr, ptr %16, align 8, !tbaa !9
  call void @scs_set_default_settings(ptr noundef %313)
  %314 = load ptr, ptr %15, align 8, !tbaa !9
  %315 = getelementptr inbounds %struct.ScsData, ptr %314, i32 0, i32 5
  %316 = load ptr, ptr %315, align 8, !tbaa !32
  %317 = load ptr, ptr %18, align 8, !tbaa !9
  %318 = getelementptr inbounds %struct.ScsSolution, ptr %317, i32 0, i32 0
  %319 = load ptr, ptr %318, align 8, !tbaa !33
  %320 = load ptr, ptr %15, align 8, !tbaa !9
  %321 = getelementptr inbounds %struct.ScsData, ptr %320, i32 0, i32 1
  %322 = load i32, ptr %321, align 4, !tbaa !31
  %323 = call double @_scs_dot(ptr noundef %316, ptr noundef %319, i32 noundef %322)
  %324 = call i32 (ptr, ...) @printf(ptr noundef @.str.38, double noundef %323)
  %325 = load ptr, ptr %15, align 8, !tbaa !9
  %326 = getelementptr inbounds %struct.ScsData, ptr %325, i32 0, i32 4
  %327 = load ptr, ptr %326, align 8, !tbaa !35
  %328 = load ptr, ptr %18, align 8, !tbaa !9
  %329 = getelementptr inbounds %struct.ScsSolution, ptr %328, i32 0, i32 1
  %330 = load ptr, ptr %329, align 8, !tbaa !36
  %331 = load ptr, ptr %15, align 8, !tbaa !9
  %332 = getelementptr inbounds %struct.ScsData, ptr %331, i32 0, i32 0
  %333 = load i32, ptr %332, align 8, !tbaa !29
  %334 = call double @_scs_dot(ptr noundef %327, ptr noundef %330, i32 noundef %333)
  %335 = fneg double %334
  %336 = call i32 (ptr, ...) @printf(ptr noundef @.str.39, double noundef %335)
  %337 = load ptr, ptr %15, align 8, !tbaa !9
  %338 = load ptr, ptr %14, align 8, !tbaa !9
  %339 = load ptr, ptr %16, align 8, !tbaa !9
  %340 = load ptr, ptr %17, align 8, !tbaa !9
  %341 = call i32 @scs(ptr noundef %337, ptr noundef %338, ptr noundef %339, ptr noundef %340, ptr noundef %19)
  %342 = load ptr, ptr %15, align 8, !tbaa !9
  %343 = getelementptr inbounds %struct.ScsData, ptr %342, i32 0, i32 5
  %344 = load ptr, ptr %343, align 8, !tbaa !32
  %345 = load ptr, ptr %18, align 8, !tbaa !9
  %346 = getelementptr inbounds %struct.ScsSolution, ptr %345, i32 0, i32 0
  %347 = load ptr, ptr %346, align 8, !tbaa !33
  %348 = load ptr, ptr %15, align 8, !tbaa !9
  %349 = getelementptr inbounds %struct.ScsData, ptr %348, i32 0, i32 1
  %350 = load i32, ptr %349, align 4, !tbaa !31
  %351 = call double @_scs_dot(ptr noundef %344, ptr noundef %347, i32 noundef %350)
  %352 = call i32 (ptr, ...) @printf(ptr noundef @.str.38, double noundef %351)
  %353 = load ptr, ptr %15, align 8, !tbaa !9
  %354 = getelementptr inbounds %struct.ScsData, ptr %353, i32 0, i32 4
  %355 = load ptr, ptr %354, align 8, !tbaa !35
  %356 = load ptr, ptr %18, align 8, !tbaa !9
  %357 = getelementptr inbounds %struct.ScsSolution, ptr %356, i32 0, i32 1
  %358 = load ptr, ptr %357, align 8, !tbaa !36
  %359 = load ptr, ptr %15, align 8, !tbaa !9
  %360 = getelementptr inbounds %struct.ScsData, ptr %359, i32 0, i32 0
  %361 = load i32, ptr %360, align 8, !tbaa !29
  %362 = call double @_scs_dot(ptr noundef %355, ptr noundef %358, i32 noundef %361)
  %363 = fneg double %362
  %364 = call i32 (ptr, ...) @printf(ptr noundef @.str.39, double noundef %363)
  %365 = load ptr, ptr %17, align 8, !tbaa !9
  %366 = getelementptr inbounds %struct.ScsSolution, ptr %365, i32 0, i32 0
  %367 = load ptr, ptr %366, align 8, !tbaa !33
  %368 = icmp ne ptr %367, null
  br i1 %368, label %369, label %381

369:                                              ; preds = %286
  %370 = load ptr, ptr %15, align 8, !tbaa !9
  %371 = getelementptr inbounds %struct.ScsData, ptr %370, i32 0, i32 5
  %372 = load ptr, ptr %371, align 8, !tbaa !32
  %373 = load ptr, ptr %17, align 8, !tbaa !9
  %374 = getelementptr inbounds %struct.ScsSolution, ptr %373, i32 0, i32 0
  %375 = load ptr, ptr %374, align 8, !tbaa !33
  %376 = load ptr, ptr %15, align 8, !tbaa !9
  %377 = getelementptr inbounds %struct.ScsData, ptr %376, i32 0, i32 1
  %378 = load i32, ptr %377, align 4, !tbaa !31
  %379 = call double @_scs_dot(ptr noundef %372, ptr noundef %375, i32 noundef %378)
  %380 = call i32 (ptr, ...) @printf(ptr noundef @.str.40, double noundef %379)
  br label %381

381:                                              ; preds = %369, %286
  %382 = load ptr, ptr %17, align 8, !tbaa !9
  %383 = getelementptr inbounds %struct.ScsSolution, ptr %382, i32 0, i32 1
  %384 = load ptr, ptr %383, align 8, !tbaa !36
  %385 = icmp ne ptr %384, null
  br i1 %385, label %386, label %399

386:                                              ; preds = %381
  %387 = load ptr, ptr %15, align 8, !tbaa !9
  %388 = getelementptr inbounds %struct.ScsData, ptr %387, i32 0, i32 4
  %389 = load ptr, ptr %388, align 8, !tbaa !35
  %390 = load ptr, ptr %17, align 8, !tbaa !9
  %391 = getelementptr inbounds %struct.ScsSolution, ptr %390, i32 0, i32 1
  %392 = load ptr, ptr %391, align 8, !tbaa !36
  %393 = load ptr, ptr %15, align 8, !tbaa !9
  %394 = getelementptr inbounds %struct.ScsData, ptr %393, i32 0, i32 0
  %395 = load i32, ptr %394, align 8, !tbaa !29
  %396 = call double @_scs_dot(ptr noundef %389, ptr noundef %392, i32 noundef %395)
  %397 = fneg double %396
  %398 = call i32 (ptr, ...) @printf(ptr noundef @.str.41, double noundef %397)
  br label %399

399:                                              ; preds = %386, %381
  %400 = load ptr, ptr %15, align 8, !tbaa !9
  call void @_scs_free_data(ptr noundef %400)
  %401 = load ptr, ptr %14, align 8, !tbaa !9
  call void @_scs_free_cone(ptr noundef %401)
  %402 = load ptr, ptr %17, align 8, !tbaa !9
  call void @_scs_free_sol(ptr noundef %402)
  %403 = load ptr, ptr %18, align 8, !tbaa !9
  call void @_scs_free_sol(ptr noundef %403)
  %404 = load ptr, ptr %16, align 8, !tbaa !9
  call void @free(ptr noundef %404) #9
  store i32 0, ptr %3, align 4
  store i32 1, ptr %24, align 4
  br label %405

405:                                              ; preds = %399, %96, %48
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #9
  call void @llvm.lifetime.end.p0(i64 400, ptr %19) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #9
  %406 = load i32, ptr %3, align 4
  ret i32 %406
}

; Function Attrs: nounwind
declare i64 @time(ptr noundef) #3

; Function Attrs: inlinehint nounwind willreturn memory(read) uwtable
declare i32 @atoi(ptr noundef nonnull) #6

; Function Attrs: inlinehint nounwind willreturn memory(read) uwtable
declare double @atof(ptr noundef nonnull) #6

; Function Attrs: nounwind
declare double @sqrt(double noundef) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.ceil.f64(double) #7

; Function Attrs: nounwind
declare double @log(double noundef) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.floor.f64(double) #7

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

; Function Attrs: nounwind
declare i32 @rand() #3

; Function Attrs: nounwind
declare double @pow(double noundef, double noundef) #3

declare void @scs_set_default_settings(ptr noundef) #5

declare i32 @scs(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #5

declare void @_scs_free_data(ptr noundef) #5

declare void @_scs_free_cone(ptr noundef) #5

declare void @_scs_free_sol(ptr noundef) #5

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nounwind allocsize(0,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 #3 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #5 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { inlinehint nounwind willreturn memory(read) 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 #7 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #8 = { nounwind allocsize(0) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #9 = { nounwind }
attributes #10 = { nounwind willreturn memory(read) }
attributes #11 = { nounwind allocsize(0,1) }
attributes #12 = { nounwind allocsize(0) }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = !{!14, !6, i64 0}
!14 = !{!"", !6, i64 0, !6, i64 4, !10, i64 8, !10, i64 16, !6, i64 24, !10, i64 32, !6, i64 40, !10, i64 48, !6, i64 56, !6, i64 60, !6, i64 64, !10, i64 72, !6, i64 80}
!15 = !{!14, !6, i64 4}
!16 = !{!14, !6, i64 40}
!17 = !{!14, !10, i64 32}
!18 = distinct !{!18, !19}
!19 = !{!"llvm.loop.mustprogress"}
!20 = distinct !{!20, !19}
!21 = !{!14, !10, i64 48}
!22 = !{!14, !6, i64 56}
!23 = !{!14, !6, i64 60}
!24 = !{!14, !6, i64 64}
!25 = !{!14, !6, i64 24}
!26 = !{!14, !10, i64 8}
!27 = !{!14, !10, i64 16}
!28 = distinct !{!28, !19}
!29 = !{!30, !6, i64 0}
!30 = !{!"", !6, i64 0, !6, i64 4, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32}
!31 = !{!30, !6, i64 4}
!32 = !{!30, !10, i64 32}
!33 = !{!34, !10, i64 0}
!34 = !{!"", !10, i64 0, !10, i64 8, !10, i64 16}
!35 = !{!30, !10, i64 24}
!36 = !{!34, !10, 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.ScsInfo = type { i32, [128 x i8], [128 x i8], i32, i32, double, double, double, double, double, double, double, double, double, double, double, double, i32, i32, double, double, double }

@.str.21 = external hidden unnamed_addr constant [469 x i8], align 1
@.str.22 = external hidden unnamed_addr constant [60 x i8], align 1
@.str.23 = external hidden unnamed_addr constant [57 x i8], align 1
@.str.24 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.25 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.26 = external hidden unnamed_addr constant [49 x i8], align 1
@.str.27 = external hidden unnamed_addr constant [34 x i8], align 1
@.str.28 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.29 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.30 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.31 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.32 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.33 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.34 = external hidden unnamed_addr constant [67 x i8], align 1
@.str.35 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.36 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.37 = external hidden unnamed_addr constant [44 x i8], align 1
@.str.38 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.39 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.40 = external hidden unnamed_addr constant [18 x i8], align 1
@.str.41 = external hidden unnamed_addr constant [19 x i8], align 1

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

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

; Function Attrs: nounwind uwtable
declare dso_local void @gen_random_prob_data(i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nofree nounwind willreturn allockind("alloc,zeroed") allocsize(0,1) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @calloc(i64 noundef, i64 noundef) local_unnamed_addr #2

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

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

declare double @_scs_dot(ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #5

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

; Function Attrs: nounwind uwtable
define dso_local range(i32 0, 2) i32 @main(i32 noundef %0, ptr nocapture noundef readonly %1) local_unnamed_addr #1 {
  %3 = alloca %struct.ScsInfo, align 8
  call void @llvm.lifetime.start.p0(i64 400, ptr nonnull %3) #13
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(400) %3, i8 0, i64 400, i1 false)
  %4 = tail call i64 @time(ptr noundef null) #13
  %5 = trunc i64 %4 to i32
  switch i32 %0, label %40 [
    i32 5, label %6
    i32 4, label %10
    i32 2, label %17
  ]

6:                                                ; preds = %2
  %7 = getelementptr inbounds i8, ptr %1, i64 32
  %8 = load ptr, ptr %7, align 8, !tbaa !5
  %9 = tail call i32 @atoi(ptr nocapture noundef %8) #14
  br label %10

10:                                               ; preds = %6, %2
  %.0124 = phi i32 [ %5, %2 ], [ %9, %6 ]
  %11 = getelementptr inbounds i8, ptr %1, i64 16
  %12 = load ptr, ptr %11, align 8, !tbaa !5
  %13 = tail call double @atof(ptr noundef %12) #14
  %14 = getelementptr inbounds i8, ptr %1, i64 24
  %15 = load ptr, ptr %14, align 8, !tbaa !5
  %16 = tail call double @atof(ptr noundef %15) #14
  br label %17

17:                                               ; preds = %10, %2
  %.0128 = phi double [ 1.000000e-01, %2 ], [ %13, %10 ]
  %.0127 = phi double [ 3.000000e-01, %2 ], [ %16, %10 ]
  %.1 = phi i32 [ %5, %2 ], [ %.0124, %10 ]
  %18 = getelementptr inbounds i8, ptr %1, i64 8
  %19 = load ptr, ptr %18, align 8, !tbaa !5
  %20 = tail call i32 @atoi(ptr nocapture noundef %19) #14
  %21 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.24, i32 noundef %.1)
  %22 = tail call noalias dereferenceable_or_null(88) ptr @calloc(i64 noundef 1, i64 noundef 88) #15
  %23 = tail call noalias dereferenceable_or_null(40) ptr @calloc(i64 noundef 1, i64 noundef 40) #15
  %24 = tail call noalias dereferenceable_or_null(112) ptr @calloc(i64 noundef 1, i64 noundef 112) #15
  %25 = tail call noalias dereferenceable_or_null(24) ptr @calloc(i64 noundef 1, i64 noundef 24) #15
  %26 = tail call noalias dereferenceable_or_null(24) ptr @calloc(i64 noundef 1, i64 noundef 24) #15
  %27 = shl nsw i32 %20, 2
  %28 = sitofp i32 %20 to double
  %29 = tail call double @sqrt(double noundef %28) #13
  %30 = tail call double @llvm.ceil.f64(double %29)
  %31 = fptosi double %30 to i32
  %32 = mul nsw i32 %20, %31
  %33 = sitofp i32 %27 to double
  %34 = tail call double @log(double noundef %33) #13
  %35 = fdiv double %33, %34
  %36 = tail call double @llvm.ceil.f64(double %35)
  %37 = fptosi double %36 to i32
  %38 = fadd double %.0128, %.0127
  %39 = fcmp ogt double %38, 1.000000e+00
  br i1 %39, label %47, label %49

40:                                               ; preds = %2
  %41 = load ptr, ptr %1, align 8, !tbaa !5
  %42 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.21, ptr noundef %41)
  %43 = load ptr, ptr %1, align 8, !tbaa !5
  %44 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.22, ptr noundef %43)
  %45 = load ptr, ptr %1, align 8, !tbaa !5
  %46 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.23, ptr noundef %45)
  br label %172

47:                                               ; preds = %17
  %48 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.25)
  br label %172

49:                                               ; preds = %17
  %50 = fmul double %.0128, %33
  %51 = tail call double @llvm.floor.f64(double %50)
  %52 = fptosi double %51 to i32
  store i32 %52, ptr %22, align 8, !tbaa !9
  %53 = fmul double %.0127, %33
  %54 = tail call double @llvm.floor.f64(double %53)
  %55 = fptosi double %54 to i32
  %56 = getelementptr inbounds i8, ptr %22, i64 4
  store i32 %55, ptr %56, align 4, !tbaa !12
  %57 = getelementptr inbounds i8, ptr %22, i64 40
  %58 = add i32 %55, %52
  %59 = sub i32 %27, %58
  %60 = sext i32 %59 to i64
  %61 = shl nsw i64 %60, 2
  %62 = tail call noalias ptr @malloc(i64 noundef %61) #16
  %63 = getelementptr inbounds i8, ptr %22, i64 32
  store ptr %62, ptr %63, align 8, !tbaa !13
  %64 = icmp sgt i32 %59, %37
  br i1 %64, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %49, %.lr.ph
  %65 = phi i32 [ %71, %.lr.ph ], [ 0, %49 ]
  %.0130137 = phi i32 [ %72, %.lr.ph ], [ %59, %49 ]
  %66 = tail call i32 @rand() #13
  %67 = srem i32 %66, %37
  %68 = add nsw i32 %67, 1
  %69 = zext nneg i32 %65 to i64
  %70 = getelementptr inbounds i32, ptr %62, i64 %69
  store i32 %68, ptr %70, align 4, !tbaa !14
  %71 = add nuw nsw i32 %65, 1
  store i32 %71, ptr %57, align 8, !tbaa !15
  %72 = sub nsw i32 %.0130137, %68
  %73 = icmp sgt i32 %72, %37
  br i1 %73, label %.lr.ph, label %._crit_edge, !llvm.loop !16

._crit_edge:                                      ; preds = %.lr.ph, %49
  %74 = phi i32 [ 0, %49 ], [ %71, %.lr.ph ]
  %.0130.lcssa = phi i32 [ %59, %49 ], [ %72, %.lr.ph ]
  %75 = icmp sgt i32 %.0130.lcssa, 0
  br i1 %75, label %76, label %80

76:                                               ; preds = %._crit_edge
  %77 = sext i32 %74 to i64
  %78 = getelementptr inbounds i32, ptr %62, i64 %77
  store i32 %.0130.lcssa, ptr %78, align 4, !tbaa !14
  %79 = add nsw i32 %74, 1
  store i32 %79, ptr %57, align 8, !tbaa !15
  br label %80

80:                                               ; preds = %76, %._crit_edge
  %81 = phi i32 [ %79, %76 ], [ %74, %._crit_edge ]
  %82 = icmp sgt i32 %81, 0
  br i1 %82, label %.lr.ph141, label %._crit_edge142

.lr.ph141:                                        ; preds = %80
  %wide.trip.count = zext nneg i32 %81 to i64
  %min.iters.check = icmp ult i32 %81, 8
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.ph

vector.ph:                                        ; preds = %.lr.ph141
  %n.vec = and i64 %wide.trip.count, 2147483640
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %vec.phi = phi <4 x i32> [ zeroinitializer, %vector.ph ], [ %85, %vector.body ]
  %vec.phi157 = phi <4 x i32> [ zeroinitializer, %vector.ph ], [ %86, %vector.body ]
  %83 = getelementptr inbounds i32, ptr %62, i64 %index
  %84 = getelementptr inbounds i8, ptr %83, i64 16
  %wide.load = load <4 x i32>, ptr %83, align 4, !tbaa !14
  %wide.load158 = load <4 x i32>, ptr %84, align 4, !tbaa !14
  %85 = add <4 x i32> %wide.load, %vec.phi
  %86 = add <4 x i32> %wide.load158, %vec.phi157
  %index.next = add nuw i64 %index, 8
  %87 = icmp eq i64 %index.next, %n.vec
  br i1 %87, label %middle.block, label %vector.body, !llvm.loop !18

middle.block:                                     ; preds = %vector.body
  %bin.rdx = add <4 x i32> %86, %85
  %88 = tail call i32 @llvm.vector.reduce.add.v4i32(<4 x i32> %bin.rdx)
  %cmp.n = icmp eq i64 %n.vec, %wide.trip.count
  br i1 %cmp.n, label %._crit_edge142, label %scalar.ph.preheader

scalar.ph.preheader:                              ; preds = %middle.block, %.lr.ph141
  %indvars.iv.ph = phi i64 [ 0, %.lr.ph141 ], [ %n.vec, %middle.block ]
  %.0129138.ph = phi i32 [ 0, %.lr.ph141 ], [ %88, %middle.block ]
  br label %scalar.ph

scalar.ph:                                        ; preds = %scalar.ph.preheader, %scalar.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %scalar.ph ], [ %indvars.iv.ph, %scalar.ph.preheader ]
  %.0129138 = phi i32 [ %91, %scalar.ph ], [ %.0129138.ph, %scalar.ph.preheader ]
  %89 = getelementptr inbounds i32, ptr %62, i64 %indvars.iv
  %90 = load i32, ptr %89, align 4, !tbaa !14
  %91 = add nsw i32 %90, %.0129138
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge142, label %scalar.ph, !llvm.loop !21

._crit_edge142:                                   ; preds = %scalar.ph, %middle.block, %80
  %.0129.lcssa = phi i32 [ 0, %80 ], [ %88, %middle.block ], [ %91, %scalar.ph ]
  %92 = sext i32 %27 to i64
  %93 = sext i32 %20 to i64
  %94 = sext i32 %31 to i64
  %95 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.26, i64 noundef %92, i64 noundef %93, i64 noundef %94)
  %96 = sext i32 %32 to i64
  %97 = sitofp i32 %31 to double
  %98 = fmul double %97, 1.000000e+02
  %99 = fdiv double %98, %33
  %100 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.27, i64 noundef %96, double noundef %99)
  %101 = sitofp i32 %32 to double
  %102 = fmul double %101, 8.000000e+00
  %103 = fmul double %102, 0x3E10000000000000
  %104 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.28, double noundef %103)
  %105 = fmul double %101, 4.000000e+00
  %106 = fmul double %105, 0x3E10000000000000
  %107 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.29, double noundef %106)
  %108 = fmul double %28, 4.000000e+00
  %109 = fmul double %108, 0x3E10000000000000
  %110 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.30, double noundef %109)
  %111 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.31)
  %112 = sext i32 %52 to i64
  %113 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.32, i64 noundef %112)
  %114 = sext i32 %55 to i64
  %115 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.33, i64 noundef %114)
  %116 = sext i32 %81 to i64
  %117 = sext i32 %.0129.lcssa to i64
  %118 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.34, i64 noundef %116, i64 noundef %117)
  br i1 %82, label %.lr.ph146, label %._crit_edge147

.lr.ph146:                                        ; preds = %._crit_edge142, %.lr.ph146
  %indvars.iv150 = phi i64 [ %indvars.iv.next151, %.lr.ph146 ], [ 0, %._crit_edge142 ]
  %119 = getelementptr inbounds i32, ptr %62, i64 %indvars.iv150
  %120 = load i32, ptr %119, align 4, !tbaa !14
  %121 = sext i32 %120 to i64
  %122 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.35, i64 noundef %121)
  %indvars.iv.next151 = add nuw nsw i64 %indvars.iv150, 1
  %123 = icmp slt i64 %indvars.iv.next151, %116
  br i1 %123, label %.lr.ph146, label %._crit_edge147, !llvm.loop !22

._crit_edge147:                                   ; preds = %.lr.ph146, %._crit_edge142
  %124 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.36)
  %125 = add nsw i32 %.0129.lcssa, %52
  %126 = add nsw i32 %125, %55
  %127 = sext i32 %126 to i64
  %128 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.37, i64 noundef %127, i64 noundef %92)
  store i32 %27, ptr %23, align 8, !tbaa !23
  %129 = getelementptr inbounds i8, ptr %23, i64 4
  store i32 %20, ptr %129, align 4, !tbaa !25
  tail call void @gen_random_prob_data(i32 noundef %32, i32 noundef %31, ptr noundef nonnull %23, ptr noundef nonnull %22, ptr noundef %26, i32 noundef %.1)
  tail call void @scs_set_default_settings(ptr noundef %24) #13
  %130 = getelementptr inbounds i8, ptr %23, i64 32
  %131 = load ptr, ptr %130, align 8, !tbaa !26
  %132 = load ptr, ptr %26, align 8, !tbaa !27
  %133 = load i32, ptr %129, align 4, !tbaa !25
  %134 = tail call double @_scs_dot(ptr noundef %131, ptr noundef %132, i32 noundef %133) #13
  %135 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.38, double noundef %134)
  %136 = getelementptr inbounds i8, ptr %23, i64 24
  %137 = load ptr, ptr %136, align 8, !tbaa !29
  %138 = getelementptr inbounds i8, ptr %26, i64 8
  %139 = load ptr, ptr %138, align 8, !tbaa !30
  %140 = load i32, ptr %23, align 8, !tbaa !23
  %141 = tail call double @_scs_dot(ptr noundef %137, ptr noundef %139, i32 noundef %140) #13
  %142 = fneg double %141
  %143 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.39, double noundef %142)
  %144 = call i32 @scs(ptr noundef nonnull %23, ptr noundef nonnull %22, ptr noundef %24, ptr noundef %25, ptr noundef nonnull %3) #13
  %145 = load ptr, ptr %130, align 8, !tbaa !26
  %146 = load ptr, ptr %26, align 8, !tbaa !27
  %147 = load i32, ptr %129, align 4, !tbaa !25
  %148 = call double @_scs_dot(ptr noundef %145, ptr noundef %146, i32 noundef %147) #13
  %149 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.38, double noundef %148)
  %150 = load ptr, ptr %136, align 8, !tbaa !29
  %151 = load ptr, ptr %138, align 8, !tbaa !30
  %152 = load i32, ptr %23, align 8, !tbaa !23
  %153 = call double @_scs_dot(ptr noundef %150, ptr noundef %151, i32 noundef %152) #13
  %154 = fneg double %153
  %155 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.39, double noundef %154)
  %156 = load ptr, ptr %25, align 8, !tbaa !27
  %.not = icmp eq ptr %156, null
  br i1 %.not, label %162, label %157

157:                                              ; preds = %._crit_edge147
  %158 = load ptr, ptr %130, align 8, !tbaa !26
  %159 = load i32, ptr %129, align 4, !tbaa !25
  %160 = call double @_scs_dot(ptr noundef %158, ptr noundef nonnull %156, i32 noundef %159) #13
  %161 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.40, double noundef %160)
  br label %162

162:                                              ; preds = %157, %._crit_edge147
  %163 = getelementptr inbounds i8, ptr %25, i64 8
  %164 = load ptr, ptr %163, align 8, !tbaa !30
  %.not134 = icmp eq ptr %164, null
  br i1 %.not134, label %171, label %165

165:                                              ; preds = %162
  %166 = load ptr, ptr %136, align 8, !tbaa !29
  %167 = load i32, ptr %23, align 8, !tbaa !23
  %168 = call double @_scs_dot(ptr noundef %166, ptr noundef nonnull %164, i32 noundef %167) #13
  %169 = fneg double %168
  %170 = call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.41, double noundef %169)
  br label %171

171:                                              ; preds = %165, %162
  call void @_scs_free_data(ptr noundef nonnull %23) #13
  call void @_scs_free_cone(ptr noundef nonnull %22) #13
  call void @_scs_free_sol(ptr noundef nonnull %25) #13
  call void @_scs_free_sol(ptr noundef nonnull %26) #13
  call void @free(ptr noundef %24) #13
  br label %172

172:                                              ; preds = %171, %47, %40
  %.0 = phi i32 [ 0, %40 ], [ 1, %47 ], [ 0, %171 ]
  call void @llvm.lifetime.end.p0(i64 400, ptr nonnull %3) #13
  ret i32 %.0
}

; Function Attrs: nounwind
declare i64 @time(ptr noundef) local_unnamed_addr #7

; Function Attrs: inlinehint mustprogress nofree nounwind willreturn memory(read) uwtable
declare i32 @atoi(ptr nocapture noundef nonnull) local_unnamed_addr #8

; Function Attrs: inlinehint mustprogress nofree nounwind willreturn memory(read) uwtable
declare double @atof(ptr nocapture noundef nonnull) local_unnamed_addr #8

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @sqrt(double noundef) local_unnamed_addr #9

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.ceil.f64(double) #10

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @log(double noundef) local_unnamed_addr #9

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.floor.f64(double) #10

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

; Function Attrs: nounwind
declare i32 @rand() local_unnamed_addr #7

declare void @scs_set_default_settings(ptr noundef) local_unnamed_addr #5

declare i32 @scs(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #5

declare void @_scs_free_data(ptr noundef) local_unnamed_addr #5

declare void @_scs_free_cone(ptr noundef) local_unnamed_addr #5

declare void @_scs_free_sol(ptr noundef) local_unnamed_addr #5

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.vector.reduce.add.v4i32(<4 x i32>) #12

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress nofree nounwind willreturn allockind("alloc,zeroed") allocsize(0,1) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite) "alloc-family"="malloc" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #5 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nofree nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #8 = { inlinehint mustprogress nofree nounwind willreturn memory(read) 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 #9 = { mustprogress nofree nounwind willreturn memory(write) "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 #10 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #11 = { mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #12 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #13 = { nounwind }
attributes #14 = { nounwind willreturn memory(read) }
attributes #15 = { nounwind allocsize(0,1) }
attributes #16 = { nounwind allocsize(0) }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !11, i64 0}
!10 = !{!"", !11, i64 0, !11, i64 4, !6, i64 8, !6, i64 16, !11, i64 24, !6, i64 32, !11, i64 40, !6, i64 48, !11, i64 56, !11, i64 60, !11, i64 64, !6, i64 72, !11, i64 80}
!11 = !{!"int", !7, i64 0}
!12 = !{!10, !11, i64 4}
!13 = !{!10, !6, i64 32}
!14 = !{!11, !11, i64 0}
!15 = !{!10, !11, i64 40}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}
!18 = distinct !{!18, !17, !19, !20}
!19 = !{!"llvm.loop.isvectorized", i32 1}
!20 = !{!"llvm.loop.unroll.runtime.disable"}
!21 = distinct !{!21, !17, !20, !19}
!22 = distinct !{!22, !17}
!23 = !{!24, !11, i64 0}
!24 = !{!"", !11, i64 0, !11, i64 4, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32}
!25 = !{!24, !11, i64 4}
!26 = !{!24, !6, i64 32}
!27 = !{!28, !6, i64 0}
!28 = !{!"", !6, i64 0, !6, i64 8, !6, i64 16}
!29 = !{!24, !6, i64 24}
!30 = !{!28, !6, i64 8}


; Effective O3 passes: DSEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,MemCpyOptPass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass