; LLVM IR from GGiecold-zz/Cluster_Ensembles :: src/Cluster_Ensembles/Hypergraph_Partitioning/metis-5.1.0/libmetis (refine)

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

@.str.1 = external hidden unnamed_addr constant [139 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [60 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [16 x i8], align 1
@__PRETTY_FUNCTION__.libmetis__Project2WayPartition = external hidden unnamed_addr constant [57 x i8], align 1

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

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #1

; Function Attrs: nounwind uwtable
define dso_local void @libmetis__Project2WayPartition(ptr noundef %0, ptr noundef %1) #2 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %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 ptr, align 8
  %20 = alloca ptr, align 8
  %21 = alloca ptr, 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 %3, align 8, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #4
  %26 = load ptr, ptr %3, align 8, !tbaa !5
  %27 = load ptr, ptr %4, align 8, !tbaa !5
  call void @libmetis__Allocate2WayPartitionMemory(ptr noundef %26, ptr noundef %27)
  %28 = load ptr, ptr %4, align 8, !tbaa !5
  %29 = getelementptr inbounds %struct.graph_t, ptr %28, i32 0, i32 29
  %30 = load ptr, ptr %29, align 8, !tbaa !9
  store ptr %30, ptr %25, align 8, !tbaa !5
  %31 = load ptr, ptr %25, align 8, !tbaa !5
  %32 = getelementptr inbounds %struct.graph_t, ptr %31, i32 0, i32 19
  %33 = load ptr, ptr %32, align 8, !tbaa !12
  store ptr %33, ptr %21, align 8, !tbaa !5
  %34 = load ptr, ptr %25, align 8, !tbaa !5
  %35 = getelementptr inbounds %struct.graph_t, ptr %34, i32 0, i32 22
  %36 = load ptr, ptr %35, align 8, !tbaa !13
  store ptr %36, ptr %22, align 8, !tbaa !5
  %37 = load ptr, ptr %4, align 8, !tbaa !5
  %38 = getelementptr inbounds %struct.graph_t, ptr %37, i32 0, i32 0
  %39 = load i32, ptr %38, align 8, !tbaa !14
  store i32 %39, ptr %9, align 4, !tbaa !15
  %40 = load ptr, ptr %4, align 8, !tbaa !5
  %41 = getelementptr inbounds %struct.graph_t, ptr %40, i32 0, i32 16
  %42 = load ptr, ptr %41, align 8, !tbaa !16
  store ptr %42, ptr %17, align 8, !tbaa !5
  %43 = load ptr, ptr %4, align 8, !tbaa !5
  %44 = getelementptr inbounds %struct.graph_t, ptr %43, i32 0, i32 3
  %45 = load ptr, ptr %44, align 8, !tbaa !17
  store ptr %45, ptr %14, align 8, !tbaa !5
  %46 = load ptr, ptr %4, align 8, !tbaa !5
  %47 = getelementptr inbounds %struct.graph_t, ptr %46, i32 0, i32 6
  %48 = load ptr, ptr %47, align 8, !tbaa !18
  store ptr %48, ptr %15, align 8, !tbaa !5
  %49 = load ptr, ptr %4, align 8, !tbaa !5
  %50 = getelementptr inbounds %struct.graph_t, ptr %49, i32 0, i32 7
  %51 = load ptr, ptr %50, align 8, !tbaa !19
  store ptr %51, ptr %16, align 8, !tbaa !5
  %52 = load ptr, ptr %4, align 8, !tbaa !5
  %53 = getelementptr inbounds %struct.graph_t, ptr %52, i32 0, i32 19
  %54 = load ptr, ptr %53, align 8, !tbaa !12
  store ptr %54, ptr %18, align 8, !tbaa !5
  %55 = load ptr, ptr %4, align 8, !tbaa !5
  %56 = getelementptr inbounds %struct.graph_t, ptr %55, i32 0, i32 24
  %57 = load ptr, ptr %56, align 8, !tbaa !20
  store ptr %57, ptr %23, align 8, !tbaa !5
  %58 = load ptr, ptr %4, align 8, !tbaa !5
  %59 = getelementptr inbounds %struct.graph_t, ptr %58, i32 0, i32 25
  %60 = load ptr, ptr %59, align 8, !tbaa !21
  store ptr %60, ptr %24, align 8, !tbaa !5
  %61 = load i32, ptr %9, align 4, !tbaa !15
  %62 = sext i32 %61 to i64
  %63 = load ptr, ptr %4, align 8, !tbaa !5
  %64 = getelementptr inbounds %struct.graph_t, ptr %63, i32 0, i32 22
  %65 = load ptr, ptr %64, align 8, !tbaa !13
  %66 = call ptr @libmetis__iset(i64 noundef %62, i32 noundef -1, ptr noundef %65)
  store ptr %66, ptr %19, align 8, !tbaa !5
  %67 = load ptr, ptr %4, align 8, !tbaa !5
  %68 = getelementptr inbounds %struct.graph_t, ptr %67, i32 0, i32 23
  %69 = load ptr, ptr %68, align 8, !tbaa !22
  store ptr %69, ptr %20, align 8, !tbaa !5
  store i32 0, ptr %5, align 4, !tbaa !15
  br label %70

70:                                               ; preds = %98, %2
  %71 = load i32, ptr %5, align 4, !tbaa !15
  %72 = load i32, ptr %9, align 4, !tbaa !15
  %73 = icmp slt i32 %71, %72
  br i1 %73, label %74, label %101

74:                                               ; preds = %70
  %75 = load ptr, ptr %17, align 8, !tbaa !5
  %76 = load i32, ptr %5, align 4, !tbaa !15
  %77 = sext i32 %76 to i64
  %78 = getelementptr inbounds i32, ptr %75, i64 %77
  %79 = load i32, ptr %78, align 4, !tbaa !15
  store i32 %79, ptr %6, align 4, !tbaa !15
  %80 = load ptr, ptr %21, align 8, !tbaa !5
  %81 = load i32, ptr %6, align 4, !tbaa !15
  %82 = sext i32 %81 to i64
  %83 = getelementptr inbounds i32, ptr %80, i64 %82
  %84 = load i32, ptr %83, align 4, !tbaa !15
  %85 = load ptr, ptr %18, align 8, !tbaa !5
  %86 = load i32, ptr %5, align 4, !tbaa !15
  %87 = sext i32 %86 to i64
  %88 = getelementptr inbounds i32, ptr %85, i64 %87
  store i32 %84, ptr %88, align 4, !tbaa !15
  %89 = load ptr, ptr %22, align 8, !tbaa !5
  %90 = load i32, ptr %6, align 4, !tbaa !15
  %91 = sext i32 %90 to i64
  %92 = getelementptr inbounds i32, ptr %89, i64 %91
  %93 = load i32, ptr %92, align 4, !tbaa !15
  %94 = load ptr, ptr %17, align 8, !tbaa !5
  %95 = load i32, ptr %5, align 4, !tbaa !15
  %96 = sext i32 %95 to i64
  %97 = getelementptr inbounds i32, ptr %94, i64 %96
  store i32 %93, ptr %97, align 4, !tbaa !15
  br label %98

98:                                               ; preds = %74
  %99 = load i32, ptr %5, align 4, !tbaa !15
  %100 = add nsw i32 %99, 1
  store i32 %100, ptr %5, align 4, !tbaa !15
  br label %70, !llvm.loop !23

101:                                              ; preds = %70
  store i32 0, ptr %10, align 4, !tbaa !15
  store i32 0, ptr %5, align 4, !tbaa !15
  br label %102

102:                                              ; preds = %237, %101
  %103 = load i32, ptr %5, align 4, !tbaa !15
  %104 = load i32, ptr %9, align 4, !tbaa !15
  %105 = icmp slt i32 %103, %104
  br i1 %105, label %106, label %240

106:                                              ; preds = %102
  %107 = load ptr, ptr %14, align 8, !tbaa !5
  %108 = load i32, ptr %5, align 4, !tbaa !15
  %109 = sext i32 %108 to i64
  %110 = getelementptr inbounds i32, ptr %107, i64 %109
  %111 = load i32, ptr %110, align 4, !tbaa !15
  store i32 %111, ptr %7, align 4, !tbaa !15
  %112 = load ptr, ptr %14, align 8, !tbaa !5
  %113 = load i32, ptr %5, align 4, !tbaa !15
  %114 = add nsw i32 %113, 1
  %115 = sext i32 %114 to i64
  %116 = getelementptr inbounds i32, ptr %112, i64 %115
  %117 = load i32, ptr %116, align 4, !tbaa !15
  store i32 %117, ptr %8, align 4, !tbaa !15
  store i32 0, ptr %13, align 4, !tbaa !15
  store i32 0, ptr %12, align 4, !tbaa !15
  %118 = load ptr, ptr %17, align 8, !tbaa !5
  %119 = load i32, ptr %5, align 4, !tbaa !15
  %120 = sext i32 %119 to i64
  %121 = getelementptr inbounds i32, ptr %118, i64 %120
  %122 = load i32, ptr %121, align 4, !tbaa !15
  %123 = icmp eq i32 %122, -1
  br i1 %123, label %124, label %142

124:                                              ; preds = %106
  %125 = load i32, ptr %7, align 4, !tbaa !15
  store i32 %125, ptr %6, align 4, !tbaa !15
  br label %126

126:                                              ; preds = %138, %124
  %127 = load i32, ptr %6, align 4, !tbaa !15
  %128 = load i32, ptr %8, align 4, !tbaa !15
  %129 = icmp slt i32 %127, %128
  br i1 %129, label %130, label %141

130:                                              ; preds = %126
  %131 = load ptr, ptr %16, align 8, !tbaa !5
  %132 = load i32, ptr %6, align 4, !tbaa !15
  %133 = sext i32 %132 to i64
  %134 = getelementptr inbounds i32, ptr %131, i64 %133
  %135 = load i32, ptr %134, align 4, !tbaa !15
  %136 = load i32, ptr %12, align 4, !tbaa !15
  %137 = add nsw i32 %136, %135
  store i32 %137, ptr %12, align 4, !tbaa !15
  br label %138

138:                                              ; preds = %130
  %139 = load i32, ptr %6, align 4, !tbaa !15
  %140 = add nsw i32 %139, 1
  store i32 %140, ptr %6, align 4, !tbaa !15
  br label %126, !llvm.loop !25

141:                                              ; preds = %126
  br label %186

142:                                              ; preds = %106
  %143 = load ptr, ptr %18, align 8, !tbaa !5
  %144 = load i32, ptr %5, align 4, !tbaa !15
  %145 = sext i32 %144 to i64
  %146 = getelementptr inbounds i32, ptr %143, i64 %145
  %147 = load i32, ptr %146, align 4, !tbaa !15
  store i32 %147, ptr %11, align 4, !tbaa !15
  %148 = load i32, ptr %7, align 4, !tbaa !15
  store i32 %148, ptr %6, align 4, !tbaa !15
  br label %149

149:                                              ; preds = %182, %142
  %150 = load i32, ptr %6, align 4, !tbaa !15
  %151 = load i32, ptr %8, align 4, !tbaa !15
  %152 = icmp slt i32 %150, %151
  br i1 %152, label %153, label %185

153:                                              ; preds = %149
  %154 = load i32, ptr %11, align 4, !tbaa !15
  %155 = load ptr, ptr %18, align 8, !tbaa !5
  %156 = load ptr, ptr %15, align 8, !tbaa !5
  %157 = load i32, ptr %6, align 4, !tbaa !15
  %158 = sext i32 %157 to i64
  %159 = getelementptr inbounds i32, ptr %156, i64 %158
  %160 = load i32, ptr %159, align 4, !tbaa !15
  %161 = sext i32 %160 to i64
  %162 = getelementptr inbounds i32, ptr %155, i64 %161
  %163 = load i32, ptr %162, align 4, !tbaa !15
  %164 = icmp eq i32 %154, %163
  br i1 %164, label %165, label %173

165:                                              ; preds = %153
  %166 = load ptr, ptr %16, align 8, !tbaa !5
  %167 = load i32, ptr %6, align 4, !tbaa !15
  %168 = sext i32 %167 to i64
  %169 = getelementptr inbounds i32, ptr %166, i64 %168
  %170 = load i32, ptr %169, align 4, !tbaa !15
  %171 = load i32, ptr %12, align 4, !tbaa !15
  %172 = add nsw i32 %171, %170
  store i32 %172, ptr %12, align 4, !tbaa !15
  br label %181

173:                                              ; preds = %153
  %174 = load ptr, ptr %16, align 8, !tbaa !5
  %175 = load i32, ptr %6, align 4, !tbaa !15
  %176 = sext i32 %175 to i64
  %177 = getelementptr inbounds i32, ptr %174, i64 %176
  %178 = load i32, ptr %177, align 4, !tbaa !15
  %179 = load i32, ptr %13, align 4, !tbaa !15
  %180 = add nsw i32 %179, %178
  store i32 %180, ptr %13, align 4, !tbaa !15
  br label %181

181:                                              ; preds = %173, %165
  br label %182

182:                                              ; preds = %181
  %183 = load i32, ptr %6, align 4, !tbaa !15
  %184 = add nsw i32 %183, 1
  store i32 %184, ptr %6, align 4, !tbaa !15
  br label %149, !llvm.loop !26

185:                                              ; preds = %149
  br label %186

186:                                              ; preds = %185, %141
  %187 = load i32, ptr %12, align 4, !tbaa !15
  %188 = load ptr, ptr %23, align 8, !tbaa !5
  %189 = load i32, ptr %5, align 4, !tbaa !15
  %190 = sext i32 %189 to i64
  %191 = getelementptr inbounds i32, ptr %188, i64 %190
  store i32 %187, ptr %191, align 4, !tbaa !15
  %192 = load i32, ptr %13, align 4, !tbaa !15
  %193 = load ptr, ptr %24, align 8, !tbaa !5
  %194 = load i32, ptr %5, align 4, !tbaa !15
  %195 = sext i32 %194 to i64
  %196 = getelementptr inbounds i32, ptr %193, i64 %195
  store i32 %192, ptr %196, align 4, !tbaa !15
  %197 = load i32, ptr %13, align 4, !tbaa !15
  %198 = icmp sgt i32 %197, 0
  br i1 %198, label %203, label %199

199:                                              ; preds = %186
  %200 = load i32, ptr %7, align 4, !tbaa !15
  %201 = load i32, ptr %8, align 4, !tbaa !15
  %202 = icmp eq i32 %200, %201
  br i1 %202, label %203, label %236

203:                                              ; preds = %199, %186
  br label %204

204:                                              ; preds = %203
  %205 = load ptr, ptr %19, align 8, !tbaa !5
  %206 = load i32, ptr %5, align 4, !tbaa !15
  %207 = sext i32 %206 to i64
  %208 = getelementptr inbounds i32, ptr %205, i64 %207
  %209 = load i32, ptr %208, align 4, !tbaa !15
  %210 = icmp eq i32 %209, -1
  br i1 %210, label %222, label %211

211:                                              ; preds = %204
  %212 = call i32 (ptr, ...) @printf(ptr noundef @.str.13, i32 noundef 200, ptr noundef @.str.1)
  %213 = load ptr, ptr %19, align 8, !tbaa !5
  %214 = load i32, ptr %5, align 4, !tbaa !15
  %215 = sext i32 %214 to i64
  %216 = getelementptr inbounds i32, ptr %213, i64 %215
  %217 = load i32, ptr %216, align 4, !tbaa !15
  %218 = icmp eq i32 %217, -1
  br i1 %218, label %219, label %220

219:                                              ; preds = %211
  br label %221

220:                                              ; preds = %211
  call void @__assert_fail(ptr noundef @.str.14, ptr noundef @.str.1, i32 noundef 200, ptr noundef @__PRETTY_FUNCTION__.libmetis__Project2WayPartition) #5
  unreachable

221:                                              ; preds = %219
  br label %222

222:                                              ; preds = %221, %204
  %223 = load i32, ptr %5, align 4, !tbaa !15
  %224 = load ptr, ptr %20, align 8, !tbaa !5
  %225 = load i32, ptr %10, align 4, !tbaa !15
  %226 = sext i32 %225 to i64
  %227 = getelementptr inbounds i32, ptr %224, i64 %226
  store i32 %223, ptr %227, align 4, !tbaa !15
  %228 = load i32, ptr %10, align 4, !tbaa !15
  %229 = add nsw i32 %228, 1
  store i32 %229, ptr %10, align 4, !tbaa !15
  %230 = load ptr, ptr %19, align 8, !tbaa !5
  %231 = load i32, ptr %5, align 4, !tbaa !15
  %232 = sext i32 %231 to i64
  %233 = getelementptr inbounds i32, ptr %230, i64 %232
  store i32 %228, ptr %233, align 4, !tbaa !15
  br label %234

234:                                              ; preds = %222
  br label %235

235:                                              ; preds = %234
  br label %236

236:                                              ; preds = %235, %199
  br label %237

237:                                              ; preds = %236
  %238 = load i32, ptr %5, align 4, !tbaa !15
  %239 = add nsw i32 %238, 1
  store i32 %239, ptr %5, align 4, !tbaa !15
  br label %102, !llvm.loop !27

240:                                              ; preds = %102
  %241 = load ptr, ptr %25, align 8, !tbaa !5
  %242 = getelementptr inbounds %struct.graph_t, ptr %241, i32 0, i32 17
  %243 = load i32, ptr %242, align 8, !tbaa !28
  %244 = load ptr, ptr %4, align 8, !tbaa !5
  %245 = getelementptr inbounds %struct.graph_t, ptr %244, i32 0, i32 17
  store i32 %243, ptr %245, align 8, !tbaa !28
  %246 = load i32, ptr %10, align 4, !tbaa !15
  %247 = load ptr, ptr %4, align 8, !tbaa !5
  %248 = getelementptr inbounds %struct.graph_t, ptr %247, i32 0, i32 21
  store i32 %246, ptr %248, align 8, !tbaa !29
  %249 = load ptr, ptr %4, align 8, !tbaa !5
  %250 = getelementptr inbounds %struct.graph_t, ptr %249, i32 0, i32 2
  %251 = load i32, ptr %250, align 8, !tbaa !30
  %252 = mul nsw i32 2, %251
  %253 = sext i32 %252 to i64
  %254 = load ptr, ptr %25, align 8, !tbaa !5
  %255 = getelementptr inbounds %struct.graph_t, ptr %254, i32 0, i32 20
  %256 = load ptr, ptr %255, align 8, !tbaa !31
  %257 = load ptr, ptr %4, align 8, !tbaa !5
  %258 = getelementptr inbounds %struct.graph_t, ptr %257, i32 0, i32 20
  %259 = load ptr, ptr %258, align 8, !tbaa !31
  %260 = call ptr @libmetis__icopy(i64 noundef %253, ptr noundef %256, ptr noundef %259)
  %261 = load ptr, ptr %4, align 8, !tbaa !5
  %262 = getelementptr inbounds %struct.graph_t, ptr %261, i32 0, i32 29
  call void @libmetis__FreeGraph(ptr noundef %262)
  %263 = load ptr, ptr %4, align 8, !tbaa !5
  %264 = getelementptr inbounds %struct.graph_t, ptr %263, i32 0, i32 29
  store ptr null, ptr %264, align 8, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #4
  ret void
}

; Function Attrs: nounwind uwtable
declare dso_local void @libmetis__Allocate2WayPartitionMemory(ptr noundef, ptr noundef) #2

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

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

declare ptr @libmetis__iset(i64 noundef, i32 noundef, ptr noundef) #0

declare ptr @libmetis__icopy(i64 noundef, ptr noundef, ptr noundef) #0

declare void @libmetis__FreeGraph(ptr noundef) #0

attributes #0 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { noreturn 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 #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 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { nounwind }
attributes #5 = { noreturn nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !6, i64 200}
!10 = !{!"graph_t", !11, i64 0, !11, i64 4, !11, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !11, i64 72, !11, i64 76, !11, i64 80, !11, i64 84, !11, i64 88, !6, i64 96, !6, i64 104, !11, i64 112, !11, i64 116, !6, i64 120, !6, i64 128, !11, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !6, i64 208}
!11 = !{!"int", !7, i64 0}
!12 = !{!10, !6, i64 120}
!13 = !{!10, !6, i64 144}
!14 = !{!10, !11, i64 0}
!15 = !{!11, !11, i64 0}
!16 = !{!10, !6, i64 104}
!17 = !{!10, !6, i64 16}
!18 = !{!10, !6, i64 40}
!19 = !{!10, !6, i64 48}
!20 = !{!10, !6, i64 160}
!21 = !{!10, !6, i64 168}
!22 = !{!10, !6, i64 152}
!23 = distinct !{!23, !24}
!24 = !{!"llvm.loop.mustprogress"}
!25 = distinct !{!25, !24}
!26 = distinct !{!26, !24}
!27 = distinct !{!27, !24}
!28 = !{!10, !11, i64 112}
!29 = !{!10, !11, i64 136}
!30 = !{!10, !11, i64 8}
!31 = !{!10, !6, i64 128}


; 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.1 = external hidden unnamed_addr constant [139 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [60 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [16 x i8], align 1
@__PRETTY_FUNCTION__.libmetis__Project2WayPartition = external hidden unnamed_addr constant [57 x i8], align 1

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

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
define dso_local void @libmetis__Project2WayPartition(ptr noundef %0, ptr noundef %1) local_unnamed_addr #2 {
  tail call void @libmetis__Allocate2WayPartitionMemory(ptr noundef %0, ptr noundef %1)
  %3 = getelementptr inbounds i8, ptr %1, i64 200
  %4 = load ptr, ptr %3, align 8, !tbaa !5
  %5 = getelementptr inbounds i8, ptr %4, i64 120
  %6 = load ptr, ptr %5, align 8, !tbaa !11
  %7 = getelementptr inbounds i8, ptr %4, i64 144
  %8 = load ptr, ptr %7, align 8, !tbaa !12
  %9 = load i32, ptr %1, align 8, !tbaa !13
  %10 = getelementptr inbounds i8, ptr %1, i64 104
  %11 = load ptr, ptr %10, align 8, !tbaa !14
  %12 = getelementptr inbounds i8, ptr %1, i64 16
  %13 = load ptr, ptr %12, align 8, !tbaa !15
  %14 = getelementptr inbounds i8, ptr %1, i64 40
  %15 = load ptr, ptr %14, align 8, !tbaa !16
  %16 = getelementptr inbounds i8, ptr %1, i64 48
  %17 = load ptr, ptr %16, align 8, !tbaa !17
  %18 = getelementptr inbounds i8, ptr %1, i64 120
  %19 = load ptr, ptr %18, align 8, !tbaa !11
  %20 = getelementptr inbounds i8, ptr %1, i64 160
  %21 = load ptr, ptr %20, align 8, !tbaa !18
  %22 = getelementptr inbounds i8, ptr %1, i64 168
  %23 = load ptr, ptr %22, align 8, !tbaa !19
  %24 = sext i32 %9 to i64
  %25 = getelementptr inbounds i8, ptr %1, i64 144
  %26 = load ptr, ptr %25, align 8, !tbaa !12
  %27 = tail call ptr @libmetis__iset(i64 noundef %24, i32 noundef -1, ptr noundef %26) #5
  %28 = getelementptr inbounds i8, ptr %1, i64 152
  %29 = load ptr, ptr %28, align 8, !tbaa !20
  %30 = icmp sgt i32 %9, 0
  br i1 %30, label %.lr.ph.preheader, label %._crit_edge

.lr.ph.preheader:                                 ; preds = %2
  %wide.trip.count = zext nneg i32 %9 to i64
  %xtraiter = and i64 %wide.trip.count, 1
  %31 = icmp eq i32 %9, 1
  br i1 %31, label %.preheader99.unr-lcssa, label %.lr.ph.preheader.new

.lr.ph.preheader.new:                             ; preds = %.lr.ph.preheader
  %unroll_iter = and i64 %wide.trip.count, 2147483646
  br label %.lr.ph

.preheader99.unr-lcssa:                           ; preds = %.lr.ph, %.lr.ph.preheader
  %indvars.iv.unr = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next.1, %.lr.ph ]
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %.preheader99, label %.lr.ph.epil

.lr.ph.epil:                                      ; preds = %.preheader99.unr-lcssa
  %32 = getelementptr inbounds i32, ptr %11, i64 %indvars.iv.unr
  %33 = load i32, ptr %32, align 4, !tbaa !21
  %34 = sext i32 %33 to i64
  %35 = getelementptr inbounds i32, ptr %6, i64 %34
  %36 = load i32, ptr %35, align 4, !tbaa !21
  %37 = getelementptr inbounds i32, ptr %19, i64 %indvars.iv.unr
  store i32 %36, ptr %37, align 4, !tbaa !21
  %38 = getelementptr inbounds i32, ptr %8, i64 %34
  %39 = load i32, ptr %38, align 4, !tbaa !21
  store i32 %39, ptr %32, align 4, !tbaa !21
  br label %.preheader99

.preheader99:                                     ; preds = %.preheader99.unr-lcssa, %.lr.ph.epil
  br i1 %30, label %.lr.ph113.preheader, label %._crit_edge

.lr.ph113.preheader:                              ; preds = %.preheader99
  %wide.trip.count130 = zext nneg i32 %9 to i64
  br label %.lr.ph113

.lr.ph:                                           ; preds = %.lr.ph, %.lr.ph.preheader.new
  %indvars.iv = phi i64 [ 0, %.lr.ph.preheader.new ], [ %indvars.iv.next.1, %.lr.ph ]
  %niter = phi i64 [ 0, %.lr.ph.preheader.new ], [ %niter.next.1, %.lr.ph ]
  %40 = getelementptr inbounds i32, ptr %11, i64 %indvars.iv
  %41 = load i32, ptr %40, align 4, !tbaa !21
  %42 = sext i32 %41 to i64
  %43 = getelementptr inbounds i32, ptr %6, i64 %42
  %44 = load i32, ptr %43, align 4, !tbaa !21
  %45 = getelementptr inbounds i32, ptr %19, i64 %indvars.iv
  store i32 %44, ptr %45, align 4, !tbaa !21
  %46 = getelementptr inbounds i32, ptr %8, i64 %42
  %47 = load i32, ptr %46, align 4, !tbaa !21
  store i32 %47, ptr %40, align 4, !tbaa !21
  %indvars.iv.next = or disjoint i64 %indvars.iv, 1
  %48 = getelementptr inbounds i32, ptr %11, i64 %indvars.iv.next
  %49 = load i32, ptr %48, align 4, !tbaa !21
  %50 = sext i32 %49 to i64
  %51 = getelementptr inbounds i32, ptr %6, i64 %50
  %52 = load i32, ptr %51, align 4, !tbaa !21
  %53 = getelementptr inbounds i32, ptr %19, i64 %indvars.iv.next
  store i32 %52, ptr %53, align 4, !tbaa !21
  %54 = getelementptr inbounds i32, ptr %8, i64 %50
  %55 = load i32, ptr %54, align 4, !tbaa !21
  store i32 %55, ptr %48, align 4, !tbaa !21
  %indvars.iv.next.1 = add nuw nsw i64 %indvars.iv, 2
  %niter.next.1 = add i64 %niter, 2
  %niter.ncmp.1 = icmp eq i64 %niter.next.1, %unroll_iter
  br i1 %niter.ncmp.1, label %.preheader99.unr-lcssa, label %.lr.ph, !llvm.loop !22

.lr.ph113:                                        ; preds = %.lr.ph113.preheader, %130
  %indvars.iv127 = phi i64 [ 0, %.lr.ph113.preheader ], [ %indvars.iv.next128, %130 ]
  %.090111 = phi i32 [ 0, %.lr.ph113.preheader ], [ %.191, %130 ]
  %56 = getelementptr inbounds i32, ptr %13, i64 %indvars.iv127
  %57 = load i32, ptr %56, align 4, !tbaa !21
  %indvars.iv.next128 = add nuw nsw i64 %indvars.iv127, 1
  %58 = getelementptr inbounds i32, ptr %13, i64 %indvars.iv.next128
  %59 = load i32, ptr %58, align 4, !tbaa !21
  %60 = getelementptr inbounds i32, ptr %11, i64 %indvars.iv127
  %61 = load i32, ptr %60, align 4, !tbaa !21
  %62 = icmp eq i32 %61, -1
  br i1 %62, label %.preheader, label %74

.preheader:                                       ; preds = %.lr.ph113
  %63 = icmp slt i32 %57, %59
  br i1 %63, label %.lr.ph109.preheader, label %.loopexit

.lr.ph109.preheader:                              ; preds = %.preheader
  %64 = sext i32 %57 to i64
  %wide.trip.count125 = sext i32 %59 to i64
  %65 = sub nsw i64 %wide.trip.count125, %64
  %min.iters.check = icmp ult i64 %65, 8
  br i1 %min.iters.check, label %.lr.ph109.preheader136, label %vector.ph

vector.ph:                                        ; preds = %.lr.ph109.preheader
  %n.vec = and i64 %65, -8
  %ind.end = add nsw i64 %n.vec, %64
  %invariant.gep = getelementptr i32, ptr %17, i64 %64
  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 ], [ %67, %vector.body ]
  %vec.phi134 = phi <4 x i32> [ zeroinitializer, %vector.ph ], [ %68, %vector.body ]
  %gep = getelementptr i32, ptr %invariant.gep, i64 %index
  %66 = getelementptr inbounds i8, ptr %gep, i64 16
  %wide.load = load <4 x i32>, ptr %gep, align 4, !tbaa !21
  %wide.load135 = load <4 x i32>, ptr %66, align 4, !tbaa !21
  %67 = add <4 x i32> %wide.load, %vec.phi
  %68 = add <4 x i32> %wide.load135, %vec.phi134
  %index.next = add nuw i64 %index, 8
  %69 = icmp eq i64 %index.next, %n.vec
  br i1 %69, label %middle.block, label %vector.body, !llvm.loop !24

middle.block:                                     ; preds = %vector.body
  %bin.rdx = add <4 x i32> %68, %67
  %70 = tail call i32 @llvm.vector.reduce.add.v4i32(<4 x i32> %bin.rdx)
  %cmp.n = icmp eq i64 %65, %n.vec
  br i1 %cmp.n, label %.loopexit, label %.lr.ph109.preheader136

.lr.ph109.preheader136:                           ; preds = %middle.block, %.lr.ph109.preheader
  %indvars.iv122.ph = phi i64 [ %64, %.lr.ph109.preheader ], [ %ind.end, %middle.block ]
  %.092107.ph = phi i32 [ 0, %.lr.ph109.preheader ], [ %70, %middle.block ]
  br label %.lr.ph109

.lr.ph109:                                        ; preds = %.lr.ph109.preheader136, %.lr.ph109
  %indvars.iv122 = phi i64 [ %indvars.iv.next123, %.lr.ph109 ], [ %indvars.iv122.ph, %.lr.ph109.preheader136 ]
  %.092107 = phi i32 [ %73, %.lr.ph109 ], [ %.092107.ph, %.lr.ph109.preheader136 ]
  %71 = getelementptr inbounds i32, ptr %17, i64 %indvars.iv122
  %72 = load i32, ptr %71, align 4, !tbaa !21
  %73 = add nsw i32 %72, %.092107
  %indvars.iv.next123 = add nsw i64 %indvars.iv122, 1
  %exitcond126.not = icmp eq i64 %indvars.iv.next123, %wide.trip.count125
  br i1 %exitcond126.not, label %.loopexit, label %.lr.ph109, !llvm.loop !27

74:                                               ; preds = %.lr.ph113
  %75 = getelementptr inbounds i32, ptr %19, i64 %indvars.iv127
  %76 = load i32, ptr %75, align 4, !tbaa !21
  %77 = icmp slt i32 %57, %59
  br i1 %77, label %.lr.ph105.preheader, label %.loopexit

.lr.ph105.preheader:                              ; preds = %74
  %78 = sext i32 %57 to i64
  %wide.trip.count120 = sext i32 %59 to i64
  %79 = sub nsw i64 %wide.trip.count120, %78
  %xtraiter140 = and i64 %79, 1
  %80 = add nsw i64 %wide.trip.count120, -1
  %81 = icmp eq i64 %80, %78
  br i1 %81, label %.loopexit.loopexit137.unr-lcssa, label %.lr.ph105.preheader.new

.lr.ph105.preheader.new:                          ; preds = %.lr.ph105.preheader
  %unroll_iter144 = and i64 %79, -2
  br label %.lr.ph105

.lr.ph105:                                        ; preds = %.lr.ph105, %.lr.ph105.preheader.new
  %indvars.iv117 = phi i64 [ %78, %.lr.ph105.preheader.new ], [ %indvars.iv.next118.1, %.lr.ph105 ]
  %.193103 = phi i32 [ 0, %.lr.ph105.preheader.new ], [ %.2.1, %.lr.ph105 ]
  %.094102 = phi i32 [ 0, %.lr.ph105.preheader.new ], [ %.195.1, %.lr.ph105 ]
  %niter145 = phi i64 [ 0, %.lr.ph105.preheader.new ], [ %niter145.next.1, %.lr.ph105 ]
  %82 = getelementptr inbounds i32, ptr %15, i64 %indvars.iv117
  %83 = load i32, ptr %82, align 4, !tbaa !21
  %84 = sext i32 %83 to i64
  %85 = getelementptr inbounds i32, ptr %19, i64 %84
  %86 = load i32, ptr %85, align 4, !tbaa !21
  %87 = icmp eq i32 %76, %86
  %88 = getelementptr inbounds i32, ptr %17, i64 %indvars.iv117
  %89 = load i32, ptr %88, align 4, !tbaa !21
  %90 = select i1 %87, i32 0, i32 %89
  %.195 = add nsw i32 %.094102, %90
  %91 = select i1 %87, i32 %89, i32 0
  %.2 = add nsw i32 %.193103, %91
  %indvars.iv.next118 = add nsw i64 %indvars.iv117, 1
  %92 = getelementptr inbounds i32, ptr %15, i64 %indvars.iv.next118
  %93 = load i32, ptr %92, align 4, !tbaa !21
  %94 = sext i32 %93 to i64
  %95 = getelementptr inbounds i32, ptr %19, i64 %94
  %96 = load i32, ptr %95, align 4, !tbaa !21
  %97 = icmp eq i32 %76, %96
  %98 = getelementptr inbounds i32, ptr %17, i64 %indvars.iv.next118
  %99 = load i32, ptr %98, align 4, !tbaa !21
  %100 = select i1 %97, i32 0, i32 %99
  %.195.1 = add nsw i32 %.195, %100
  %101 = select i1 %97, i32 %99, i32 0
  %.2.1 = add nsw i32 %.2, %101
  %indvars.iv.next118.1 = add nsw i64 %indvars.iv117, 2
  %niter145.next.1 = add i64 %niter145, 2
  %niter145.ncmp.1 = icmp eq i64 %niter145.next.1, %unroll_iter144
  br i1 %niter145.ncmp.1, label %.loopexit.loopexit137.unr-lcssa, label %.lr.ph105, !llvm.loop !28

.loopexit.loopexit137.unr-lcssa:                  ; preds = %.lr.ph105, %.lr.ph105.preheader
  %.195.lcssa.ph = phi i32 [ poison, %.lr.ph105.preheader ], [ %.195.1, %.lr.ph105 ]
  %.2.lcssa.ph = phi i32 [ poison, %.lr.ph105.preheader ], [ %.2.1, %.lr.ph105 ]
  %indvars.iv117.unr = phi i64 [ %78, %.lr.ph105.preheader ], [ %indvars.iv.next118.1, %.lr.ph105 ]
  %.193103.unr = phi i32 [ 0, %.lr.ph105.preheader ], [ %.2.1, %.lr.ph105 ]
  %.094102.unr = phi i32 [ 0, %.lr.ph105.preheader ], [ %.195.1, %.lr.ph105 ]
  %lcmp.mod141.not = icmp eq i64 %xtraiter140, 0
  br i1 %lcmp.mod141.not, label %.loopexit, label %.lr.ph105.epil

.lr.ph105.epil:                                   ; preds = %.loopexit.loopexit137.unr-lcssa
  %102 = getelementptr inbounds i32, ptr %15, i64 %indvars.iv117.unr
  %103 = load i32, ptr %102, align 4, !tbaa !21
  %104 = sext i32 %103 to i64
  %105 = getelementptr inbounds i32, ptr %19, i64 %104
  %106 = load i32, ptr %105, align 4, !tbaa !21
  %107 = icmp eq i32 %76, %106
  %108 = getelementptr inbounds i32, ptr %17, i64 %indvars.iv117.unr
  %109 = load i32, ptr %108, align 4, !tbaa !21
  %110 = select i1 %107, i32 0, i32 %109
  %.195.epil = add nsw i32 %.094102.unr, %110
  %111 = select i1 %107, i32 %109, i32 0
  %.2.epil = add nsw i32 %.193103.unr, %111
  br label %.loopexit

.loopexit:                                        ; preds = %.lr.ph105.epil, %.loopexit.loopexit137.unr-lcssa, %.lr.ph109, %middle.block, %74, %.preheader
  %.296 = phi i32 [ 0, %.preheader ], [ 0, %74 ], [ 0, %middle.block ], [ 0, %.lr.ph109 ], [ %.195.lcssa.ph, %.loopexit.loopexit137.unr-lcssa ], [ %.195.epil, %.lr.ph105.epil ]
  %.3 = phi i32 [ 0, %.preheader ], [ 0, %74 ], [ %70, %middle.block ], [ %73, %.lr.ph109 ], [ %.2.lcssa.ph, %.loopexit.loopexit137.unr-lcssa ], [ %.2.epil, %.lr.ph105.epil ]
  %112 = getelementptr inbounds i32, ptr %21, i64 %indvars.iv127
  store i32 %.3, ptr %112, align 4, !tbaa !21
  %113 = getelementptr inbounds i32, ptr %23, i64 %indvars.iv127
  store i32 %.296, ptr %113, align 4, !tbaa !21
  %114 = icmp sgt i32 %.296, 0
  %115 = icmp eq i32 %57, %59
  %or.cond = select i1 %114, i1 true, i1 %115
  br i1 %or.cond, label %116, label %130

116:                                              ; preds = %.loopexit
  %117 = getelementptr inbounds i32, ptr %27, i64 %indvars.iv127
  %118 = load i32, ptr %117, align 4, !tbaa !21
  %119 = icmp eq i32 %118, -1
  br i1 %119, label %125, label %120

120:                                              ; preds = %116
  %121 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.13, i32 noundef 200, ptr noundef nonnull @.str.1)
  %122 = load i32, ptr %117, align 4, !tbaa !21
  %123 = icmp eq i32 %122, -1
  br i1 %123, label %125, label %124

