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

; 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.ctrl_t = type { i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, ptr, i32, i32, float, ptr, ptr, ptr, float, double, double, double, double, double, double, double, double, double, double, double, double, ptr, i64, i64, i64, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
%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 = external hidden unnamed_addr constant [64 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [143 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [26 x i8], align 1
@__PRETTY_FUNCTION__.libmetis__RefineKWay = external hidden unnamed_addr constant [58 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [124 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [102 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local void @libmetis__RefineKWay(ptr noundef %0, ptr noundef %1, ptr noundef %2) #0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  store ptr %2, ptr %6, align 8, !tbaa !5
  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
  %11 = load ptr, ptr %4, align 8, !tbaa !5
  %12 = getelementptr inbounds %struct.ctrl_t, ptr %11, i32 0, i32 10
  %13 = load i32, ptr %12, align 8, !tbaa !9
  store i32 %13, ptr %9, align 4, !tbaa !15
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #4
  %14 = load ptr, ptr %4, align 8, !tbaa !5
  %15 = getelementptr inbounds %struct.ctrl_t, ptr %14, i32 0, i32 2
  %16 = load i32, ptr %15, align 8, !tbaa !16
  %17 = and i32 %16, 2
  %18 = icmp ne i32 %17, 0
  br i1 %18, label %19, label %25

19:                                               ; preds = %3
  %20 = call double @gk_CPUSeconds()
  %21 = load ptr, ptr %4, align 8, !tbaa !5
  %22 = getelementptr inbounds %struct.ctrl_t, ptr %21, i32 0, i32 32
  %23 = load double, ptr %22, align 8, !tbaa !17
  %24 = fsub double %23, %20
  store double %24, ptr %22, align 8, !tbaa !17
  br label %25

25:                                               ; preds = %19, %3
  %26 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %26, ptr %10, align 8, !tbaa !5
  store i32 0, ptr %8, align 4, !tbaa !15
  br label %27

27:                                               ; preds = %32, %25
  %28 = load ptr, ptr %10, align 8, !tbaa !5
  %29 = load ptr, ptr %5, align 8, !tbaa !5
  %30 = icmp ne ptr %28, %29
  br i1 %30, label %31, label %38

31:                                               ; preds = %27
  br label %32

32:                                               ; preds = %31
  %33 = load ptr, ptr %10, align 8, !tbaa !5
  %34 = getelementptr inbounds %struct.graph_t, ptr %33, i32 0, i32 30
  %35 = load ptr, ptr %34, align 8, !tbaa !18
  store ptr %35, ptr %10, align 8, !tbaa !5
  %36 = load i32, ptr %8, align 4, !tbaa !15
  %37 = add nsw i32 %36, 1
  store i32 %37, ptr %8, align 4, !tbaa !15
  br label %27, !llvm.loop !20

38:                                               ; preds = %27
  %39 = load ptr, ptr %4, align 8, !tbaa !5
  %40 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__ComputeKWayPartitionParams(ptr noundef %39, ptr noundef %40)
  %41 = load ptr, ptr %4, align 8, !tbaa !5
  %42 = getelementptr inbounds %struct.ctrl_t, ptr %41, i32 0, i32 9
  %43 = load i32, ptr %42, align 4, !tbaa !22
  %44 = icmp ne i32 %43, 0
  br i1 %44, label %45, label %48

45:                                               ; preds = %38
  %46 = load ptr, ptr %4, align 8, !tbaa !5
  %47 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__EliminateSubDomainEdges(ptr noundef %46, ptr noundef %47)
  br label %48

48:                                               ; preds = %45, %38
  %49 = load i32, ptr %9, align 4, !tbaa !15
  %50 = icmp ne i32 %49, 0
  br i1 %50, label %51, label %77

51:                                               ; preds = %48
  %52 = load ptr, ptr %6, align 8, !tbaa !5
  %53 = load ptr, ptr %6, align 8, !tbaa !5
  %54 = getelementptr inbounds %struct.graph_t, ptr %53, i32 0, i32 19
  %55 = load ptr, ptr %54, align 8, !tbaa !23
  %56 = call i32 @libmetis__FindPartitionInducedComponents(ptr noundef %52, ptr noundef %55, ptr noundef null, ptr noundef null)
  %57 = load ptr, ptr %4, align 8, !tbaa !5
  %58 = getelementptr inbounds %struct.ctrl_t, ptr %57, i32 0, i32 21
  %59 = load i32, ptr %58, align 4, !tbaa !24
  %60 = icmp sgt i32 %56, %59
  br i1 %60, label %61, label %77

61:                                               ; preds = %51
  %62 = load ptr, ptr %4, align 8, !tbaa !5
  %63 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__EliminateComponents(ptr noundef %62, ptr noundef %63)
  %64 = load ptr, ptr %4, align 8, !tbaa !5
  %65 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__ComputeKWayBoundary(ptr noundef %64, ptr noundef %65, i32 noundef 2)
  %66 = load ptr, ptr %4, align 8, !tbaa !5
  %67 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__Greedy_KWayOptimize(ptr noundef %66, ptr noundef %67, i32 noundef 5, float noundef 0.000000e+00, i32 noundef 2)
  %68 = load ptr, ptr %4, align 8, !tbaa !5
  %69 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__ComputeKWayBoundary(ptr noundef %68, ptr noundef %69, i32 noundef 1)
  %70 = load ptr, ptr %4, align 8, !tbaa !5
  %71 = load ptr, ptr %6, align 8, !tbaa !5
  %72 = load ptr, ptr %4, align 8, !tbaa !5
  %73 = getelementptr inbounds %struct.ctrl_t, ptr %72, i32 0, i32 17
  %74 = load i32, ptr %73, align 4, !tbaa !25
  call void @libmetis__Greedy_KWayOptimize(ptr noundef %70, ptr noundef %71, i32 noundef %74, float noundef 0.000000e+00, i32 noundef 1)
  %75 = load ptr, ptr %4, align 8, !tbaa !5
  %76 = getelementptr inbounds %struct.ctrl_t, ptr %75, i32 0, i32 10
  store i32 0, ptr %76, align 8, !tbaa !9
  br label %77

77:                                               ; preds = %61, %51, %48
  store i32 0, ptr %7, align 4, !tbaa !15
  br label %78

78:                                               ; preds = %229, %77
  %79 = load ptr, ptr %4, align 8, !tbaa !5
  %80 = getelementptr inbounds %struct.ctrl_t, ptr %79, i32 0, i32 9
  %81 = load i32, ptr %80, align 4, !tbaa !22
  %82 = icmp ne i32 %81, 0
  br i1 %82, label %83, label %91

83:                                               ; preds = %78
  %84 = load i32, ptr %7, align 4, !tbaa !15
  %85 = load i32, ptr %8, align 4, !tbaa !15
  %86 = sdiv i32 %85, 2
  %87 = icmp eq i32 %84, %86
  br i1 %87, label %88, label %91

88:                                               ; preds = %83
  %89 = load ptr, ptr %4, align 8, !tbaa !5
  %90 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__EliminateSubDomainEdges(ptr noundef %89, ptr noundef %90)
  br label %91

91:                                               ; preds = %88, %83, %78
  %92 = load ptr, ptr %4, align 8, !tbaa !5
  %93 = getelementptr inbounds %struct.ctrl_t, ptr %92, i32 0, i32 2
  %94 = load i32, ptr %93, align 8, !tbaa !16
  %95 = and i32 %94, 2
  %96 = icmp ne i32 %95, 0
  br i1 %96, label %97, label %103

97:                                               ; preds = %91
  %98 = call double @gk_CPUSeconds()
  %99 = load ptr, ptr %4, align 8, !tbaa !5
  %100 = getelementptr inbounds %struct.ctrl_t, ptr %99, i32 0, i32 33
  %101 = load double, ptr %100, align 8, !tbaa !26
  %102 = fsub double %101, %98
  store double %102, ptr %100, align 8, !tbaa !26
  br label %103

103:                                              ; preds = %97, %91
  %104 = load i32, ptr %7, align 4, !tbaa !15
  %105 = mul nsw i32 2, %104
  %106 = load i32, ptr %8, align 4, !tbaa !15
  %107 = icmp sge i32 %105, %106
  br i1 %107, label %108, label %120

108:                                              ; preds = %103
  %109 = load ptr, ptr %4, align 8, !tbaa !5
  %110 = load ptr, ptr %6, align 8, !tbaa !5
  %111 = call i32 @libmetis__IsBalanced(ptr noundef %109, ptr noundef %110, float noundef 0x3F947AE140000000)
  %112 = icmp ne i32 %111, 0
  br i1 %112, label %120, label %113

113:                                              ; preds = %108
  %114 = load ptr, ptr %4, align 8, !tbaa !5
  %115 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__ComputeKWayBoundary(ptr noundef %114, ptr noundef %115, i32 noundef 2)
  %116 = load ptr, ptr %4, align 8, !tbaa !5
  %117 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__Greedy_KWayOptimize(ptr noundef %116, ptr noundef %117, i32 noundef 1, float noundef 0.000000e+00, i32 noundef 2)
  %118 = load ptr, ptr %4, align 8, !tbaa !5
  %119 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__ComputeKWayBoundary(ptr noundef %118, ptr noundef %119, i32 noundef 1)
  br label %120

120:                                              ; preds = %113, %108, %103
  %121 = load ptr, ptr %4, align 8, !tbaa !5
  %122 = load ptr, ptr %6, align 8, !tbaa !5
  %123 = load ptr, ptr %4, align 8, !tbaa !5
  %124 = getelementptr inbounds %struct.ctrl_t, ptr %123, i32 0, i32 17
  %125 = load i32, ptr %124, align 4, !tbaa !25
  call void @libmetis__Greedy_KWayOptimize(ptr noundef %121, ptr noundef %122, i32 noundef %125, float noundef 5.000000e+00, i32 noundef 1)
  %126 = load ptr, ptr %4, align 8, !tbaa !5
  %127 = getelementptr inbounds %struct.ctrl_t, ptr %126, i32 0, i32 2
  %128 = load i32, ptr %127, align 8, !tbaa !16
  %129 = and i32 %128, 2
  %130 = icmp ne i32 %129, 0
  br i1 %130, label %131, label %137

131:                                              ; preds = %120
  %132 = call double @gk_CPUSeconds()
  %133 = load ptr, ptr %4, align 8, !tbaa !5
  %134 = getelementptr inbounds %struct.ctrl_t, ptr %133, i32 0, i32 33
  %135 = load double, ptr %134, align 8, !tbaa !26
  %136 = fadd double %135, %132
  store double %136, ptr %134, align 8, !tbaa !26
  br label %137

137:                                              ; preds = %131, %120
  %138 = load i32, ptr %9, align 4, !tbaa !15
  %139 = icmp ne i32 %138, 0
  br i1 %139, label %140, label %180

140:                                              ; preds = %137
  %141 = load i32, ptr %7, align 4, !tbaa !15
  %142 = load i32, ptr %8, align 4, !tbaa !15
  %143 = sdiv i32 %142, 2
  %144 = icmp eq i32 %141, %143
  br i1 %144, label %145, label %180

145:                                              ; preds = %140
  %146 = load ptr, ptr %6, align 8, !tbaa !5
  %147 = load ptr, ptr %6, align 8, !tbaa !5
  %148 = getelementptr inbounds %struct.graph_t, ptr %147, i32 0, i32 19
  %149 = load ptr, ptr %148, align 8, !tbaa !23
  %150 = call i32 @libmetis__FindPartitionInducedComponents(ptr noundef %146, ptr noundef %149, ptr noundef null, ptr noundef null)
  %151 = load ptr, ptr %4, align 8, !tbaa !5
  %152 = getelementptr inbounds %struct.ctrl_t, ptr %151, i32 0, i32 21
  %153 = load i32, ptr %152, align 4, !tbaa !24
  %154 = icmp sgt i32 %150, %153
  br i1 %154, label %155, label %179

155:                                              ; preds = %145
  %156 = load ptr, ptr %4, align 8, !tbaa !5
  %157 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__EliminateComponents(ptr noundef %156, ptr noundef %157)
  %158 = load ptr, ptr %4, align 8, !tbaa !5
  %159 = load ptr, ptr %6, align 8, !tbaa !5
  %160 = call i32 @libmetis__IsBalanced(ptr noundef %158, ptr noundef %159, float noundef 0x3F947AE140000000)
  %161 = icmp ne i32 %160, 0
  br i1 %161, label %178, label %162

162:                                              ; preds = %155
  %163 = load ptr, ptr %4, align 8, !tbaa !5
  %164 = getelementptr inbounds %struct.ctrl_t, ptr %163, i32 0, i32 10
  store i32 1, ptr %164, align 8, !tbaa !9
  %165 = load ptr, ptr %4, align 8, !tbaa !5
  %166 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__ComputeKWayBoundary(ptr noundef %165, ptr noundef %166, i32 noundef 2)
  %167 = load ptr, ptr %4, align 8, !tbaa !5
  %168 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__Greedy_KWayOptimize(ptr noundef %167, ptr noundef %168, i32 noundef 5, float noundef 0.000000e+00, i32 noundef 2)
  %169 = load ptr, ptr %4, align 8, !tbaa !5
  %170 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__ComputeKWayBoundary(ptr noundef %169, ptr noundef %170, i32 noundef 1)
  %171 = load ptr, ptr %4, align 8, !tbaa !5
  %172 = load ptr, ptr %6, align 8, !tbaa !5
  %173 = load ptr, ptr %4, align 8, !tbaa !5
  %174 = getelementptr inbounds %struct.ctrl_t, ptr %173, i32 0, i32 17
  %175 = load i32, ptr %174, align 4, !tbaa !25
  call void @libmetis__Greedy_KWayOptimize(ptr noundef %171, ptr noundef %172, i32 noundef %175, float noundef 0.000000e+00, i32 noundef 1)
  %176 = load ptr, ptr %4, align 8, !tbaa !5
  %177 = getelementptr inbounds %struct.ctrl_t, ptr %176, i32 0, i32 10
  store i32 0, ptr %177, align 8, !tbaa !9
  br label %178

178:                                              ; preds = %162, %155
  br label %179

179:                                              ; preds = %178, %145
  br label %180

180:                                              ; preds = %179, %140, %137
  %181 = load ptr, ptr %6, align 8, !tbaa !5
  %182 = load ptr, ptr %5, align 8, !tbaa !5
  %183 = icmp eq ptr %181, %182
  br i1 %183, label %184, label %185

184:                                              ; preds = %180
  br label %232

185:                                              ; preds = %180
  %186 = load ptr, ptr %6, align 8, !tbaa !5
  %187 = getelementptr inbounds %struct.graph_t, ptr %186, i32 0, i32 30
  %188 = load ptr, ptr %187, align 8, !tbaa !18
  store ptr %188, ptr %6, align 8, !tbaa !5
  %189 = load ptr, ptr %4, align 8, !tbaa !5
  %190 = getelementptr inbounds %struct.ctrl_t, ptr %189, i32 0, i32 2
  %191 = load i32, ptr %190, align 8, !tbaa !16
  %192 = and i32 %191, 2
  %193 = icmp ne i32 %192, 0
  br i1 %193, label %194, label %200

194:                                              ; preds = %185
  %195 = call double @gk_CPUSeconds()
  %196 = load ptr, ptr %4, align 8, !tbaa !5
  %197 = getelementptr inbounds %struct.ctrl_t, ptr %196, i32 0, i32 34
  %198 = load double, ptr %197, align 8, !tbaa !27
  %199 = fsub double %198, %195
  store double %199, ptr %197, align 8, !tbaa !27
  br label %200

200:                                              ; preds = %194, %185
  %201 = load ptr, ptr %6, align 8, !tbaa !5
  %202 = getelementptr inbounds %struct.graph_t, ptr %201, i32 0, i32 4
  %203 = load ptr, ptr %202, align 8, !tbaa !28
  %204 = icmp ne ptr %203, null
  br i1 %204, label %214, label %205

205:                                              ; preds = %200
  %206 = call i32 (ptr, ...) @printf(ptr noundef @.str, i32 noundef 87, ptr noundef @.str.1)
  %207 = load ptr, ptr %6, align 8, !tbaa !5
  %208 = getelementptr inbounds %struct.graph_t, ptr %207, i32 0, i32 4
  %209 = load ptr, ptr %208, align 8, !tbaa !28
  %210 = icmp ne ptr %209, null
  br i1 %210, label %211, label %212

211:                                              ; preds = %205
  br label %213

212:                                              ; preds = %205
  call void @__assert_fail(ptr noundef @.str.2, ptr noundef @.str.1, i32 noundef 87, ptr noundef @__PRETTY_FUNCTION__.libmetis__RefineKWay) #5
  unreachable

213:                                              ; preds = %211
  br label %214

214:                                              ; preds = %213, %200
  %215 = load ptr, ptr %4, align 8, !tbaa !5
  %216 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__ProjectKWayPartition(ptr noundef %215, ptr noundef %216)
  %217 = load ptr, ptr %4, align 8, !tbaa !5
  %218 = getelementptr inbounds %struct.ctrl_t, ptr %217, i32 0, i32 2
  %219 = load i32, ptr %218, align 8, !tbaa !16
  %220 = and i32 %219, 2
  %221 = icmp ne i32 %220, 0
  br i1 %221, label %222, label %228

222:                                              ; preds = %214
  %223 = call double @gk_CPUSeconds()
  %224 = load ptr, ptr %4, align 8, !tbaa !5
  %225 = getelementptr inbounds %struct.ctrl_t, ptr %224, i32 0, i32 34
  %226 = load double, ptr %225, align 8, !tbaa !27
  %227 = fadd double %226, %223
  store double %227, ptr %225, align 8, !tbaa !27
  br label %228

228:                                              ; preds = %222, %214
  br label %229

229:                                              ; preds = %228
  %230 = load i32, ptr %7, align 4, !tbaa !15
  %231 = add nsw i32 %230, 1
  store i32 %231, ptr %7, align 4, !tbaa !15
  br label %78

232:                                              ; preds = %184
  %233 = load i32, ptr %9, align 4, !tbaa !15
  %234 = load ptr, ptr %4, align 8, !tbaa !5
  %235 = getelementptr inbounds %struct.ctrl_t, ptr %234, i32 0, i32 10
  store i32 %233, ptr %235, align 8, !tbaa !9
  %236 = load i32, ptr %9, align 4, !tbaa !15
  %237 = icmp ne i32 %236, 0
  br i1 %237, label %238, label %251

238:                                              ; preds = %232
  %239 = load ptr, ptr %6, align 8, !tbaa !5
  %240 = load ptr, ptr %6, align 8, !tbaa !5
  %241 = getelementptr inbounds %struct.graph_t, ptr %240, i32 0, i32 19
  %242 = load ptr, ptr %241, align 8, !tbaa !23
  %243 = call i32 @libmetis__FindPartitionInducedComponents(ptr noundef %239, ptr noundef %242, ptr noundef null, ptr noundef null)
  %244 = load ptr, ptr %4, align 8, !tbaa !5
  %245 = getelementptr inbounds %struct.ctrl_t, ptr %244, i32 0, i32 21
  %246 = load i32, ptr %245, align 4, !tbaa !24
  %247 = icmp sgt i32 %243, %246
  br i1 %247, label %248, label %251

248:                                              ; preds = %238
  %249 = load ptr, ptr %4, align 8, !tbaa !5
  %250 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__EliminateComponents(ptr noundef %249, ptr noundef %250)
  br label %251

251:                                              ; preds = %248, %238, %232
  %252 = load ptr, ptr %4, align 8, !tbaa !5
  %253 = load ptr, ptr %6, align 8, !tbaa !5
  %254 = call i32 @libmetis__IsBalanced(ptr noundef %252, ptr noundef %253, float noundef 0.000000e+00)
  %255 = icmp ne i32 %254, 0
  br i1 %255, label %268, label %256

256:                                              ; preds = %251
  %257 = load ptr, ptr %4, align 8, !tbaa !5
  %258 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__ComputeKWayBoundary(ptr noundef %257, ptr noundef %258, i32 noundef 2)
  %259 = load ptr, ptr %4, align 8, !tbaa !5
  %260 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__Greedy_KWayOptimize(ptr noundef %259, ptr noundef %260, i32 noundef 10, float noundef 0.000000e+00, i32 noundef 2)
  %261 = load ptr, ptr %4, align 8, !tbaa !5
  %262 = load ptr, ptr %6, align 8, !tbaa !5
  call void @libmetis__ComputeKWayBoundary(ptr noundef %261, ptr noundef %262, i32 noundef 1)
  %263 = load ptr, ptr %4, align 8, !tbaa !5
  %264 = load ptr, ptr %6, align 8, !tbaa !5
  %265 = load ptr, ptr %4, align 8, !tbaa !5
  %266 = getelementptr inbounds %struct.ctrl_t, ptr %265, i32 0, i32 17
  %267 = load i32, ptr %266, align 4, !tbaa !25
  call void @libmetis__Greedy_KWayOptimize(ptr noundef %263, ptr noundef %264, i32 noundef %267, float noundef 0.000000e+00, i32 noundef 1)
  br label %268

268:                                              ; preds = %256, %251
  %269 = load ptr, ptr %4, align 8, !tbaa !5
  %270 = getelementptr inbounds %struct.ctrl_t, ptr %269, i32 0, i32 10
  %271 = load i32, ptr %270, align 8, !tbaa !9
  %272 = icmp ne i32 %271, 0
  br i1 %272, label %273, label %298

273:                                              ; preds = %268
  %274 = load ptr, ptr %6, align 8, !tbaa !5
  %275 = load ptr, ptr %6, align 8, !tbaa !5
  %276 = getelementptr inbounds %struct.graph_t, ptr %275, i32 0, i32 19
  %277 = load ptr, ptr %276, align 8, !tbaa !23
  %278 = call i32 @libmetis__FindPartitionInducedComponents(ptr noundef %274, ptr noundef %277, ptr noundef null, ptr noundef null)
  %279 = load ptr, ptr %4, align 8, !tbaa !5
  %280 = getelementptr inbounds %struct.ctrl_t, ptr %279, i32 0, i32 21
  %281 = load i32, ptr %280, align 4, !tbaa !24
  %282 = icmp eq i32 %278, %281
  br i1 %282, label %297, label %283

283:                                              ; preds = %273
  %284 = call i32 (ptr, ...) @printf(ptr noundef @.str.3, i32 noundef 107, ptr noundef @.str.1)
  %285 = load ptr, ptr %6, align 8, !tbaa !5
  %286 = load ptr, ptr %6, align 8, !tbaa !5
  %287 = getelementptr inbounds %struct.graph_t, ptr %286, i32 0, i32 19
  %288 = load ptr, ptr %287, align 8, !tbaa !23
  %289 = call i32 @libmetis__FindPartitionInducedComponents(ptr noundef %285, ptr noundef %288, ptr noundef null, ptr noundef null)
  %290 = load ptr, ptr %4, align 8, !tbaa !5
  %291 = getelementptr inbounds %struct.ctrl_t, ptr %290, i32 0, i32 21
  %292 = load i32, ptr %291, align 4, !tbaa !24
  %293 = icmp eq i32 %289, %292
  br i1 %293, label %294, label %295

294:                                              ; preds = %283
  br label %296

295:                                              ; preds = %283
  call void @__assert_fail(ptr noundef @.str.4, ptr noundef @.str.1, i32 noundef 107, ptr noundef @__PRETTY_FUNCTION__.libmetis__RefineKWay) #5
  unreachable

296:                                              ; preds = %294
  br label %297

297:                                              ; preds = %296, %273
  br label %298

298:                                              ; preds = %297, %268
  %299 = load ptr, ptr %4, align 8, !tbaa !5
  %300 = getelementptr inbounds %struct.ctrl_t, ptr %299, i32 0, i32 2
  %301 = load i32, ptr %300, align 8, !tbaa !16
  %302 = and i32 %301, 2
  %303 = icmp ne i32 %302, 0
  br i1 %303, label %304, label %310

304:                                              ; preds = %298
  %305 = call double @gk_CPUSeconds()
  %306 = load ptr, ptr %4, align 8, !tbaa !5
  %307 = getelementptr inbounds %struct.ctrl_t, ptr %306, i32 0, i32 32
  %308 = load double, ptr %307, align 8, !tbaa !17
  %309 = fadd double %308, %305
  store double %309, ptr %307, align 8, !tbaa !17
  br label %310

310:                                              ; preds = %304, %298
  call void @llvm.lifetime.end.p0(i64 8, 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
  ret void
}

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

declare double @gk_CPUSeconds() #2

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

declare void @libmetis__EliminateSubDomainEdges(ptr noundef, ptr noundef) #2

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

declare void @libmetis__EliminateComponents(ptr noundef, ptr noundef) #2

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

declare void @libmetis__Greedy_KWayOptimize(ptr noundef, ptr noundef, i32 noundef, float noundef, i32 noundef) #2

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

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

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

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

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

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 #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, !11, i64 40}
!10 = !{!"ctrl_t", !11, i64 0, !11, i64 4, !11, i64 8, !11, i64 12, !11, i64 16, !11, i64 20, !11, i64 24, !11, i64 28, !11, i64 32, !11, i64 36, !11, i64 40, !11, i64 44, !11, i64 48, !11, i64 52, !11, i64 56, !11, i64 60, !11, i64 64, !11, i64 68, !11, i64 72, !6, i64 80, !11, i64 88, !11, i64 92, !12, i64 96, !6, i64 104, !6, i64 112, !6, i64 120, !12, i64 128, !13, i64 136, !13, i64 144, !13, i64 152, !13, i64 160, !13, i64 168, !13, i64 176, !13, i64 184, !13, i64 192, !13, i64 200, !13, i64 208, !13, i64 216, !13, i64 224, !6, i64 232, !14, i64 240, !14, i64 248, !14, i64 256, !6, i64 264, !6, i64 272, !6, i64 280, !6, i64 288, !6, i64 296, !6, i64 304, !6, i64 312, !6, i64 320}
!11 = !{!"int", !7, i64 0}
!12 = !{!"float", !7, i64 0}
!13 = !{!"double", !7, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = !{!11, !11, i64 0}
!16 = !{!10, !11, i64 8}
!17 = !{!10, !13, i64 176}
!18 = !{!19, !6, i64 208}
!19 = !{!"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}
!20 = distinct !{!20, !21}
!21 = !{!"llvm.loop.mustprogress"}
!22 = !{!10, !11, i64 36}
!23 = !{!19, !6, i64 120}
!24 = !{!10, !11, i64 92}
!25 = !{!10, !11, i64 68}
!26 = !{!10, !13, i64 184}
!27 = !{!10, !13, i64 192}
!28 = !{!19, !6, i64 24}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

@.str = external hidden unnamed_addr constant [64 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [143 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [26 x i8], align 1
@__PRETTY_FUNCTION__.libmetis__RefineKWay = external hidden unnamed_addr constant [58 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [124 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [102 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local void @libmetis__RefineKWay(ptr noundef %0, ptr noundef readnone %1, ptr noundef %2) local_unnamed_addr #0 {
  %4 = getelementptr inbounds i8, ptr %0, i64 40
  %5 = load i32, ptr %4, align 8, !tbaa !5
  %6 = getelementptr inbounds i8, ptr %0, i64 8
  %7 = load i32, ptr %6, align 8, !tbaa !14
  %8 = and i32 %7, 2
  %.not = icmp eq i32 %8, 0
  br i1 %.not, label %14, label %9

9:                                                ; preds = %3
  %10 = tail call double @gk_CPUSeconds() #4
  %11 = getelementptr inbounds i8, ptr %0, i64 176
  %12 = load double, ptr %11, align 8, !tbaa !15
  %13 = fsub double %12, %10
  store double %13, ptr %11, align 8, !tbaa !15
  br label %14

14:                                               ; preds = %9, %3
  %.not115136 = icmp eq ptr %2, %1
  br i1 %.not115136, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %14, %.lr.ph
  %.0138 = phi ptr [ %16, %.lr.ph ], [ %2, %14 ]
  %.0112137 = phi i32 [ %17, %.lr.ph ], [ 0, %14 ]
  %15 = getelementptr inbounds i8, ptr %.0138, i64 208
  %16 = load ptr, ptr %15, align 8, !tbaa !16
  %17 = add nuw nsw i32 %.0112137, 1
  %.not115 = icmp eq ptr %16, %1
  br i1 %.not115, label %._crit_edge, label %.lr.ph, !llvm.loop !18

._crit_edge:                                      ; preds = %.lr.ph, %14
  %.0112.lcssa = phi i32 [ 0, %14 ], [ %17, %.lr.ph ]
  tail call void @libmetis__ComputeKWayPartitionParams(ptr noundef %0, ptr noundef %2)
  %18 = getelementptr inbounds i8, ptr %0, i64 36
  %19 = load i32, ptr %18, align 4, !tbaa !20
  %.not116 = icmp eq i32 %19, 0
  br i1 %.not116, label %21, label %20

20:                                               ; preds = %._crit_edge
  tail call void @libmetis__EliminateSubDomainEdges(ptr noundef nonnull %0, ptr noundef %2) #4
  br label %21

21:                                               ; preds = %20, %._crit_edge
  %.not117 = icmp ne i32 %5, 0
  br i1 %.not117, label %22, label %32

22:                                               ; preds = %21
  %23 = getelementptr inbounds i8, ptr %2, i64 120
  %24 = load ptr, ptr %23, align 8, !tbaa !21
  %25 = tail call i32 @libmetis__FindPartitionInducedComponents(ptr noundef %2, ptr noundef %24, ptr noundef null, ptr noundef null) #4
  %26 = getelementptr inbounds i8, ptr %0, i64 92
  %27 = load i32, ptr %26, align 4, !tbaa !22
  %28 = icmp sgt i32 %25, %27
  br i1 %28, label %29, label %32

29:                                               ; preds = %22
  tail call void @libmetis__EliminateComponents(ptr noundef nonnull %0, ptr noundef nonnull %2) #4
  tail call void @libmetis__ComputeKWayBoundary(ptr noundef nonnull %0, ptr noundef nonnull %2, i32 noundef 2)
  tail call void @libmetis__Greedy_KWayOptimize(ptr noundef nonnull %0, ptr noundef nonnull %2, i32 noundef 5, float noundef 0.000000e+00, i32 noundef 2) #4
  tail call void @libmetis__ComputeKWayBoundary(ptr noundef nonnull %0, ptr noundef nonnull %2, i32 noundef 1)
  %30 = getelementptr inbounds i8, ptr %0, i64 68
  %31 = load i32, ptr %30, align 4, !tbaa !23
  tail call void @libmetis__Greedy_KWayOptimize(ptr noundef nonnull %0, ptr noundef nonnull %2, i32 noundef %31, float noundef 0.000000e+00, i32 noundef 1) #4
  store i32 0, ptr %4, align 8, !tbaa !5
  br label %32

32:                                               ; preds = %29, %22, %21
  %33 = lshr i32 %.0112.lcssa, 1
  %34 = getelementptr inbounds i8, ptr %0, i64 184
  %35 = getelementptr inbounds i8, ptr %0, i64 68
  %36 = getelementptr inbounds i8, ptr %0, i64 92
  %37 = getelementptr inbounds i8, ptr %0, i64 192
  br label %38

38:                                               ; preds = %98, %32
  %.0113 = phi i32 [ 0, %32 ], [ %99, %98 ]
  %.0111 = phi ptr [ %2, %32 ], [ %77, %98 ]
  %39 = load i32, ptr %18, align 4, !tbaa !20
  %.not118 = icmp ne i32 %39, 0
  %40 = icmp eq i32 %.0113, %33
  %or.cond = select i1 %.not118, i1 %40, i1 false
  br i1 %or.cond, label %41, label %42

41:                                               ; preds = %38
  tail call void @libmetis__EliminateSubDomainEdges(ptr noundef nonnull %0, ptr noundef %.0111) #4
  br label %42

42:                                               ; preds = %41, %38
  %43 = load i32, ptr %6, align 8, !tbaa !14
  %44 = and i32 %43, 2
  %.not119 = icmp eq i32 %44, 0
  br i1 %.not119, label %49, label %45

45:                                               ; preds = %42
  %46 = tail call double @gk_CPUSeconds() #4
  %47 = load double, ptr %34, align 8, !tbaa !24
  %48 = fsub double %47, %46
  store double %48, ptr %34, align 8, !tbaa !24
  br label %49

49:                                               ; preds = %45, %42
  %50 = shl nuw nsw i32 %.0113, 1
  %.not120 = icmp ult i32 %50, %.0112.lcssa
  br i1 %.not120, label %54, label %51

51:                                               ; preds = %49
  %52 = tail call i32 @libmetis__IsBalanced(ptr noundef nonnull %0, ptr noundef %.0111, float noundef 0x3F947AE140000000)
  %.not121 = icmp eq i32 %52, 0
  br i1 %.not121, label %53, label %54

53:                                               ; preds = %51
  tail call void @libmetis__ComputeKWayBoundary(ptr noundef nonnull %0, ptr noundef %.0111, i32 noundef 2)
  tail call void @libmetis__Greedy_KWayOptimize(ptr noundef nonnull %0, ptr noundef %.0111, i32 noundef 1, float noundef 0.000000e+00, i32 noundef 2) #4
  tail call void @libmetis__ComputeKWayBoundary(ptr noundef nonnull %0, ptr noundef %.0111, i32 noundef 1)
  br label %54

54:                                               ; preds = %53, %51, %49
  %55 = load i32, ptr %35, align 4, !tbaa !23
  tail call void @libmetis__Greedy_KWayOptimize(ptr noundef nonnull %0, ptr noundef %.0111, i32 noundef %55, float noundef 5.000000e+00, i32 noundef 1) #4
  %56 = load i32, ptr %6, align 8, !tbaa !14
  %57 = and i32 %56, 2
  %.not122 = icmp eq i32 %57, 0
  br i1 %.not122, label %62, label %58

58:                                               ; preds = %54
  %59 = tail call double @gk_CPUSeconds() #4
  %60 = load double, ptr %34, align 8, !tbaa !24
  %61 = fadd double %59, %60
  store double %61, ptr %34, align 8, !tbaa !24
  br label %62

62:                                               ; preds = %58, %54
  %or.cond133 = select i1 %.not117, i1 %40, i1 false
  br i1 %or.cond133, label %63, label %73

63:                                               ; preds = %62
  %64 = getelementptr inbounds i8, ptr %.0111, i64 120
  %65 = load ptr, ptr %64, align 8, !tbaa !21
  %66 = tail call i32 @libmetis__FindPartitionInducedComponents(ptr noundef %.0111, ptr noundef %65, ptr noundef null, ptr noundef null) #4
  %67 = load i32, ptr %36, align 4, !tbaa !22
  %68 = icmp sgt i32 %66, %67
  br i1 %68, label %69, label %73

69:                                               ; preds = %63
  tail call void @libmetis__EliminateComponents(ptr noundef nonnull %0, ptr noundef nonnull %.0111) #4
  %70 = tail call i32 @libmetis__IsBalanced(ptr noundef nonnull %0, ptr noundef nonnull %.0111, float noundef 0x3F947AE140000000)
  %.not123 = icmp eq i32 %70, 0
  br i1 %.not123, label %71, label %73

71:                                               ; preds = %69
  store i32 1, ptr %4, align 8, !tbaa !5
  tail call void @libmetis__ComputeKWayBoundary(ptr noundef nonnull %0, ptr noundef nonnull %.0111, i32 noundef 2)
  tail call void @libmetis__Greedy_KWayOptimize(ptr noundef nonnull %0, ptr noundef nonnull %.0111, i32 noundef 5, float noundef 0.000000e+00, i32 noundef 2) #4
  tail call void @libmetis__ComputeKWayBoundary(ptr noundef nonnull %0, ptr noundef nonnull %.0111, i32 noundef 1)
  %72 = load i32, ptr %35, align 4, !tbaa !23
  tail call void @libmetis__Greedy_KWayOptimize(ptr noundef nonnull %0, ptr noundef nonnull %.0111, i32 noundef %72, float noundef 0.000000e+00, i32 noundef 1) #4
  store i32 0, ptr %4, align 8, !tbaa !5
  br label %73

73:                                               ; preds = %63, %71, %69, %62
  %74 = icmp eq ptr %.0111, %1
  br i1 %74, label %100, label %75

75:                                               ; preds = %73
  %76 = getelementptr inbounds i8, ptr %.0111, i64 208
  %77 = load ptr, ptr %76, align 8, !tbaa !16
  %78 = load i32, ptr %6, align 8, !tbaa !14
  %79 = and i32 %78, 2
  %.not124 = icmp eq i32 %79, 0
  br i1 %.not124, label %84, label %80

80:                                               ; preds = %75
  %81 = tail call double @gk_CPUSeconds() #4
  %82 = load double, ptr %37, align 8, !tbaa !25
  %83 = fsub double %82, %81
  store double %83, ptr %37, align 8, !tbaa !25
  br label %84

84:                                               ; preds = %80, %75
  %85 = getelementptr inbounds i8, ptr %77, i64 24
  %86 = load ptr, ptr %85, align 8, !tbaa !26
  %.not125 = icmp eq ptr %86, null
  br i1 %.not125, label %87, label %91

87:                                               ; preds = %84
  %88 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str, i32 noundef 87, ptr noundef nonnull @.str.1)
  %89 = load ptr, ptr %85, align 8, !tbaa !26
  %.not126 = icmp eq ptr %89, null
  br i1 %.not126, label %90, label %91

90:                                               ; preds = %87
  tail call void @__assert_fail(ptr noundef nonnull @.str.2, ptr noundef nonnull @.str.1, i32 noundef 87, ptr noundef nonnull @__PRETTY_FUNCTION__.libmetis__RefineKWay) #5
  unreachable

91:                                               ; preds = %87, %84
  tail call void @libmetis__ProjectKWayPartition(ptr noundef nonnull %0, ptr noundef nonnull %77)
  %92 = load i32, ptr %6, align 8, !tbaa !14
  %93 = and i32 %92, 2
  %.not127 = icmp eq i32 %93, 0
  br i1 %.not127, label %98, label %94

94:                                               ; preds = %91
  %95 = tail call double @gk_CPUSeconds() #4
  %96 = load double, ptr %37, align 8, !tbaa !25
  %97 = fadd double %95, %96
  store double %97, ptr %37, align 8, !tbaa !25
  br label %98

98:                                               ; preds = %91, %94
  %99 = add nuw nsw i32 %.0113, 1
  br label %38

100:                                              ; preds = %73
  store i32 %5, ptr %4, align 8, !tbaa !5
  br i1 %.not117, label %101, label %108

101:                                              ; preds = %100
  %102 = getelementptr inbounds i8, ptr %.0111, i64 120
  %103 = load ptr, ptr %102, align 8, !tbaa !21
  %104 = tail call i32 @libmetis__FindPartitionInducedComponents(ptr noundef %.0111, ptr noundef %103, ptr noundef null, ptr noundef null) #4
  %105 = load i32, ptr %36, align 4, !tbaa !22
  %106 = icmp sgt i32 %104, %105
  br i1 %106, label %107, label %108

107:                                              ; preds = %101
  tail call void @libmetis__EliminateComponents(ptr noundef nonnull %0, ptr noundef nonnull %.0111) #4
  br label %108

108:                                              ; preds = %107, %101, %100
  %109 = tail call i32 @libmetis__IsBalanced(ptr noundef nonnull %0, ptr noundef %.0111, float noundef 0.000000e+00)
  %.not128 = icmp eq i32 %109, 0
  br i1 %.not128, label %110, label %112

110:                                              ; preds = %108
  tail call void @libmetis__ComputeKWayBoundary(ptr noundef nonnull %0, ptr noundef %.0111, i32 noundef 2)
  tail call void @libmetis__Greedy_KWayOptimize(ptr noundef nonnull %0, ptr noundef %.0111, i32 noundef 10, float noundef 0.000000e+00, i32 noundef 2) #4
  tail call void @libmetis__ComputeKWayBoundary(ptr noundef nonnull %0, ptr noundef %.0111, i32 noundef 1)
  %111 = load i32, ptr %35, align 4, !tbaa !23
  tail call void @libmetis__Greedy_KWayOptimize(ptr noundef nonnull %0, ptr noundef %.0111, i32 noundef %111, float noundef 0.000000e+00, i32 noundef 1) #4
  br label %112

112:                                              ; preds = %110, %108
  %113 = load i32, ptr %4, align 8, !tbaa !5
  %.not129 = icmp eq i32 %113, 0
  br i1 %.not129, label %127, label %114

114:                                              ; preds = %112
  %115 = getelementptr inbounds i8, ptr %.0111, i64 120
  %116 = load ptr, ptr %115, align 8, !tbaa !21
  %117 = tail call i32 @libmetis__FindPartitionInducedComponents(ptr noundef %.0111, ptr noundef %116, ptr noundef null, ptr noundef null) #4
  %118 = load i32, ptr %36, align 4, !tbaa !22
  %119 = icmp eq i32 %117, %118
  br i1 %119, label %127, label %120

120:                                              ; preds = %114
  %121 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.3, i32 noundef 107, ptr noundef nonnull @.str.1)
  %122 = load ptr, ptr %115, align 8, !tbaa !21
  %123 = tail call i32 @libmetis__FindPartitionInducedComponents(ptr noundef nonnull %.0111, ptr noundef %122, ptr noundef null, ptr noundef null) #4
  %124 = load i32, ptr %36, align 4, !tbaa !22
  %125 = icmp eq i32 %123, %124
  br i1 %125, label %127, label %126

126:                                              ; preds = %120
  tail call void @__assert_fail(ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.1, i32 noundef 107, ptr noundef nonnull @__PRETTY_FUNCTION__.libmetis__RefineKWay) #5
  unreachable

127:                                              ; preds = %114, %120, %112
  %128 = load i32, ptr %6, align 8, !tbaa !14
  %129 = and i32 %128, 2
  %.not130 = icmp eq i32 %129, 0
  br i1 %.not130, label %135, label %130

130:                                              ; preds = %127
  %131 = tail call double @gk_CPUSeconds() #4
  %132 = getelementptr inbounds i8, ptr %0, i64 176
  %133 = load double, ptr %132, align 8, !tbaa !15
  %134 = fadd double %131, %133
  store double %134, ptr %132, align 8, !tbaa !15
  br label %135

135:                                              ; preds = %130, %127
  ret void
}

declare double @gk_CPUSeconds() local_unnamed_addr #1

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

declare void @libmetis__EliminateSubDomainEdges(ptr noundef, ptr noundef) local_unnamed_addr #1

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

declare void @libmetis__EliminateComponents(ptr noundef, ptr noundef) local_unnamed_addr #1

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

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

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

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

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

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

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { 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 #3 = { 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 #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, !7, i64 40}
!6 = !{!"ctrl_t", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16, !7, i64 20, !7, i64 24, !7, i64 28, !7, i64 32, !7, i64 36, !7, i64 40, !7, i64 44, !7, i64 48, !7, i64 52, !7, i64 56, !7, i64 60, !7, i64 64, !7, i64 68, !7, i64 72, !10, i64 80, !7, i64 88, !7, i64 92, !11, i64 96, !10, i64 104, !10, i64 112, !10, i64 120, !11, i64 128, !12, i64 136, !12, i64 144, !12, i64 152, !12, i64 160, !12, i64 168, !12, i64 176, !12, i64 184, !12, i64 192, !12, i64 200, !12, i64 208, !12, i64 216, !12, i64 224, !10, i64 232, !13, i64 240, !13, i64 248, !13, i64 256, !10, i64 264, !10, i64 272, !10, i64 280, !10, i64 288, !10, i64 296, !10, i64 304, !10, i64 312, !10, i64 320}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"float", !8, i64 0}
!12 = !{!"double", !8, i64 0}
!13 = !{!"long", !8, i64 0}
!14 = !{!6, !7, i64 8}
!15 = !{!6, !12, i64 176}
!16 = !{!17, !10, i64 208}
!17 = !{!"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}
!18 = distinct !{!18, !19}
!19 = !{!"llvm.loop.mustprogress"}
!20 = !{!6, !7, i64 36}
!21 = !{!17, !10, i64 120}
!22 = !{!6, !7, i64 92}
!23 = !{!6, !7, i64 68}
!24 = !{!6, !12, i64 184}
!25 = !{!6, !12, i64 192}
!26 = !{!17, !10, i64 24}


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