; LLVM IR from ekoontz/graphlab :: src/graphlab/extern/metis/libmetis/compress.ll_libmetis (PruneGraph)

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

@.str.7 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.16 = 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

declare void @libmetis__InitGraph(ptr noundef) #1

declare ptr @libmetis__idxmalloc(i64 noundef, ptr noundef) #1

declare ptr @libmetis__idxset(i64 noundef, i64 noundef, ptr noundef) #1

declare void @gk_free(ptr noundef, ...) #1

; 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
define dso_local void @libmetis__PruneGraph(ptr noundef %0, ptr noundef %1, i64 noundef %2, ptr noundef %3, ptr noundef %4, ptr noundef %5, float noundef %6) #2 {
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i64, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca float, align 4
  %15 = alloca i64, align 8
  %16 = alloca i64, align 8
  %17 = alloca i64, align 8
  %18 = alloca i64, align 8
  %19 = alloca i64, align 8
  %20 = alloca i64, align 8
  %21 = alloca i64, align 8
  %22 = alloca ptr, align 8
  %23 = alloca ptr, align 8
  %24 = alloca ptr, align 8
  %25 = alloca ptr, align 8
  store ptr %0, ptr %8, align 8, !tbaa !5
  store ptr %1, ptr %9, align 8, !tbaa !5
  store i64 %2, ptr %10, align 8, !tbaa !9
  store ptr %3, ptr %11, align 8, !tbaa !5
  store ptr %4, ptr %12, align 8, !tbaa !5
  store ptr %5, ptr %13, align 8, !tbaa !5
  store float %6, ptr %14, align 4, !tbaa !11
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #3
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #3
  %26 = load i64, ptr %10, align 8, !tbaa !9
  %27 = call ptr @libmetis__idxmalloc(i64 noundef %26, ptr noundef @.str.10)
  store ptr %27, ptr %25, align 8, !tbaa !5
  %28 = load float, ptr %14, align 4, !tbaa !11
  %29 = load ptr, ptr %11, align 8, !tbaa !5
  %30 = load i64, ptr %10, align 8, !tbaa !9
  %31 = getelementptr inbounds i64, ptr %29, i64 %30
  %32 = load i64, ptr %31, align 8, !tbaa !9
  %33 = sitofp i64 %32 to float
  %34 = fmul float %28, %33
  %35 = load i64, ptr %10, align 8, !tbaa !9
  %36 = sitofp i64 %35 to float
  %37 = fdiv float %34, %36
  store float %37, ptr %14, align 4, !tbaa !11
  store i64 0, ptr %19, align 8, !tbaa !9
  store i64 0, ptr %21, align 8, !tbaa !9
  store i64 0, ptr %20, align 8, !tbaa !9
  store i64 0, ptr %15, align 8, !tbaa !9
  br label %38

38:                                               ; preds = %93, %7
  %39 = load i64, ptr %15, align 8, !tbaa !9
  %40 = load i64, ptr %10, align 8, !tbaa !9
  %41 = icmp slt i64 %39, %40
  br i1 %41, label %42, label %96

42:                                               ; preds = %38
  %43 = load ptr, ptr %11, align 8, !tbaa !5
  %44 = load i64, ptr %15, align 8, !tbaa !9
  %45 = add nsw i64 %44, 1
  %46 = getelementptr inbounds i64, ptr %43, i64 %45
  %47 = load i64, ptr %46, align 8, !tbaa !9
  %48 = load ptr, ptr %11, align 8, !tbaa !5
  %49 = load i64, ptr %15, align 8, !tbaa !9
  %50 = getelementptr inbounds i64, ptr %48, i64 %49
  %51 = load i64, ptr %50, align 8, !tbaa !9
  %52 = sub nsw i64 %47, %51
  %53 = sitofp i64 %52 to float
  %54 = load float, ptr %14, align 4, !tbaa !11
  %55 = fcmp olt float %53, %54
  br i1 %55, label %56, label %78

56:                                               ; preds = %42
  %57 = load i64, ptr %20, align 8, !tbaa !9
  %58 = load ptr, ptr %25, align 8, !tbaa !5
  %59 = load i64, ptr %15, align 8, !tbaa !9
  %60 = getelementptr inbounds i64, ptr %58, i64 %59
  store i64 %57, ptr %60, align 8, !tbaa !9
  %61 = load i64, ptr %15, align 8, !tbaa !9
  %62 = load ptr, ptr %13, align 8, !tbaa !5
  %63 = load i64, ptr %20, align 8, !tbaa !9
  %64 = add nsw i64 %63, 1
  store i64 %64, ptr %20, align 8, !tbaa !9
  %65 = getelementptr inbounds i64, ptr %62, i64 %63
  store i64 %61, ptr %65, align 8, !tbaa !9
  %66 = load ptr, ptr %11, align 8, !tbaa !5
  %67 = load i64, ptr %15, align 8, !tbaa !9
  %68 = add nsw i64 %67, 1
  %69 = getelementptr inbounds i64, ptr %66, i64 %68
  %70 = load i64, ptr %69, align 8, !tbaa !9
  %71 = load ptr, ptr %11, align 8, !tbaa !5
  %72 = load i64, ptr %15, align 8, !tbaa !9
  %73 = getelementptr inbounds i64, ptr %71, i64 %72
  %74 = load i64, ptr %73, align 8, !tbaa !9
  %75 = sub nsw i64 %70, %74
  %76 = load i64, ptr %21, align 8, !tbaa !9
  %77 = add nsw i64 %76, %75
  store i64 %77, ptr %21, align 8, !tbaa !9
  br label %92

78:                                               ; preds = %42
  %79 = load i64, ptr %10, align 8, !tbaa !9
  %80 = load i64, ptr %19, align 8, !tbaa !9
  %81 = add nsw i64 %80, 1
  store i64 %81, ptr %19, align 8, !tbaa !9
  %82 = sub nsw i64 %79, %81
  %83 = load ptr, ptr %25, align 8, !tbaa !5
  %84 = load i64, ptr %15, align 8, !tbaa !9
  %85 = getelementptr inbounds i64, ptr %83, i64 %84
  store i64 %82, ptr %85, align 8, !tbaa !9
  %86 = load i64, ptr %15, align 8, !tbaa !9
  %87 = load ptr, ptr %13, align 8, !tbaa !5
  %88 = load i64, ptr %10, align 8, !tbaa !9
  %89 = load i64, ptr %19, align 8, !tbaa !9
  %90 = sub nsw i64 %88, %89
  %91 = getelementptr inbounds i64, ptr %87, i64 %90
  store i64 %86, ptr %91, align 8, !tbaa !9
  br label %92

92:                                               ; preds = %78, %56
  br label %93

93:                                               ; preds = %92
  %94 = load i64, ptr %15, align 8, !tbaa !9
  %95 = add nsw i64 %94, 1
  store i64 %95, ptr %15, align 8, !tbaa !9
  br label %38, !llvm.loop !13

96:                                               ; preds = %38
  %97 = load ptr, ptr %9, align 8, !tbaa !5
  call void @libmetis__InitGraph(ptr noundef %97)
  %98 = load i64, ptr %19, align 8, !tbaa !9
  %99 = icmp eq i64 %98, 0
  br i1 %99, label %100, label %195