124:                                              ; preds = %120
  tail call void @__assert_fail(ptr noundef nonnull @.str.14, ptr noundef nonnull @.str.1, i32 noundef 200, ptr noundef nonnull @__PRETTY_FUNCTION__.libmetis__Project2WayPartition) #6
  unreachable

125:                                              ; preds = %120, %116
  %126 = sext i32 %.090111 to i64
  %127 = getelementptr inbounds i32, ptr %29, i64 %126
  %128 = trunc nuw nsw i64 %indvars.iv127 to i32
  store i32 %128, ptr %127, align 4, !tbaa !21
  %129 = add nsw i32 %.090111, 1
  store i32 %.090111, ptr %117, align 4, !tbaa !21
  br label %130

130:                                              ; preds = %.loopexit, %125
  %.191 = phi i32 [ %129, %125 ], [ %.090111, %.loopexit ]
  %exitcond131.not = icmp eq i64 %indvars.iv.next128, %wide.trip.count130
  br i1 %exitcond131.not, label %._crit_edge, label %.lr.ph113, !llvm.loop !29

._crit_edge:                                      ; preds = %130, %2, %.preheader99
  %.090.lcssa = phi i32 [ 0, %.preheader99 ], [ 0, %2 ], [ %.191, %130 ]
  %131 = getelementptr inbounds i8, ptr %4, i64 112
  %132 = load i32, ptr %131, align 8, !tbaa !30
  %133 = getelementptr inbounds i8, ptr %1, i64 112
  store i32 %132, ptr %133, align 8, !tbaa !30
  %134 = getelementptr inbounds i8, ptr %1, i64 136
  store i32 %.090.lcssa, ptr %134, align 8, !tbaa !31
  %135 = getelementptr inbounds i8, ptr %1, i64 8
  %136 = load i32, ptr %135, align 8, !tbaa !32
  %137 = shl nsw i32 %136, 1
  %138 = sext i32 %137 to i64
  %139 = getelementptr inbounds i8, ptr %4, i64 128
  %140 = load ptr, ptr %139, align 8, !tbaa !33
  %141 = getelementptr inbounds i8, ptr %1, i64 128
  %142 = load ptr, ptr %141, align 8, !tbaa !33
  %143 = tail call ptr @libmetis__icopy(i64 noundef %138, ptr noundef %140, ptr noundef %142) #5
  tail call void @libmetis__FreeGraph(ptr noundef nonnull %3) #5
  store ptr null, ptr %3, align 8, !tbaa !5
  ret void
}