100:                                              ; preds = %96
  %101 = load i64, ptr %10, align 8, !tbaa !9
  %102 = load ptr, ptr %9, align 8, !tbaa !5
  %103 = getelementptr inbounds %struct.graphdef, ptr %102, i32 0, i32 0
  store i64 %101, ptr %103, align 8, !tbaa !15
  %104 = load ptr, ptr %11, align 8, !tbaa !5
  %105 = load i64, ptr %10, align 8, !tbaa !9
  %106 = getelementptr inbounds i64, ptr %104, i64 %105
  %107 = load i64, ptr %106, align 8, !tbaa !9
  %108 = load ptr, ptr %9, align 8, !tbaa !5
  %109 = getelementptr inbounds %struct.graphdef, ptr %108, i32 0, i32 1
  store i64 %107, ptr %109, align 8, !tbaa !18
  %110 = load ptr, ptr %9, align 8, !tbaa !5
  %111 = getelementptr inbounds %struct.graphdef, ptr %110, i32 0, i32 28
  store i64 1, ptr %111, align 8, !tbaa !19
  %112 = load ptr, ptr %11, align 8, !tbaa !5
  %113 = load ptr, ptr %9, align 8, !tbaa !5
  %114 = getelementptr inbounds %struct.graphdef, ptr %113, i32 0, i32 2
  store ptr %112, ptr %114, align 8, !tbaa !20
  %115 = load ptr, ptr %9, align 8, !tbaa !5
  %116 = getelementptr inbounds %struct.graphdef, ptr %115, i32 0, i32 7
  store i32 0, ptr %116, align 8, !tbaa !21
  %117 = load ptr, ptr %12, align 8, !tbaa !5
  %118 = load ptr, ptr %9, align 8, !tbaa !5
  %119 = getelementptr inbounds %struct.graphdef, ptr %118, i32 0, i32 5
  store ptr %117, ptr %119, align 8, !tbaa !22
  %120 = load ptr, ptr %9, align 8, !tbaa !5
  %121 = getelementptr inbounds %struct.graphdef, ptr %120, i32 0, i32 10
  store i32 0, ptr %121, align 4, !tbaa !23
  %122 = load i64, ptr %10, align 8, !tbaa !9
  %123 = call ptr @libmetis__idxmalloc(i64 noundef %122, ptr noundef @.str.11)
  %124 = load ptr, ptr %9, align 8, !tbaa !5
  %125 = getelementptr inbounds %struct.graphdef, ptr %124, i32 0, i32 3
  store ptr %123, ptr %125, align 8, !tbaa !24
  %126 = load i64, ptr %10, align 8, !tbaa !9
  %127 = call ptr @libmetis__idxmalloc(i64 noundef %126, ptr noundef @.str.12)
  %128 = load ptr, ptr %9, align 8, !tbaa !5
  %129 = getelementptr inbounds %struct.graphdef, ptr %128, i32 0, i32 13
  store ptr %127, ptr %129, align 8, !tbaa !25
  %130 = load i64, ptr %10, align 8, !tbaa !9
  %131 = call ptr @libmetis__idxmalloc(i64 noundef %130, ptr noundef @.str.13)
  %132 = load ptr, ptr %9, align 8, !tbaa !5
  %133 = getelementptr inbounds %struct.graphdef, ptr %132, i32 0, i32 15
  store ptr %131, ptr %133, align 8, !tbaa !26
  %134 = load ptr, ptr %9, align 8, !tbaa !5
  %135 = getelementptr inbounds %struct.graphdef, ptr %134, i32 0, i32 1
  %136 = load i64, ptr %135, align 8, !tbaa !18
  %137 = call ptr @libmetis__idxmalloc(i64 noundef %136, ptr noundef @.str.14)
  %138 = load ptr, ptr %9, align 8, !tbaa !5
  %139 = getelementptr inbounds %struct.graphdef, ptr %138, i32 0, i32 6
  store ptr %137, ptr %139, align 8, !tbaa !27
  %140 = load i64, ptr %10, align 8, !tbaa !9
  %141 = load ptr, ptr %9, align 8, !tbaa !5
  %142 = getelementptr inbounds %struct.graphdef, ptr %141, i32 0, i32 3
  %143 = load ptr, ptr %142, align 8, !tbaa !24
  %144 = call ptr @libmetis__idxset(i64 noundef %140, i64 noundef 1, ptr noundef %143)
  %145 = load ptr, ptr %9, align 8, !tbaa !5
  %146 = getelementptr inbounds %struct.graphdef, ptr %145, i32 0, i32 1
  %147 = load i64, ptr %146, align 8, !tbaa !18
  %148 = load ptr, ptr %9, align 8, !tbaa !5
  %149 = getelementptr inbounds %struct.graphdef, ptr %148, i32 0, i32 6
  %150 = load ptr, ptr %149, align 8, !tbaa !27
  %151 = call ptr @libmetis__idxset(i64 noundef %147, i64 noundef 1, ptr noundef %150)
  store i64 0, ptr %15, align 8, !tbaa !9
  br label %152

152:                                              ; preds = %172, %100
  %153 = load i64, ptr %15, align 8, !tbaa !9
  %154 = load i64, ptr %10, align 8, !tbaa !9
  %155 = icmp slt i64 %153, %154
  br i1 %155, label %156, label %175

156:                                              ; preds = %152
  %157 = load ptr, ptr %11, align 8, !tbaa !5
  %158 = load i64, ptr %15, align 8, !tbaa !9
  %159 = add nsw i64 %158, 1
  %160 = getelementptr inbounds i64, ptr %157, i64 %159
  %161 = load i64, ptr %160, align 8, !tbaa !9
  %162 = load ptr, ptr %11, align 8, !tbaa !5
  %163 = load i64, ptr %15, align 8, !tbaa !9
  %164 = getelementptr inbounds i64, ptr %162, i64 %163
  %165 = load i64, ptr %164, align 8, !tbaa !9
  %166 = sub nsw i64 %161, %165
  %167 = load ptr, ptr %9, align 8, !tbaa !5
  %168 = getelementptr inbounds %struct.graphdef, ptr %167, i32 0, i32 13
  %169 = load ptr, ptr %168, align 8, !tbaa !25
  %170 = load i64, ptr %15, align 8, !tbaa !9
  %171 = getelementptr inbounds i64, ptr %169, i64 %170
  store i64 %166, ptr %171, align 8, !tbaa !9
  br label %172

172:                                              ; preds = %156
  %173 = load i64, ptr %15, align 8, !tbaa !9
  %174 = add nsw i64 %173, 1
  store i64 %174, ptr %15, align 8, !tbaa !9
  br label %152, !llvm.loop !28

175:                                              ; preds = %152
  %176 = load i64, ptr %10, align 8, !tbaa !9
  %177 = call ptr @libmetis__idxmalloc(i64 noundef %176, ptr noundef @.str.7)
  %178 = load ptr, ptr %9, align 8, !tbaa !5
  %179 = getelementptr inbounds %struct.graphdef, ptr %178, i32 0, i32 14
  store ptr %177, ptr %179, align 8, !tbaa !29
  store i64 0, ptr %15, align 8, !tbaa !9
  br label %180

180:                                              ; preds = %191, %175
  %181 = load i64, ptr %15, align 8, !tbaa !9
  %182 = load i64, ptr %10, align 8, !tbaa !9
  %183 = icmp slt i64 %181, %182
  br i1 %183, label %184, label %194

184:                                              ; preds = %180
  %185 = load i64, ptr %15, align 8, !tbaa !9
  %186 = load ptr, ptr %9, align 8, !tbaa !5
  %187 = getelementptr inbounds %struct.graphdef, ptr %186, i32 0, i32 14
  %188 = load ptr, ptr %187, align 8, !tbaa !29
  %189 = load i64, ptr %15, align 8, !tbaa !9
  %190 = getelementptr inbounds i64, ptr %188, i64 %189
  store i64 %185, ptr %190, align 8, !tbaa !9
  br label %191

191:                                              ; preds = %184
  %192 = load i64, ptr %15, align 8, !tbaa !9
  %193 = add nsw i64 %192, 1
  store i64 %193, ptr %15, align 8, !tbaa !9
  br label %180, !llvm.loop !30

194:                                              ; preds = %180
  br label %347

195:                                              ; preds = %96
  %196 = load i64, ptr %20, align 8, !tbaa !9
  %197 = add nsw i64 %196, 1
  %198 = call ptr @libmetis__idxmalloc(i64 noundef %197, ptr noundef @.str.15)
  %199 = load ptr, ptr %9, align 8, !tbaa !5
  %200 = getelementptr inbounds %struct.graphdef, ptr %199, i32 0, i32 2
  store ptr %198, ptr %200, align 8, !tbaa !20
  store ptr %198, ptr %22, align 8, !tbaa !5
  %201 = load i64, ptr %20, align 8, !tbaa !9
  %202 = call ptr @libmetis__idxmalloc(i64 noundef %201, ptr noundef @.str.11)
  %203 = load ptr, ptr %9, align 8, !tbaa !5
  %204 = getelementptr inbounds %struct.graphdef, ptr %203, i32 0, i32 3
  store ptr %202, ptr %204, align 8, !tbaa !24
  %205 = load i64, ptr %20, align 8, !tbaa !9
  %206 = call ptr @libmetis__idxmalloc(i64 noundef %205, ptr noundef @.str.12)
  %207 = load ptr, ptr %9, align 8, !tbaa !5
  %208 = getelementptr inbounds %struct.graphdef, ptr %207, i32 0, i32 13
  store ptr %206, ptr %208, align 8, !tbaa !25
  %209 = load i64, ptr %20, align 8, !tbaa !9
  %210 = call ptr @libmetis__idxmalloc(i64 noundef %209, ptr noundef @.str.13)
  %211 = load ptr, ptr %9, align 8, !tbaa !5
  %212 = getelementptr inbounds %struct.graphdef, ptr %211, i32 0, i32 15
  store ptr %210, ptr %212, align 8, !tbaa !26
  %213 = load i64, ptr %21, align 8, !tbaa !9
  %214 = call ptr @libmetis__idxmalloc(i64 noundef %213, ptr noundef @.str.16)
  %215 = load ptr, ptr %9, align 8, !tbaa !5
  %216 = getelementptr inbounds %struct.graphdef, ptr %215, i32 0, i32 5
  store ptr %214, ptr %216, align 8, !tbaa !22
  store ptr %214, ptr %23, align 8, !tbaa !5
  %217 = load i64, ptr %21, align 8, !tbaa !9
  %218 = call ptr @libmetis__idxmalloc(i64 noundef %217, ptr noundef @.str.14)
  %219 = load ptr, ptr %9, align 8, !tbaa !5
  %220 = getelementptr inbounds %struct.graphdef, ptr %219, i32 0, i32 6
  store ptr %218, ptr %220, align 8, !tbaa !27
  store i64 0, ptr %18, align 8, !tbaa !9
  store i64 0, ptr %21, align 8, !tbaa !9
  %221 = load ptr, ptr %22, align 8, !tbaa !5
  %222 = getelementptr inbounds i64, ptr %221, i64 0
  store i64 0, ptr %222, align 8, !tbaa !9
  store i64 0, ptr %15, align 8, !tbaa !9
  br label %223

223:                                              ; preds = %282, %195
  %224 = load i64, ptr %15, align 8, !tbaa !9
  %225 = load i64, ptr %10, align 8, !tbaa !9
  %226 = icmp slt i64 %224, %225
  br i1 %226, label %227, label %285

227:                                              ; preds = %223
  %228 = load ptr, ptr %11, align 8, !tbaa !5
  %229 = load i64, ptr %15, align 8, !tbaa !9
  %230 = add nsw i64 %229, 1
  %231 = getelementptr inbounds i64, ptr %228, i64 %230
  %232 = load i64, ptr %231, align 8, !tbaa !9
  %233 = load ptr, ptr %11, align 8, !tbaa !5
  %234 = load i64, ptr %15, align 8, !tbaa !9
  %235 = getelementptr inbounds i64, ptr %233, i64 %234
  %236 = load i64, ptr %235, align 8, !tbaa !9
  %237 = sub nsw i64 %232, %236
  %238 = sitofp i64 %237 to float
  %239 = load float, ptr %14, align 4, !tbaa !11
  %240 = fcmp olt float %238, %239
  br i1 %240, label %241, label %281

241:                                              ; preds = %227
  %242 = load ptr, ptr %11, align 8, !tbaa !5
  %243 = load i64, ptr %15, align 8, !tbaa !9
  %244 = getelementptr inbounds i64, ptr %242, i64 %243
  %245 = load i64, ptr %244, align 8, !tbaa !9
  store i64 %245, ptr %16, align 8, !tbaa !9
  br label %246

246:                                              ; preds = %272, %241
  %247 = load i64, ptr %16, align 8, !tbaa !9
  %248 = load ptr, ptr %11, align 8, !tbaa !5
  %249 = load i64, ptr %15, align 8, !tbaa !9
  %250 = add nsw i64 %249, 1
  %251 = getelementptr inbounds i64, ptr %248, i64 %250
  %252 = load i64, ptr %251, align 8, !tbaa !9
  %253 = icmp slt i64 %247, %252
  br i1 %253, label %254, label %275

254:                                              ; preds = %246
  %255 = load ptr, ptr %25, align 8, !tbaa !5
  %256 = load ptr, ptr %12, align 8, !tbaa !5
  %257 = load i64, ptr %16, align 8, !tbaa !9
  %258 = getelementptr inbounds i64, ptr %256, i64 %257
  %259 = load i64, ptr %258, align 8, !tbaa !9
  %260 = getelementptr inbounds i64, ptr %255, i64 %259
  %261 = load i64, ptr %260, align 8, !tbaa !9
  store i64 %261, ptr %17, align 8, !tbaa !9
  %262 = load i64, ptr %17, align 8, !tbaa !9
  %263 = load i64, ptr %20, align 8, !tbaa !9
  %264 = icmp slt i64 %262, %263
  br i1 %264, label %265, label %271

265:                                              ; preds = %254
  %266 = load i64, ptr %17, align 8, !tbaa !9
  %267 = load ptr, ptr %23, align 8, !tbaa !5
  %268 = load i64, ptr %21, align 8, !tbaa !9
  %269 = add nsw i64 %268, 1
  store i64 %269, ptr %21, align 8, !tbaa !9
  %270 = getelementptr inbounds i64, ptr %267, i64 %268
  store i64 %266, ptr %270, align 8, !tbaa !9
  br label %271

271:                                              ; preds = %265, %254
  br label %272

272:                                              ; preds = %271
  %273 = load i64, ptr %16, align 8, !tbaa !9
  %274 = add nsw i64 %273, 1
  store i64 %274, ptr %16, align 8, !tbaa !9
  br label %246, !llvm.loop !31

275:                                              ; preds = %246
  %276 = load i64, ptr %21, align 8, !tbaa !9
  %277 = load ptr, ptr %22, align 8, !tbaa !5
  %278 = load i64, ptr %18, align 8, !tbaa !9
  %279 = add nsw i64 %278, 1
  store i64 %279, ptr %18, align 8, !tbaa !9
  %280 = getelementptr inbounds i64, ptr %277, i64 %279
  store i64 %276, ptr %280, align 8, !tbaa !9
  br label %281

281:                                              ; preds = %275, %227
  br label %282

282:                                              ; preds = %281
  %283 = load i64, ptr %15, align 8, !tbaa !9
  %284 = add nsw i64 %283, 1
  store i64 %284, ptr %15, align 8, !tbaa !9
  br label %223, !llvm.loop !32

285:                                              ; preds = %223
  %286 = load i64, ptr %20, align 8, !tbaa !9
  %287 = load ptr, ptr %9, align 8, !tbaa !5
  %288 = getelementptr inbounds %struct.graphdef, ptr %287, i32 0, i32 0
  store i64 %286, ptr %288, align 8, !tbaa !15
  %289 = load i64, ptr %21, align 8, !tbaa !9
  %290 = load ptr, ptr %9, align 8, !tbaa !5
  %291 = getelementptr inbounds %struct.graphdef, ptr %290, i32 0, i32 1
  store i64 %289, ptr %291, align 8, !tbaa !18
  %292 = load ptr, ptr %9, align 8, !tbaa !5
  %293 = getelementptr inbounds %struct.graphdef, ptr %292, i32 0, i32 28
  store i64 1, ptr %293, align 8, !tbaa !19
  %294 = load i64, ptr %20, align 8, !tbaa !9
  %295 = load ptr, ptr %9, align 8, !tbaa !5
  %296 = getelementptr inbounds %struct.graphdef, ptr %295, i32 0, i32 3
  %297 = load ptr, ptr %296, align 8, !tbaa !24
  %298 = call ptr @libmetis__idxset(i64 noundef %294, i64 noundef 1, ptr noundef %297)
  %299 = load i64, ptr %21, align 8, !tbaa !9
  %300 = load ptr, ptr %9, align 8, !tbaa !5
  %301 = getelementptr inbounds %struct.graphdef, ptr %300, i32 0, i32 6
  %302 = load ptr, ptr %301, align 8, !tbaa !27
  %303 = call ptr @libmetis__idxset(i64 noundef %299, i64 noundef 1, ptr noundef %302)
  store i64 0, ptr %15, align 8, !tbaa !9
  br label %304