; Function Attrs: nounwind uwtable
declare dso_local void @libmetis__Allocate2WayPartitionMemory(ptr noundef, ptr noundef) local_unnamed_addr #2

declare ptr @libmetis__iset(i64 noundef, i32 noundef, ptr noundef) local_unnamed_addr #3

declare ptr @libmetis__icopy(i64 noundef, ptr noundef, ptr noundef) local_unnamed_addr #3

declare void @libmetis__FreeGraph(ptr noundef) local_unnamed_addr #3

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

attributes #0 = { 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 #1 = { noreturn 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 #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 = { "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 nosync nounwind speculatable willreturn memory(none) }
attributes #5 = { nounwind }
attributes #6 = { noreturn nounwind }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !10, i64 200}
!6 = !{!"graph_t", !7, i64 0, !7, i64 4, !7, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !7, i64 72, !7, i64 76, !7, i64 80, !7, i64 84, !7, i64 88, !10, i64 96, !10, i64 104, !7, i64 112, !7, i64 116, !10, i64 120, !10, i64 128, !7, i64 136, !10, i64 144, !10, i64 152, !10, i64 160, !10, i64 168, !10, i64 176, !10, i64 184, !10, i64 192, !10, i64 200, !10, i64 208}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!6, !10, i64 120}
!12 = !{!6, !10, i64 144}
!13 = !{!6, !7, i64 0}
!14 = !{!6, !10, i64 104}
!15 = !{!6, !10, i64 16}
!16 = !{!6, !10, i64 40}
!17 = !{!6, !10, i64 48}
!18 = !{!6, !10, i64 160}
!19 = !{!6, !10, i64 168}
!20 = !{!6, !10, i64 152}
!21 = !{!7, !7, i64 0}
!22 = distinct !{!22, !23}
!23 = !{!"llvm.loop.mustprogress"}
!24 = distinct !{!24, !23, !25, !26}
!25 = !{!"llvm.loop.isvectorized", i32 1}
!26 = !{!"llvm.loop.unroll.runtime.disable"}
!27 = distinct !{!27, !23, !26, !25}
!28 = distinct !{!28, !23}
!29 = distinct !{!29, !23}
!30 = !{!6, !7, i64 112}
!31 = !{!6, !7, i64 136}
!32 = !{!6, !7, i64 8}
!33 = !{!6, !10, i64 128}


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