304:                                              ; preds = %324, %285
  %305 = load i64, ptr %15, align 8, !tbaa !9
  %306 = load i64, ptr %20, align 8, !tbaa !9
  %307 = icmp slt i64 %305, %306
  br i1 %307, label %308, label %327

308:                                              ; preds = %304
  %309 = load ptr, ptr %22, align 8, !tbaa !5
  %310 = load i64, ptr %15, align 8, !tbaa !9
  %311 = add nsw i64 %310, 1
  %312 = getelementptr inbounds i64, ptr %309, i64 %311
  %313 = load i64, ptr %312, align 8, !tbaa !9
  %314 = load ptr, ptr %22, align 8, !tbaa !5
  %315 = load i64, ptr %15, align 8, !tbaa !9
  %316 = getelementptr inbounds i64, ptr %314, i64 %315
  %317 = load i64, ptr %316, align 8, !tbaa !9
  %318 = sub nsw i64 %313, %317
  %319 = load ptr, ptr %9, align 8, !tbaa !5
  %320 = getelementptr inbounds %struct.graphdef, ptr %319, i32 0, i32 13
  %321 = load ptr, ptr %320, align 8, !tbaa !25
  %322 = load i64, ptr %15, align 8, !tbaa !9
  %323 = getelementptr inbounds i64, ptr %321, i64 %322
  store i64 %318, ptr %323, align 8, !tbaa !9
  br label %324

324:                                              ; preds = %308
  %325 = load i64, ptr %15, align 8, !tbaa !9
  %326 = add nsw i64 %325, 1
  store i64 %326, ptr %15, align 8, !tbaa !9
  br label %304, !llvm.loop !33

327:                                              ; preds = %304
  %328 = load i64, ptr %20, align 8, !tbaa !9
  %329 = call ptr @libmetis__idxmalloc(i64 noundef %328, ptr noundef @.str.7)
  %330 = load ptr, ptr %9, align 8, !tbaa !5
  %331 = getelementptr inbounds %struct.graphdef, ptr %330, i32 0, i32 14
  store ptr %329, ptr %331, align 8, !tbaa !29
  store i64 0, ptr %15, align 8, !tbaa !9
  br label %332

332:                                              ; preds = %343, %327
  %333 = load i64, ptr %15, align 8, !tbaa !9
  %334 = load i64, ptr %20, align 8, !tbaa !9
  %335 = icmp slt i64 %333, %334
  br i1 %335, label %336, label %346

336:                                              ; preds = %332
  %337 = load i64, ptr %15, align 8, !tbaa !9
  %338 = load ptr, ptr %9, align 8, !tbaa !5
  %339 = getelementptr inbounds %struct.graphdef, ptr %338, i32 0, i32 14
  %340 = load ptr, ptr %339, align 8, !tbaa !29
  %341 = load i64, ptr %15, align 8, !tbaa !9
  %342 = getelementptr inbounds i64, ptr %340, i64 %341
  store i64 %337, ptr %342, align 8, !tbaa !9
  br label %343

343:                                              ; preds = %336
  %344 = load i64, ptr %15, align 8, !tbaa !9
  %345 = add nsw i64 %344, 1
  store i64 %345, ptr %15, align 8, !tbaa !9
  br label %332, !llvm.loop !34

346:                                              ; preds = %332
  br label %347

347:                                              ; preds = %346, %194
  call void (ptr, ...) @gk_free(ptr noundef %25, ptr noundef null)
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #3
  ret void
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { 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, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"float", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = !{!16, !10, i64 0}
!16 = !{!"graphdef", !10, i64 0, !10, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !17, i64 56, !17, i64 60, !17, i64 64, !17, i64 68, !17, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !10, i64 112, !10, i64 120, !6, i64 128, !6, i64 136, !10, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !10, i64 208, !6, i64 216, !6, i64 224, !6, i64 232, !6, i64 240}
!17 = !{!"int", !7, i64 0}
!18 = !{!16, !10, i64 8}
!19 = !{!16, !10, i64 208}
!20 = !{!16, !6, i64 16}
!21 = !{!16, !17, i64 56}
!22 = !{!16, !6, i64 40}
!23 = !{!16, !17, i64 68}
!24 = !{!16, !6, i64 24}
!25 = !{!16, !6, i64 88}
!26 = !{!16, !6, i64 104}
!27 = !{!16, !6, i64 48}
!28 = distinct !{!28, !14}
!29 = !{!16, !6, i64 96}
!30 = distinct !{!30, !14}
!31 = distinct !{!31, !14}
!32 = distinct !{!32, !14}
!33 = distinct !{!33, !14}
!34 = distinct !{!34, !14}


; 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.7 = external hidden unnamed_addr constant [21 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.16 = 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

declare void @libmetis__InitGraph(ptr noundef) local_unnamed_addr #1

declare ptr @libmetis__idxmalloc(i64 noundef, ptr noundef) local_unnamed_addr #1

declare ptr @libmetis__idxset(i64 noundef, i64 noundef, ptr noundef) local_unnamed_addr #1

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

; 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
define dso_local void @libmetis__PruneGraph(ptr nocapture noundef readnone %0, ptr noundef %1, i64 noundef %2, ptr noundef %3, ptr noundef %4, ptr nocapture noundef writeonly %5, float noundef %6) local_unnamed_addr #2 {
  %8 = alloca ptr, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #3
  %9 = tail call ptr @libmetis__idxmalloc(i64 noundef %2, ptr noundef nonnull @.str.10) #3
  store ptr %9, ptr %8, align 8, !tbaa !5
  %10 = getelementptr inbounds i64, ptr %3, i64 %2
  %11 = load i64, ptr %10, align 8, !tbaa !9
  %12 = sitofp i64 %11 to float
  %13 = fmul float %12, %6
  %14 = sitofp i64 %2 to float
  %15 = fdiv float %13, %14
  %16 = icmp sgt i64 %2, 0
  br i1 %16, label %.lr.ph, label %._crit_edge.thread

._crit_edge.thread:                               ; preds = %7
  tail call void @libmetis__InitGraph(ptr noundef %1) #3
  br label %40

.lr.ph:                                           ; preds = %7, %38
  %.0155 = phi i64 [ %17, %38 ], [ 0, %7 ]
  %.0136154 = phi i64 [ %.1137, %38 ], [ 0, %7 ]
  %.0142153 = phi i64 [ %.1143, %38 ], [ 0, %7 ]
  %.0144152 = phi i64 [ %.1145, %38 ], [ 0, %7 ]
  %17 = add nuw nsw i64 %.0155, 1
  %18 = getelementptr inbounds i64, ptr %3, i64 %17
  %19 = load i64, ptr %18, align 8, !tbaa !9
  %20 = getelementptr inbounds i64, ptr %3, i64 %.0155
  %21 = load i64, ptr %20, align 8, !tbaa !9
  %22 = sub nsw i64 %19, %21
  %23 = sitofp i64 %22 to float
  %24 = fcmp ogt float %15, %23
  br i1 %24, label %25, label %33

25:                                               ; preds = %.lr.ph
  %26 = getelementptr inbounds i64, ptr %9, i64 %.0155
  store i64 %.0142153, ptr %26, align 8, !tbaa !9
  %27 = add nsw i64 %.0142153, 1
  %28 = getelementptr inbounds i64, ptr %5, i64 %.0142153
  store i64 %.0155, ptr %28, align 8, !tbaa !9
  %29 = load i64, ptr %18, align 8, !tbaa !9
  %30 = load i64, ptr %20, align 8, !tbaa !9
  %31 = add i64 %29, %.0136154
  %32 = sub i64 %31, %30
  br label %38

33:                                               ; preds = %.lr.ph
  %34 = add nsw i64 %.0144152, 1
  %35 = sub nsw i64 %2, %34
  %36 = getelementptr inbounds i64, ptr %9, i64 %.0155
  store i64 %35, ptr %36, align 8, !tbaa !9
  %37 = getelementptr inbounds i64, ptr %5, i64 %35
  store i64 %.0155, ptr %37, align 8, !tbaa !9
  br label %38

38:                                               ; preds = %25, %33
  %.1145 = phi i64 [ %.0144152, %25 ], [ %34, %33 ]
  %.1143 = phi i64 [ %27, %25 ], [ %.0142153, %33 ]
  %.1137 = phi i64 [ %32, %25 ], [ %.0136154, %33 ]
  %exitcond.not = icmp eq i64 %17, %2
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !11

._crit_edge:                                      ; preds = %38
  %39 = icmp eq i64 %.1145, 0
  tail call void @libmetis__InitGraph(ptr noundef %1) #3
  br i1 %39, label %40, label %119

40:                                               ; preds = %._crit_edge.thread, %._crit_edge
  store i64 %2, ptr %1, align 8, !tbaa !13
  %41 = load i64, ptr %10, align 8, !tbaa !9
  %42 = getelementptr inbounds i8, ptr %1, i64 8
  store i64 %41, ptr %42, align 8, !tbaa !16
  %43 = getelementptr inbounds i8, ptr %1, i64 208
  store i64 1, ptr %43, align 8, !tbaa !17
  %44 = getelementptr inbounds i8, ptr %1, i64 16
  store ptr %3, ptr %44, align 8, !tbaa !18
  %45 = getelementptr inbounds i8, ptr %1, i64 56
  store i32 0, ptr %45, align 8, !tbaa !19
  %46 = getelementptr inbounds i8, ptr %1, i64 40
  store ptr %4, ptr %46, align 8, !tbaa !20
  %47 = getelementptr inbounds i8, ptr %1, i64 68
  store i32 0, ptr %47, align 4, !tbaa !21
  %48 = tail call ptr @libmetis__idxmalloc(i64 noundef %2, ptr noundef nonnull @.str.11) #3
  %49 = getelementptr inbounds i8, ptr %1, i64 24
  store ptr %48, ptr %49, align 8, !tbaa !22
  %50 = tail call ptr @libmetis__idxmalloc(i64 noundef %2, ptr noundef nonnull @.str.12) #3
  %51 = getelementptr inbounds i8, ptr %1, i64 88
  store ptr %50, ptr %51, align 8, !tbaa !23
  %52 = tail call ptr @libmetis__idxmalloc(i64 noundef %2, ptr noundef nonnull @.str.13) #3
  %53 = getelementptr inbounds i8, ptr %1, i64 104
  store ptr %52, ptr %53, align 8, !tbaa !24
  %54 = load i64, ptr %42, align 8, !tbaa !16
  %55 = tail call ptr @libmetis__idxmalloc(i64 noundef %54, ptr noundef nonnull @.str.14) #3
  %56 = getelementptr inbounds i8, ptr %1, i64 48
  store ptr %55, ptr %56, align 8, !tbaa !25
  %57 = load ptr, ptr %49, align 8, !tbaa !22
  %58 = tail call ptr @libmetis__idxset(i64 noundef %2, i64 noundef 1, ptr noundef %57) #3
  %59 = load i64, ptr %42, align 8, !tbaa !16
  %60 = load ptr, ptr %56, align 8, !tbaa !25
  %61 = tail call ptr @libmetis__idxset(i64 noundef %59, i64 noundef 1, ptr noundef %60) #3
  br i1 %16, label %.lr.ph179, label %.loopexit.sink.split

.lr.ph179:                                        ; preds = %40
  %62 = load ptr, ptr %51, align 8, !tbaa !23
  %min.iters.check221 = icmp ult i64 %2, 10
  br i1 %min.iters.check221, label %scalar.ph220.preheader, label %vector.memcheck213

vector.memcheck213:                               ; preds = %.lr.ph179
  %63 = shl i64 %2, 3
  %scevgep214 = getelementptr i8, ptr %62, i64 %63
  %64 = getelementptr i8, ptr %3, i64 %63
  %scevgep215 = getelementptr i8, ptr %64, i64 8
  %bound0216 = icmp ult ptr %62, %scevgep215
  %bound1217 = icmp ugt ptr %scevgep214, %3
  %found.conflict218 = and i1 %bound0216, %bound1217
  br i1 %found.conflict218, label %scalar.ph220.preheader, label %vector.ph222

vector.ph222:                                     ; preds = %vector.memcheck213
  %n.vec224 = and i64 %2, 9223372036854775804
  br label %vector.body226

vector.body226:                                   ; preds = %vector.body226, %vector.ph222
  %index227 = phi i64 [ 0, %vector.ph222 ], [ %index.next232, %vector.body226 ]
  %65 = or disjoint i64 %index227, 1
  %66 = getelementptr inbounds i64, ptr %3, i64 %65
  %67 = getelementptr inbounds i8, ptr %66, i64 16
  %wide.load228 = load <2 x i64>, ptr %66, align 8, !tbaa !9, !alias.scope !26
  %wide.load229 = load <2 x i64>, ptr %67, align 8, !tbaa !9, !alias.scope !26
  %68 = getelementptr inbounds i64, ptr %3, i64 %index227
  %69 = getelementptr inbounds i8, ptr %68, i64 16
  %wide.load230 = load <2 x i64>, ptr %68, align 8, !tbaa !9, !alias.scope !26
  %wide.load231 = load <2 x i64>, ptr %69, align 8, !tbaa !9, !alias.scope !26
  %70 = sub nsw <2 x i64> %wide.load228, %wide.load230
  %71 = sub nsw <2 x i64> %wide.load229, %wide.load231
  %72 = getelementptr inbounds i64, ptr %62, i64 %index227
  %73 = getelementptr inbounds i8, ptr %72, i64 16
  store <2 x i64> %70, ptr %72, align 8, !tbaa !9, !alias.scope !29, !noalias !26
  store <2 x i64> %71, ptr %73, align 8, !tbaa !9, !alias.scope !29, !noalias !26
  %index.next232 = add nuw i64 %index227, 4
  %74 = icmp eq i64 %index.next232, %n.vec224
  br i1 %74, label %middle.block219, label %vector.body226, !llvm.loop !31

middle.block219:                                  ; preds = %vector.body226
  %cmp.n233 = icmp eq i64 %n.vec224, %2
  br i1 %cmp.n233, label %._crit_edge180, label %scalar.ph220.preheader

scalar.ph220.preheader:                           ; preds = %middle.block219, %vector.memcheck213, %.lr.ph179
  %.1177.ph = phi i64 [ 0, %vector.memcheck213 ], [ 0, %.lr.ph179 ], [ %n.vec224, %middle.block219 ]
  %xtraiter252 = and i64 %2, 3
  %lcmp.mod253.not = icmp eq i64 %xtraiter252, 0
  br i1 %lcmp.mod253.not, label %scalar.ph220.prol.loopexit, label %scalar.ph220.prol

scalar.ph220.prol:                                ; preds = %scalar.ph220.preheader, %scalar.ph220.prol
  %.1177.prol = phi i64 [ %75, %scalar.ph220.prol ], [ %.1177.ph, %scalar.ph220.preheader ]
  %prol.iter254 = phi i64 [ %prol.iter254.next, %scalar.ph220.prol ], [ 0, %scalar.ph220.preheader ]
  %75 = add nuw nsw i64 %.1177.prol, 1
  %76 = getelementptr inbounds i64, ptr %3, i64 %75
  %77 = load i64, ptr %76, align 8, !tbaa !9
  %78 = getelementptr inbounds i64, ptr %3, i64 %.1177.prol
  %79 = load i64, ptr %78, align 8, !tbaa !9
  %80 = sub nsw i64 %77, %79
  %81 = getelementptr inbounds i64, ptr %62, i64 %.1177.prol
  store i64 %80, ptr %81, align 8, !tbaa !9
  %prol.iter254.next = add i64 %prol.iter254, 1
  %prol.iter254.cmp.not = icmp eq i64 %prol.iter254.next, %xtraiter252
  br i1 %prol.iter254.cmp.not, label %scalar.ph220.prol.loopexit, label %scalar.ph220.prol, !llvm.loop !34

scalar.ph220.prol.loopexit:                       ; preds = %scalar.ph220.prol, %scalar.ph220.preheader
  %.1177.unr = phi i64 [ %.1177.ph, %scalar.ph220.preheader ], [ %75, %scalar.ph220.prol ]
  %82 = sub nsw i64 %.1177.ph, %2
  %83 = icmp ugt i64 %82, -4
  br i1 %83, label %._crit_edge180, label %scalar.ph220

scalar.ph220:                                     ; preds = %scalar.ph220.prol.loopexit, %scalar.ph220
  %.1177 = phi i64 [ %105, %scalar.ph220 ], [ %.1177.unr, %scalar.ph220.prol.loopexit ]
  %84 = add nuw nsw i64 %.1177, 1
  %85 = getelementptr inbounds i64, ptr %3, i64 %84
  %86 = load i64, ptr %85, align 8, !tbaa !9
  %87 = getelementptr inbounds i64, ptr %3, i64 %.1177
  %88 = load i64, ptr %87, align 8, !tbaa !9
  %89 = sub nsw i64 %86, %88
  %90 = getelementptr inbounds i64, ptr %62, i64 %.1177
  store i64 %89, ptr %90, align 8, !tbaa !9
  %91 = add nuw nsw i64 %.1177, 2
  %92 = getelementptr inbounds i64, ptr %3, i64 %91
  %93 = load i64, ptr %92, align 8, !tbaa !9
  %94 = getelementptr inbounds i64, ptr %3, i64 %84
  %95 = load i64, ptr %94, align 8, !tbaa !9
  %96 = sub nsw i64 %93, %95
  %97 = getelementptr inbounds i64, ptr %62, i64 %84
  store i64 %96, ptr %97, align 8, !tbaa !9
  %98 = add nuw nsw i64 %.1177, 3
  %99 = getelementptr inbounds i64, ptr %3, i64 %98
  %100 = load i64, ptr %99, align 8, !tbaa !9
  %101 = getelementptr inbounds i64, ptr %3, i64 %91
  %102 = load i64, ptr %101, align 8, !tbaa !9
  %103 = sub nsw i64 %100, %102
  %104 = getelementptr inbounds i64, ptr %62, i64 %91
  store i64 %103, ptr %104, align 8, !tbaa !9
  %105 = add nuw nsw i64 %.1177, 4
  %106 = getelementptr inbounds i64, ptr %3, i64 %105
  %107 = load i64, ptr %106, align 8, !tbaa !9
  %108 = getelementptr inbounds i64, ptr %3, i64 %98
  %109 = load i64, ptr %108, align 8, !tbaa !9
  %110 = sub nsw i64 %107, %109
  %111 = getelementptr inbounds i64, ptr %62, i64 %98
  store i64 %110, ptr %111, align 8, !tbaa !9
  %exitcond188.not.3 = icmp eq i64 %105, %2
  br i1 %exitcond188.not.3, label %._crit_edge180, label %scalar.ph220, !llvm.loop !36

._crit_edge180:                                   ; preds = %scalar.ph220.prol.loopexit, %scalar.ph220, %middle.block219
  %112 = tail call ptr @libmetis__idxmalloc(i64 noundef %2, ptr noundef nonnull @.str.7) #3
  %113 = getelementptr inbounds i8, ptr %1, i64 96
  store ptr %112, ptr %113, align 8, !tbaa !37
  br i1 %16, label %.lr.ph183.preheader, label %.loopexit

.lr.ph183.preheader:                              ; preds = %._crit_edge180
  %min.iters.check236 = icmp ult i64 %2, 4
  br i1 %min.iters.check236, label %.lr.ph183.preheader249, label %vector.ph237

vector.ph237:                                     ; preds = %.lr.ph183.preheader
  %n.vec239 = and i64 %2, 9223372036854775804
  br label %vector.body241

vector.body241:                                   ; preds = %vector.body241, %vector.ph237
  %index242 = phi i64 [ 0, %vector.ph237 ], [ %index.next247, %vector.body241 ]
  %vec.ind243 = phi <2 x i64> [ <i64 0, i64 1>, %vector.ph237 ], [ %vec.ind.next246, %vector.body241 ]
  %step.add244 = add <2 x i64> %vec.ind243, <i64 2, i64 2>
  %114 = getelementptr inbounds i64, ptr %112, i64 %index242
  %115 = getelementptr inbounds i8, ptr %114, i64 16
  store <2 x i64> %vec.ind243, ptr %114, align 8, !tbaa !9
  store <2 x i64> %step.add244, ptr %115, align 8, !tbaa !9
  %index.next247 = add nuw i64 %index242, 4
  %vec.ind.next246 = add <2 x i64> %vec.ind243, <i64 4, i64 4>
  %116 = icmp eq i64 %index.next247, %n.vec239
  br i1 %116, label %middle.block234, label %vector.body241, !llvm.loop !38

middle.block234:                                  ; preds = %vector.body241
  %cmp.n248 = icmp eq i64 %n.vec239, %2
  br i1 %cmp.n248, label %.loopexit, label %.lr.ph183.preheader249

.lr.ph183.preheader249:                           ; preds = %middle.block234, %.lr.ph183.preheader
  %.2181.ph = phi i64 [ 0, %.lr.ph183.preheader ], [ %n.vec239, %middle.block234 ]
  br label %.lr.ph183

.lr.ph183:                                        ; preds = %.lr.ph183.preheader249, %.lr.ph183
  %.2181 = phi i64 [ %118, %.lr.ph183 ], [ %.2181.ph, %.lr.ph183.preheader249 ]
  %117 = getelementptr inbounds i64, ptr %112, i64 %.2181
  store i64 %.2181, ptr %117, align 8, !tbaa !9
  %118 = add nuw nsw i64 %.2181, 1
  %exitcond189.not = icmp eq i64 %118, %2
  br i1 %exitcond189.not, label %.loopexit, label %.lr.ph183, !llvm.loop !39

119:                                              ; preds = %._crit_edge
  %120 = add nsw i64 %.1143, 1
  %121 = tail call ptr @libmetis__idxmalloc(i64 noundef %120, ptr noundef nonnull @.str.15) #3
  %122 = getelementptr inbounds i8, ptr %1, i64 16
  store ptr %121, ptr %122, align 8, !tbaa !18
  %123 = tail call ptr @libmetis__idxmalloc(i64 noundef %.1143, ptr noundef nonnull @.str.11) #3
  %124 = getelementptr inbounds i8, ptr %1, i64 24
  store ptr %123, ptr %124, align 8, !tbaa !22
  %125 = tail call ptr @libmetis__idxmalloc(i64 noundef %.1143, ptr noundef nonnull @.str.12) #3
  %126 = getelementptr inbounds i8, ptr %1, i64 88
  store ptr %125, ptr %126, align 8, !tbaa !23
  %127 = tail call ptr @libmetis__idxmalloc(i64 noundef %.1143, ptr noundef nonnull @.str.13) #3
  %128 = getelementptr inbounds i8, ptr %1, i64 104
  store ptr %127, ptr %128, align 8, !tbaa !24
  %129 = tail call ptr @libmetis__idxmalloc(i64 noundef %.1137, ptr noundef nonnull @.str.16) #3
  %130 = getelementptr inbounds i8, ptr %1, i64 40
  store ptr %129, ptr %130, align 8, !tbaa !20
  %131 = tail call ptr @libmetis__idxmalloc(i64 noundef %.1137, ptr noundef nonnull @.str.14) #3
  %132 = getelementptr inbounds i8, ptr %1, i64 48
  store ptr %131, ptr %132, align 8, !tbaa !25
  store i64 0, ptr %121, align 8, !tbaa !9
  br i1 %16, label %.lr.ph167, label %._crit_edge168

.lr.ph167:                                        ; preds = %119, %157
  %.3165 = phi i64 [ %133, %157 ], [ 0, %119 ]
  %.2138164 = phi i64 [ %.5141, %157 ], [ 0, %119 ]
  %.0146163 = phi i64 [ %.1147, %157 ], [ 0, %119 ]
  %133 = add nuw nsw i64 %.3165, 1
  %134 = getelementptr inbounds i64, ptr %3, i64 %133
  %135 = load i64, ptr %134, align 8, !tbaa !9
  %136 = getelementptr inbounds i64, ptr %3, i64 %.3165
  %137 = load i64, ptr %136, align 8, !tbaa !9
  %138 = sub nsw i64 %135, %137
  %139 = sitofp i64 %138 to float
  %140 = fcmp ogt float %15, %139
  br i1 %140, label %.preheader, label %157

.preheader:                                       ; preds = %.lr.ph167
  %141 = icmp slt i64 %137, %135
  br i1 %141, label %.lr.ph160, label %._crit_edge161

.lr.ph160:                                        ; preds = %.preheader, %151
  %142 = phi i64 [ %152, %151 ], [ %135, %.preheader ]
  %.0135159 = phi i64 [ %153, %151 ], [ %137, %.preheader ]
  %.3139158 = phi i64 [ %.4140, %151 ], [ %.2138164, %.preheader ]
  %143 = getelementptr inbounds i64, ptr %4, i64 %.0135159
  %144 = load i64, ptr %143, align 8, !tbaa !9
  %145 = getelementptr inbounds i64, ptr %9, i64 %144
  %146 = load i64, ptr %145, align 8, !tbaa !9
  %147 = icmp slt i64 %146, %.1143
  br i1 %147, label %148, label %151

148:                                              ; preds = %.lr.ph160
  %149 = add nsw i64 %.3139158, 1
  %150 = getelementptr inbounds i64, ptr %129, i64 %.3139158
  store i64 %146, ptr %150, align 8, !tbaa !9
  %.pre = load i64, ptr %134, align 8, !tbaa !9
  br label %151

151:                                              ; preds = %.lr.ph160, %148
  %152 = phi i64 [ %.pre, %148 ], [ %142, %.lr.ph160 ]
  %.4140 = phi i64 [ %149, %148 ], [ %.3139158, %.lr.ph160 ]
  %153 = add nsw i64 %.0135159, 1
  %154 = icmp slt i64 %153, %152
  br i1 %154, label %.lr.ph160, label %._crit_edge161, !llvm.loop !40

._crit_edge161:                                   ; preds = %151, %.preheader
  %.3139.lcssa = phi i64 [ %.2138164, %.preheader ], [ %.4140, %151 ]
  %155 = add nsw i64 %.0146163, 1
  %156 = getelementptr inbounds i64, ptr %121, i64 %155
  store i64 %.3139.lcssa, ptr %156, align 8, !tbaa !9
  br label %157

157:                                              ; preds = %.lr.ph167, %._crit_edge161
  %.1147 = phi i64 [ %155, %._crit_edge161 ], [ %.0146163, %.lr.ph167 ]
  %.5141 = phi i64 [ %.3139.lcssa, %._crit_edge161 ], [ %.2138164, %.lr.ph167 ]
  %exitcond185.not = icmp eq i64 %133, %2
  br i1 %exitcond185.not, label %._crit_edge168, label %.lr.ph167, !llvm.loop !41

._crit_edge168:                                   ; preds = %157, %119
  %.2138.lcssa = phi i64 [ 0, %119 ], [ %.5141, %157 ]
  store i64 %.1143, ptr %1, align 8, !tbaa !13
  %158 = getelementptr inbounds i8, ptr %1, i64 8
  store i64 %.2138.lcssa, ptr %158, align 8, !tbaa !16
  %159 = getelementptr inbounds i8, ptr %1, i64 208
  store i64 1, ptr %159, align 8, !tbaa !17
  %160 = load ptr, ptr %124, align 8, !tbaa !22
  %161 = tail call ptr @libmetis__idxset(i64 noundef %.1143, i64 noundef 1, ptr noundef %160) #3
  %162 = load ptr, ptr %132, align 8, !tbaa !25
  %163 = tail call ptr @libmetis__idxset(i64 noundef %.2138.lcssa, i64 noundef 1, ptr noundef %162) #3
  %164 = icmp sgt i64 %.1143, 0
  br i1 %164, label %.lr.ph172, label %.loopexit.sink.split

.lr.ph172:                                        ; preds = %._crit_edge168
  %165 = load ptr, ptr %126, align 8, !tbaa !23
  %min.iters.check = icmp ult i64 %.1143, 8
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.memcheck

vector.memcheck:                                  ; preds = %.lr.ph172
  %166 = shl i64 %.1143, 3
  %scevgep = getelementptr i8, ptr %165, i64 %166
  %scevgep196 = getelementptr i8, ptr %121, i64 8
  %scevgep197 = getelementptr i8, ptr %scevgep196, i64 %166
  %bound0 = icmp ult ptr %165, %scevgep197
  %bound1 = icmp ult ptr %121, %scevgep
  %found.conflict = and i1 %bound0, %bound1
  br i1 %found.conflict, label %scalar.ph.preheader, label %vector.ph

vector.ph:                                        ; preds = %vector.memcheck
  %n.vec = and i64 %.1143, 9223372036854775804
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %167 = or disjoint i64 %index, 1
  %168 = getelementptr inbounds i64, ptr %121, i64 %167
  %169 = getelementptr inbounds i8, ptr %168, i64 16
  %wide.load = load <2 x i64>, ptr %168, align 8, !tbaa !9, !alias.scope !42
  %wide.load198 = load <2 x i64>, ptr %169, align 8, !tbaa !9, !alias.scope !42
  %170 = getelementptr inbounds i64, ptr %121, i64 %index
  %171 = getelementptr inbounds i8, ptr %170, i64 16
  %wide.load199 = load <2 x i64>, ptr %170, align 8, !tbaa !9, !alias.scope !42
  %wide.load200 = load <2 x i64>, ptr %171, align 8, !tbaa !9, !alias.scope !42
  %172 = sub nsw <2 x i64> %wide.load, %wide.load199
  %173 = sub nsw <2 x i64> %wide.load198, %wide.load200
  %174 = getelementptr inbounds i64, ptr %165, i64 %index
  %175 = getelementptr inbounds i8, ptr %174, i64 16
  store <2 x i64> %172, ptr %174, align 8, !tbaa !9, !alias.scope !45, !noalias !42
  store <2 x i64> %173, ptr %175, align 8, !tbaa !9, !alias.scope !45, !noalias !42
  %index.next = add nuw i64 %index, 4
  %176 = icmp eq i64 %index.next, %n.vec
  br i1 %176, label %middle.block, label %vector.body, !llvm.loop !47

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %.1143, %n.vec
  br i1 %cmp.n, label %._crit_edge173, label %scalar.ph.preheader

scalar.ph.preheader:                              ; preds = %middle.block, %vector.memcheck, %.lr.ph172
  %.4170.ph = phi i64 [ 0, %vector.memcheck ], [ 0, %.lr.ph172 ], [ %n.vec, %middle.block ]
  %xtraiter = and i64 %.1143, 3
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %scalar.ph.prol.loopexit, label %scalar.ph.prol

scalar.ph.prol:                                   ; preds = %scalar.ph.preheader, %scalar.ph.prol
  %.4170.prol = phi i64 [ %177, %scalar.ph.prol ], [ %.4170.ph, %scalar.ph.preheader ]
  %prol.iter = phi i64 [ %prol.iter.next, %scalar.ph.prol ], [ 0, %scalar.ph.preheader ]
  %177 = add nuw nsw i64 %.4170.prol, 1
  %178 = getelementptr inbounds i64, ptr %121, i64 %177
  %179 = load i64, ptr %178, align 8, !tbaa !9
  %180 = getelementptr inbounds i64, ptr %121, i64 %.4170.prol
  %181 = load i64, ptr %180, align 8, !tbaa !9
  %182 = sub nsw i64 %179, %181
  %183 = getelementptr inbounds i64, ptr %165, i64 %.4170.prol
  store i64 %182, ptr %183, align 8, !tbaa !9
  %prol.iter.next = add i64 %prol.iter, 1
  %prol.iter.cmp.not = icmp eq i64 %prol.iter.next, %xtraiter
  br i1 %prol.iter.cmp.not, label %scalar.ph.prol.loopexit, label %scalar.ph.prol, !llvm.loop !48

scalar.ph.prol.loopexit:                          ; preds = %scalar.ph.prol, %scalar.ph.preheader
  %.4170.unr = phi i64 [ %.4170.ph, %scalar.ph.preheader ], [ %177, %scalar.ph.prol ]
  %184 = sub nsw i64 %.4170.ph, %.1143
  %185 = icmp ugt i64 %184, -4
  br i1 %185, label %._crit_edge173, label %scalar.ph

scalar.ph:                                        ; preds = %scalar.ph.prol.loopexit, %scalar.ph
  %.4170 = phi i64 [ %207, %scalar.ph ], [ %.4170.unr, %scalar.ph.prol.loopexit ]
  %186 = add nuw nsw i64 %.4170, 1
  %187 = getelementptr inbounds i64, ptr %121, i64 %186
  %188 = load i64, ptr %187, align 8, !tbaa !9
  %189 = getelementptr inbounds i64, ptr %121, i64 %.4170
  %190 = load i64, ptr %189, align 8, !tbaa !9
  %191 = sub nsw i64 %188, %190
  %192 = getelementptr inbounds i64, ptr %165, i64 %.4170
  store i64 %191, ptr %192, align 8, !tbaa !9
  %193 = add nuw nsw i64 %.4170, 2
  %194 = getelementptr inbounds i64, ptr %121, i64 %193
  %195 = load i64, ptr %194, align 8, !tbaa !9
  %196 = getelementptr inbounds i64, ptr %121, i64 %186
  %197 = load i64, ptr %196, align 8, !tbaa !9
  %198 = sub nsw i64 %195, %197
  %199 = getelementptr inbounds i64, ptr %165, i64 %186
  store i64 %198, ptr %199, align 8, !tbaa !9
  %200 = add nuw nsw i64 %.4170, 3
  %201 = getelementptr inbounds i64, ptr %121, i64 %200
  %202 = load i64, ptr %201, align 8, !tbaa !9
  %203 = getelementptr inbounds i64, ptr %121, i64 %193
  %204 = load i64, ptr %203, align 8, !tbaa !9
  %205 = sub nsw i64 %202, %204
  %206 = getelementptr inbounds i64, ptr %165, i64 %193
  store i64 %205, ptr %206, align 8, !tbaa !9
  %207 = add nuw nsw i64 %.4170, 4
  %208 = getelementptr inbounds i64, ptr %121, i64 %207
  %209 = load i64, ptr %208, align 8, !tbaa !9
  %210 = getelementptr inbounds i64, ptr %121, i64 %200
  %211 = load i64, ptr %210, align 8, !tbaa !9
  %212 = sub nsw i64 %209, %211
  %213 = getelementptr inbounds i64, ptr %165, i64 %200
  store i64 %212, ptr %213, align 8, !tbaa !9
  %exitcond186.not.3 = icmp eq i64 %207, %.1143
  br i1 %exitcond186.not.3, label %._crit_edge173, label %scalar.ph, !llvm.loop !49

._crit_edge173:                                   ; preds = %scalar.ph.prol.loopexit, %scalar.ph, %middle.block
  %214 = tail call ptr @libmetis__idxmalloc(i64 noundef %.1143, ptr noundef nonnull @.str.7) #3
  %215 = getelementptr inbounds i8, ptr %1, i64 96
  store ptr %214, ptr %215, align 8, !tbaa !37
  br i1 %164, label %.lr.ph176.preheader, label %.loopexit

.lr.ph176.preheader:                              ; preds = %._crit_edge173
  %min.iters.check203 = icmp ult i64 %.1143, 4
  br i1 %min.iters.check203, label %.lr.ph176.preheader250, label %vector.ph204

vector.ph204:                                     ; preds = %.lr.ph176.preheader
  %n.vec206 = and i64 %.1143, 9223372036854775804
  br label %vector.body208

vector.body208:                                   ; preds = %vector.body208, %vector.ph204
  %index209 = phi i64 [ 0, %vector.ph204 ], [ %index.next211, %vector.body208 ]
  %vec.ind = phi <2 x i64> [ <i64 0, i64 1>, %vector.ph204 ], [ %vec.ind.next, %vector.body208 ]
  %step.add = add <2 x i64> %vec.ind, <i64 2, i64 2>
  %216 = getelementptr inbounds i64, ptr %214, i64 %index209
  %217 = getelementptr inbounds i8, ptr %216, i64 16
  store <2 x i64> %vec.ind, ptr %216, align 8, !tbaa !9
  store <2 x i64> %step.add, ptr %217, align 8, !tbaa !9
  %index.next211 = add nuw i64 %index209, 4
  %vec.ind.next = add <2 x i64> %vec.ind, <i64 4, i64 4>
  %218 = icmp eq i64 %index.next211, %n.vec206
  br i1 %218, label %middle.block201, label %vector.body208, !llvm.loop !50

middle.block201:                                  ; preds = %vector.body208
  %cmp.n212 = icmp eq i64 %.1143, %n.vec206
  br i1 %cmp.n212, label %.loopexit, label %.lr.ph176.preheader250

.lr.ph176.preheader250:                           ; preds = %middle.block201, %.lr.ph176.preheader
  %.5174.ph = phi i64 [ 0, %.lr.ph176.preheader ], [ %n.vec206, %middle.block201 ]
  br label %.lr.ph176

.lr.ph176:                                        ; preds = %.lr.ph176.preheader250, %.lr.ph176
  %.5174 = phi i64 [ %220, %.lr.ph176 ], [ %.5174.ph, %.lr.ph176.preheader250 ]
  %219 = getelementptr inbounds i64, ptr %214, i64 %.5174
  store i64 %.5174, ptr %219, align 8, !tbaa !9
  %220 = add nuw nsw i64 %.5174, 1
  %exitcond187.not = icmp eq i64 %220, %.1143
  br i1 %exitcond187.not, label %.loopexit, label %.lr.ph176, !llvm.loop !51

.loopexit.sink.split:                             ; preds = %._crit_edge168, %40
  %.1143.lcssa.sink = phi i64 [ %2, %40 ], [ %.1143, %._crit_edge168 ]
  %221 = tail call ptr @libmetis__idxmalloc(i64 noundef %.1143.lcssa.sink, ptr noundef nonnull @.str.7) #3
  %222 = getelementptr inbounds i8, ptr %1, i64 96
  store ptr %221, ptr %222, align 8, !tbaa !37
  br label %.loopexit

.loopexit:                                        ; preds = %.lr.ph176, %.lr.ph183, %middle.block201, %middle.block234, %.loopexit.sink.split, %._crit_edge173, %._crit_edge180
  call void (ptr, ...) @gk_free(ptr noundef nonnull %8, ptr noundef null) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #3
  ret void
}

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { 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, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{!14, !10, i64 0}
!14 = !{!"graphdef", !10, i64 0, !10, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !15, i64 56, !15, i64 60, !15, i64 64, !15, i64 68, !15, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !10, i64 112, !10, i64 120, !6, i64 128, !6, i64 136, !10, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !10, i64 208, !6, i64 216, !6, i64 224, !6, i64 232, !6, i64 240}
!15 = !{!"int", !7, i64 0}
!16 = !{!14, !10, i64 8}
!17 = !{!14, !10, i64 208}
!18 = !{!14, !6, i64 16}
!19 = !{!14, !15, i64 56}
!20 = !{!14, !6, i64 40}
!21 = !{!14, !15, i64 68}
!22 = !{!14, !6, i64 24}
!23 = !{!14, !6, i64 88}
!24 = !{!14, !6, i64 104}
!25 = !{!14, !6, i64 48}
!26 = !{!27}
!27 = distinct !{!27, !28}
!28 = distinct !{!28, !"LVerDomain"}
!29 = !{!30}
!30 = distinct !{!30, !28}
!31 = distinct !{!31, !12, !32, !33}
!32 = !{!"llvm.loop.isvectorized", i32 1}
!33 = !{!"llvm.loop.unroll.runtime.disable"}
!34 = distinct !{!34, !35}
!35 = !{!"llvm.loop.unroll.disable"}
!36 = distinct !{!36, !12, !32}
!37 = !{!14, !6, i64 96}
!38 = distinct !{!38, !12, !32, !33}
!39 = distinct !{!39, !12, !33, !32}
!40 = distinct !{!40, !12}
!41 = distinct !{!41, !12}
!42 = !{!43}
!43 = distinct !{!43, !44}
!44 = distinct !{!44, !"LVerDomain"}
!45 = !{!46}
!46 = distinct !{!46, !44}
!47 = distinct !{!47, !12, !32, !33}
!48 = distinct !{!48, !35}
!49 = distinct !{!49, !12, !32}
!50 = distinct !{!50, !12, !32, !33}
!51 = distinct !{!51, !12, !33, !32}


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