; LLVM IR from jrl-umi3218/mc_rtc :: 3rd-party/qhull/src/libqhull (merge)

; 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.qhT = type { i32, i32, i32, i32, i32, i32, double, i32, i32, i32, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, i32, i32, ptr, i32, i32, ptr, i32, i32, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, double, double, i32, i32, double, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, [29 x i32], i32, i32, i32, i32, i32, i32, i32, i32, double, double, double, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, double, i32, i32, i32, i32, i32, i32, i32, i32, double, i32, ptr, ptr, i32, i32, i32, i32, i32, ptr, i32, ptr, i32, [256 x i8], i32, [256 x i8], [512 x i8], i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, double, double, double, double, double, double, double, double, double, double, double, double, double, double, ptr, double, double, double, double, i32, [6 x i8], [1 x %struct.__jmp_buf_tag], [40 x i8], [1 x %struct.__jmp_buf_tag], [40 x i8], ptr, ptr, ptr, ptr, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, i32, i32, ptr, i32, ptr, i32, ptr, ptr, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i64, i32, i32, i32, i32, i32, ptr, ptr, i32, i32, i32, double, i32, double, double, double, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, ptr, ptr, i32, i32, i32, ptr, double, double, double, double, i32, i32, i32, i32, i32, i32, ptr, ptr, i32 }
%struct.__jmp_buf_tag = type { [8 x i64], i32, %struct.__sigset_t }
%struct.__sigset_t = type { [16 x i64] }
%struct.qhstatT = type { [249 x %union.intrealT], [259 x i8], [249 x ptr], [249 x i16], [249 x i8], [249 x i8], [9 x %union.intrealT], i32, i32, i32, i32, double }
%union.intrealT = type { double }
%struct.qhmemT = type { i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, i32, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32 }
%struct.facetT = type { double, double, double, ptr, %union.anon, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, i32, i32 }
%union.anon = type { double }
%struct.setT = type { i32, [1 x %union.setelemT] }
%union.setelemT = type { ptr }
%struct.vertexT = type { ptr, ptr, ptr, ptr, i32, i32, i8 }

@qh_qh = external global %struct.qhT, align 8
@qh_qhstat = external global %struct.qhstatT, align 8
@qhmem = external global %struct.qhmemT, align 8
@.str.142 = external hidden unnamed_addr constant [125 x i8], align 1
@.str.143 = external hidden unnamed_addr constant [62 x i8], align 1
@.str.144 = external hidden unnamed_addr constant [104 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 @qh_fprintf(ptr noundef, i32 noundef, ptr noundef, ...) #1

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

23:                                               ; preds = %2
  %24 = load ptr, ptr getelementptr inbounds (%struct.qhT, ptr @qh_qh, i32 0, i32 158), align 8, !tbaa !15
  call void (ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %24, i32 noundef 2031, ptr noundef @.str.142)
  br label %25

25:                                               ; preds = %23, %2
  %26 = load ptr, ptr %3, align 8, !tbaa !5
  store ptr %26, ptr %5, align 8, !tbaa !5
  br label %27

27:                                               ; preds = %240, %25
  %28 = load ptr, ptr %5, align 8, !tbaa !5
  %29 = icmp ne ptr %28, null
  br i1 %29, label %30, label %35

30:                                               ; preds = %27
  %31 = load ptr, ptr %5, align 8, !tbaa !5
  %32 = getelementptr inbounds %struct.facetT, ptr %31, i32 0, i32 7
  %33 = load ptr, ptr %32, align 8, !tbaa !16
  store ptr %33, ptr %11, align 8, !tbaa !5
  %34 = icmp ne ptr %33, null
  br label %35

35:                                               ; preds = %30, %27
  %36 = phi i1 [ false, %27 ], [ %34, %30 ]
  br i1 %36, label %37, label %242

37:                                               ; preds = %35
  %38 = load ptr, ptr %5, align 8, !tbaa !5
  %39 = getelementptr inbounds %struct.facetT, ptr %38, i32 0, i32 3
  %40 = load ptr, ptr %39, align 8, !tbaa !18
  %41 = icmp ne ptr %40, null
  br i1 %41, label %42, label %43

42:                                               ; preds = %37
  br label %240

43:                                               ; preds = %37
  %44 = load ptr, ptr %5, align 8, !tbaa !5
  %45 = getelementptr inbounds %struct.facetT, ptr %44, i32 0, i32 15
  %46 = load i32, ptr %45, align 8
  %47 = lshr i32 %46, 25
  %48 = and i32 %47, 1
  %49 = icmp ne i32 %48, 0
  br i1 %49, label %56, label %50

50:                                               ; preds = %43
  %51 = load ptr, ptr getelementptr inbounds (%struct.qhT, ptr @qh_qh, i32 0, i32 158), align 8, !tbaa !15
  %52 = load ptr, ptr %5, align 8, !tbaa !5
  %53 = getelementptr inbounds %struct.facetT, ptr %52, i32 0, i32 14
  %54 = load i32, ptr %53, align 4, !tbaa !19
  call void (ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %51, i32 noundef 6225, ptr noundef @.str.143, i32 noundef %54)
  %55 = load ptr, ptr %5, align 8, !tbaa !5
  call void @qh_errexit(i32 noundef 5, ptr noundef %55, ptr noundef null)
  br label %56

56:                                               ; preds = %50, %43
  %57 = load ptr, ptr %5, align 8, !tbaa !5
  %58 = getelementptr inbounds %struct.facetT, ptr %57, i32 0, i32 10
  %59 = load ptr, ptr %58, align 8, !tbaa !20
  %60 = getelementptr inbounds %struct.setT, ptr %59, i32 0, i32 1
  %61 = getelementptr inbounds [1 x %union.setelemT], ptr %60, i64 0, i64 0
  %62 = load ptr, ptr %61, align 8, !tbaa !21
  store ptr %62, ptr %8, align 8, !tbaa !5
  %63 = load ptr, ptr %5, align 8, !tbaa !5
  %64 = getelementptr inbounds %struct.facetT, ptr %63, i32 0, i32 4
  %65 = load ptr, ptr %64, align 8, !tbaa !21
  %66 = load ptr, ptr %5, align 8, !tbaa !5
  %67 = icmp eq ptr %65, %66
  br i1 %67, label %68, label %116

68:                                               ; preds = %56
  %69 = load i32, ptr getelementptr inbounds (%struct.qhT, ptr @qh_qh, i32 0, i32 96), align 8, !tbaa !22
  %70 = sub nsw i32 %69, 1
  %71 = load i32, ptr getelementptr inbounds ([249 x %union.intrealT], ptr @qh_qhstat, i64 0, i64 216), align 8, !tbaa !21
  %72 = icmp eq i32 %70, %71
  br i1 %72, label %73, label %75

73:                                               ; preds = %68
  %74 = load i32, ptr getelementptr inbounds (%struct.qhT, ptr @qh_qh, i32 0, i32 92), align 8, !tbaa !23
  store i32 %74, ptr getelementptr inbounds (%struct.qhT, ptr @qh_qh, i32 0, i32 29), align 8, !tbaa !11
  store i32 %74, ptr getelementptr inbounds (%struct.qhmemT, ptr @qhmem, i32 0, i32 14), align 8, !tbaa !24
  br label %75

75:                                               ; preds = %73, %68
  %76 = load i32, ptr getelementptr inbounds ([249 x %union.intrealT], ptr @qh_qhstat, i64 0, i64 169), align 8, !tbaa !21
  %77 = add nsw i32 %76, 1
  store i32 %77, ptr getelementptr inbounds ([249 x %union.intrealT], ptr @qh_qhstat, i64 0, i64 169), align 8, !tbaa !21
  %78 = load ptr, ptr %5, align 8, !tbaa !5
  %79 = getelementptr inbounds %struct.facetT, ptr %78, i32 0, i32 8
  %80 = load ptr, ptr %79, align 8, !tbaa !26
  %81 = getelementptr inbounds %struct.setT, ptr %80, i32 0, i32 1
  %82 = getelementptr inbounds [1 x %union.setelemT], ptr %81, i64 0, i64 0
  %83 = load ptr, ptr %82, align 8, !tbaa !21
  store ptr %83, ptr %13, align 8, !tbaa !5
  store ptr null, ptr %14, align 8, !tbaa !5
  %84 = load ptr, ptr %5, align 8, !tbaa !5
  %85 = getelementptr inbounds %struct.facetT, ptr %84, i32 0, i32 8
  %86 = load ptr, ptr %85, align 8, !tbaa !26
  %87 = icmp ne ptr %86, null
  br i1 %87, label %88, label %111

88:                                               ; preds = %75
  %89 = load ptr, ptr %5, align 8, !tbaa !5
  %90 = getelementptr inbounds %struct.facetT, ptr %89, i32 0, i32 8
  %91 = load ptr, ptr %90, align 8, !tbaa !26
  %92 = getelementptr inbounds %struct.setT, ptr %91, i32 0, i32 1
  %93 = getelementptr inbounds [1 x %union.setelemT], ptr %92, i64 0, i64 0
  store ptr %93, ptr %15, align 8, !tbaa !5
  br label %94

94:                                               ; preds = %109, %88
  %95 = load ptr, ptr %15, align 8, !tbaa !5
  %96 = getelementptr inbounds ptr, ptr %95, i32 1
  store ptr %96, ptr %15, align 8, !tbaa !5
  %97 = load ptr, ptr %95, align 8, !tbaa !5
  store ptr %97, ptr %14, align 8, !tbaa !5
  %98 = icmp ne ptr %97, null
  br i1 %98, label %99, label %110

99:                                               ; preds = %94
  %100 = load ptr, ptr %14, align 8, !tbaa !5
  %101 = load ptr, ptr %13, align 8, !tbaa !5
  %102 = icmp ne ptr %100, %101
  br i1 %102, label %103, label %109

103:                                              ; preds = %99
  %104 = load ptr, ptr %14, align 8, !tbaa !5
  %105 = getelementptr inbounds %struct.vertexT, ptr %104, i32 0, i32 6
  %106 = load i8, ptr %105, align 8
  %107 = and i8 %106, -9
  %108 = or i8 %107, 8
  store i8 %108, ptr %105, align 8
  br label %109

109:                                              ; preds = %103, %99
  br label %94, !llvm.loop !27

110:                                              ; preds = %94
  br label %111

111:                                              ; preds = %110, %75
  %112 = load ptr, ptr %8, align 8, !tbaa !5
  %113 = getelementptr inbounds %struct.facetT, ptr %112, i32 0, i32 4
  store ptr null, ptr %113, align 8, !tbaa !21
  %114 = load ptr, ptr %5, align 8, !tbaa !5
  %115 = load ptr, ptr %8, align 8, !tbaa !5
  call void @qh_mergefacet(ptr noundef %114, ptr noundef %115, i32 noundef 13, ptr noundef null, ptr noundef null, i32 noundef 1)
  br label %237

116:                                              ; preds = %56
  %117 = load ptr, ptr %5, align 8, !tbaa !5
  store ptr %117, ptr %10, align 8, !tbaa !5
  store i32 0, ptr %18, align 4, !tbaa !9
  %118 = load ptr, ptr %5, align 8, !tbaa !5
  store ptr %118, ptr %7, align 8, !tbaa !5
  %119 = load ptr, ptr %5, align 8, !tbaa !5
  %120 = getelementptr inbounds %struct.facetT, ptr %119, i32 0, i32 4
  %121 = load ptr, ptr %120, align 8, !tbaa !21
  store ptr %121, ptr %6, align 8, !tbaa !5
  br label %122

122:                                              ; preds = %174, %116
  %123 = load ptr, ptr %6, align 8, !tbaa !5
  %124 = icmp ne ptr %123, null
  br i1 %124, label %125, label %176

125:                                              ; preds = %122
  %126 = load ptr, ptr %6, align 8, !tbaa !5
  %127 = getelementptr inbounds %struct.facetT, ptr %126, i32 0, i32 4
  %128 = load ptr, ptr %127, align 8, !tbaa !21
  store ptr %128, ptr %12, align 8, !tbaa !5
  %129 = load ptr, ptr %6, align 8, !tbaa !5
  %130 = getelementptr inbounds %struct.facetT, ptr %129, i32 0, i32 15
  %131 = load i32, ptr %130, align 8
  %132 = lshr i32 %131, 26
  %133 = and i32 %132, 1
  %134 = icmp ne i32 %133, 0
  br i1 %134, label %142, label %135

135:                                              ; preds = %125
  %136 = load ptr, ptr %6, align 8, !tbaa !5
  %137 = getelementptr inbounds %struct.facetT, ptr %136, i32 0, i32 15
  %138 = load i32, ptr %137, align 8
  %139 = lshr i32 %138, 11
  %140 = and i32 %139, 1
  %141 = icmp ne i32 %140, 0
  br i1 %141, label %142, label %144

142:                                              ; preds = %135, %125
  %143 = load ptr, ptr %6, align 8, !tbaa !5
  call void @qh_infiniteloop(ptr noundef %143)
  br label %144

144:                                              ; preds = %142, %135
  %145 = load ptr, ptr %6, align 8, !tbaa !5
  %146 = getelementptr inbounds %struct.facetT, ptr %145, i32 0, i32 15
  %147 = load i32, ptr %146, align 8
  %148 = and i32 %147, -67108865
  %149 = or i32 %148, 67108864
  store i32 %149, ptr %146, align 8
  %150 = load ptr, ptr %6, align 8, !tbaa !5
  %151 = getelementptr inbounds %struct.facetT, ptr %150, i32 0, i32 3
  %152 = load ptr, ptr %151, align 8, !tbaa !18
  %153 = icmp ne ptr %152, null
  br i1 %153, label %154, label %162

154:                                              ; preds = %144
  %155 = load ptr, ptr %6, align 8, !tbaa !5
  %156 = getelementptr inbounds %struct.facetT, ptr %155, i32 0, i32 4
  %157 = load ptr, ptr %156, align 8, !tbaa !21
  %158 = load ptr, ptr %7, align 8, !tbaa !5
  %159 = getelementptr inbounds %struct.facetT, ptr %158, i32 0, i32 4
  store ptr %157, ptr %159, align 8, !tbaa !21
  %160 = load ptr, ptr %6, align 8, !tbaa !5
  %161 = getelementptr inbounds %struct.facetT, ptr %160, i32 0, i32 4
  store ptr null, ptr %161, align 8, !tbaa !21
  br label %166

162:                                              ; preds = %144
  %163 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %163, ptr %7, align 8, !tbaa !5
  %164 = load i32, ptr %18, align 4, !tbaa !9
  %165 = add nsw i32 %164, 1
  store i32 %165, ptr %18, align 4, !tbaa !9
  br label %166

166:                                              ; preds = %162, %154
  br label %167

167:                                              ; preds = %166
  %168 = load ptr, ptr %6, align 8, !tbaa !5
  %169 = load ptr, ptr %5, align 8, !tbaa !5
  %170 = icmp eq ptr %168, %169
  br i1 %170, label %171, label %172

171:                                              ; preds = %167
  br label %174

172:                                              ; preds = %167
  %173 = load ptr, ptr %12, align 8, !tbaa !5
  br label %174

174:                                              ; preds = %172, %171
  %175 = phi ptr [ null, %171 ], [ %173, %172 ]
  store ptr %175, ptr %6, align 8, !tbaa !5
  br label %122, !llvm.loop !29

176:                                              ; preds = %122
  br label %177

177:                                              ; preds = %189, %176
  %178 = load ptr, ptr %11, align 8, !tbaa !5
  %179 = icmp ne ptr %178, null
  br i1 %179, label %180, label %187

180:                                              ; preds = %177
  %181 = load ptr, ptr %11, align 8, !tbaa !5
  %182 = getelementptr inbounds %struct.facetT, ptr %181, i32 0, i32 15
  %183 = load i32, ptr %182, align 8
  %184 = lshr i32 %183, 26
  %185 = and i32 %184, 1
  %186 = icmp ne i32 %185, 0
  br label %187

187:                                              ; preds = %180, %177
  %188 = phi i1 [ false, %177 ], [ %186, %180 ]
  br i1 %188, label %189, label %193

189:                                              ; preds = %187
  %190 = load ptr, ptr %11, align 8, !tbaa !5
  %191 = getelementptr inbounds %struct.facetT, ptr %190, i32 0, i32 7
  %192 = load ptr, ptr %191, align 8, !tbaa !16
  store ptr %192, ptr %11, align 8, !tbaa !5
  br label %177, !llvm.loop !30

193:                                              ; preds = %187
  %194 = load ptr, ptr %8, align 8, !tbaa !5
  %195 = getelementptr inbounds %struct.facetT, ptr %194, i32 0, i32 4
  store ptr null, ptr %195, align 8, !tbaa !21
  %196 = load ptr, ptr %10, align 8, !tbaa !5
  %197 = load ptr, ptr %8, align 8, !tbaa !5
  call void @qh_mergecycle(ptr noundef %196, ptr noundef %197)
  %198 = load ptr, ptr %8, align 8, !tbaa !5
  %199 = getelementptr inbounds %struct.facetT, ptr %198, i32 0, i32 15
  %200 = load i32, ptr %199, align 8
  %201 = and i32 %200, 511
  %202 = load i32, ptr %18, align 4, !tbaa !9
  %203 = add nsw i32 %201, %202
  store i32 %203, ptr %19, align 4, !tbaa !9
  %204 = load i32, ptr %19, align 4, !tbaa !9
  %205 = icmp sgt i32 %204, 511
  br i1 %205, label %206, label %212

206:                                              ; preds = %193
  %207 = load ptr, ptr %8, align 8, !tbaa !5
  %208 = getelementptr inbounds %struct.facetT, ptr %207, i32 0, i32 15
  %209 = load i32, ptr %208, align 8
  %210 = and i32 %209, -512
  %211 = or i32 %210, 511
  store i32 %211, ptr %208, align 8
  br label %222

212:                                              ; preds = %193
  %213 = load i32, ptr %19, align 4, !tbaa !9
  %214 = trunc i32 %213 to i16
  %215 = zext i16 %214 to i32
  %216 = load ptr, ptr %8, align 8, !tbaa !5
  %217 = getelementptr inbounds %struct.facetT, ptr %216, i32 0, i32 15
  %218 = load i32, ptr %217, align 8
  %219 = and i32 %215, 511
  %220 = and i32 %218, -512
  %221 = or i32 %220, %219
  store i32 %221, ptr %217, align 8
  br label %222

222:                                              ; preds = %212, %206
  %223 = load i32, ptr getelementptr inbounds ([249 x %union.intrealT], ptr @qh_qhstat, i64 0, i64 45), align 8, !tbaa !21
  %224 = add nsw i32 %223, 1
  store i32 %224, ptr getelementptr inbounds ([249 x %union.intrealT], ptr @qh_qhstat, i64 0, i64 45), align 8, !tbaa !21
  %225 = load i32, ptr %18, align 4, !tbaa !9
  %226 = load i32, ptr %17, align 4, !tbaa !9
  %227 = add nsw i32 %226, %225
  store i32 %227, ptr %17, align 4, !tbaa !9
  %228 = load i32, ptr %18, align 4, !tbaa !9
  %229 = load i32, ptr getelementptr inbounds ([249 x %union.intrealT], ptr @qh_qhstat, i64 0, i64 44), align 8, !tbaa !21
  %230 = add nsw i32 %229, %228
  store i32 %230, ptr getelementptr inbounds ([249 x %union.intrealT], ptr @qh_qhstat, i64 0, i64 44), align 8, !tbaa !21
  %231 = load i32, ptr getelementptr inbounds ([249 x %union.intrealT], ptr @qh_qhstat, i64 0, i64 43), align 8, !tbaa !21
  %232 = load i32, ptr %18, align 4, !tbaa !9
  %233 = icmp slt i32 %231, %232
  br i1 %233, label %234, label %236

234:                                              ; preds = %222
  %235 = load i32, ptr %18, align 4, !tbaa !9
  store i32 %235, ptr getelementptr inbounds ([249 x %union.intrealT], ptr @qh_qhstat, i64 0, i64 43), align 8, !tbaa !21
  br label %236

236:                                              ; preds = %234, %222
  br label %237

237:                                              ; preds = %236, %111
  %238 = load i32, ptr %16, align 4, !tbaa !9
  %239 = add nsw i32 %238, 1
  store i32 %239, ptr %16, align 4, !tbaa !9
  br label %240

240:                                              ; preds = %237, %42
  %241 = load ptr, ptr %11, align 8, !tbaa !5
  store ptr %241, ptr %5, align 8, !tbaa !5
  br label %27, !llvm.loop !31

242:                                              ; preds = %35
  %243 = load i32, ptr %16, align 4, !tbaa !9
  %244 = icmp ne i32 %243, 0
  br i1 %244, label %245, label %289

245:                                              ; preds = %242
  %246 = load ptr, ptr getelementptr inbounds (%struct.qhT, ptr @qh_qh, i32 0, i32 166), align 8, !tbaa !32
  store ptr %246, ptr %9, align 8, !tbaa !5
  br label %247

247:                                              ; preds = %273, %245
  %248 = load ptr, ptr %9, align 8, !tbaa !5
  %249 = icmp ne ptr %248, null
  br i1 %249, label %250, label %255

250:                                              ; preds = %247
  %251 = load ptr, ptr %9, align 8, !tbaa !5
  %252 = getelementptr inbounds %struct.facetT, ptr %251, i32 0, i32 7
  %253 = load ptr, ptr %252, align 8, !tbaa !16
  %254 = icmp ne ptr %253, null
  br label %255

255:                                              ; preds = %250, %247
  %256 = phi i1 [ false, %247 ], [ %254, %250 ]
  br i1 %256, label %257, label %277

257:                                              ; preds = %255
  %258 = load ptr, ptr %9, align 8, !tbaa !5
  %259 = getelementptr inbounds %struct.facetT, ptr %258, i32 0, i32 15
  %260 = load i32, ptr %259, align 8
  %261 = lshr i32 %260, 24
  %262 = and i32 %261, 1
  %263 = icmp ne i32 %262, 0
  br i1 %263, label %264, label %272

264:                                              ; preds = %257
  %265 = load ptr, ptr %9, align 8, !tbaa !5
  call void @qh_test_redundant_neighbors(ptr noundef %265)
  %266 = load ptr, ptr %9, align 8, !tbaa !5
  call void @qh_maybe_duplicateridges(ptr noundef %266)
  %267 = load ptr, ptr %9, align 8, !tbaa !5
  %268 = getelementptr inbounds %struct.facetT, ptr %267, i32 0, i32 15
  %269 = load i32, ptr %268, align 8
  %270 = and i32 %269, -16777217
  %271 = or i32 %270, 0
  store i32 %271, ptr %268, align 8
  br label %272

272:                                              ; preds = %264, %257
  br label %273

273:                                              ; preds = %272
  %274 = load ptr, ptr %9, align 8, !tbaa !5
  %275 = getelementptr inbounds %struct.facetT, ptr %274, i32 0, i32 7
  %276 = load ptr, ptr %275, align 8, !tbaa !16
  store ptr %276, ptr %9, align 8, !tbaa !5
  br label %247, !llvm.loop !33

277:                                              ; preds = %255
  %278 = call i32 @qh_merge_degenredundant()
  %279 = load i32, ptr %20, align 4, !tbaa !9
  %280 = add nsw i32 %279, %278
  store i32 %280, ptr %20, align 4, !tbaa !9
  %281 = load ptr, ptr %4, align 8, !tbaa !5
  store i32 1, ptr %281, align 4, !tbaa !9
  %282 = load i32, ptr getelementptr inbounds (%struct.qhT, ptr @qh_qh, i32 0, i32 29), align 8, !tbaa !11
  %283 = icmp sge i32 %282, 1
  br i1 %283, label %284, label %288

284:                                              ; preds = %277
  %285 = load ptr, ptr getelementptr inbounds (%struct.qhT, ptr @qh_qh, i32 0, i32 158), align 8, !tbaa !15
  %286 = load i32, ptr %16, align 4, !tbaa !9
  %287 = load i32, ptr %20, align 4, !tbaa !9
  call void (ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %285, i32 noundef 1013, ptr noundef @.str.144, i32 noundef %286, i32 noundef %287)
  br label %288

288:                                              ; preds = %284, %277
  br label %289

289:                                              ; preds = %288, %242
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #3
  ret void
}

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

; Function Attrs: nounwind uwtable
declare dso_local i32 @qh_merge_degenredundant() #2

declare void @qh_errexit(i32 noundef, ptr noundef, ptr noundef) #1

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

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

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

declare void @qh_infiniteloop(ptr noundef) #1

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

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 = !{!"int", !7, i64 0}
!11 = !{!12, !10, i64 136}
!12 = !{!"qhT", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !13, i64 24, !10, i64 32, !10, i64 36, !10, i64 40, !10, i64 44, !10, i64 48, !10, i64 52, !10, i64 56, !10, i64 60, !13, i64 64, !13, i64 72, !10, i64 80, !10, i64 84, !10, i64 88, !10, i64 92, !10, i64 96, !10, i64 100, !6, i64 104, !10, i64 112, !10, i64 116, !6, i64 120, !10, i64 128, !10, i64 132, !10, i64 136, !10, i64 140, !10, i64 144, !10, i64 148, !10, i64 152, !13, i64 160, !13, i64 168, !10, i64 176, !10, i64 180, !10, i64 184, !10, i64 188, !13, i64 192, !13, i64 200, !10, i64 208, !10, i64 212, !13, i64 216, !10, i64 224, !10, i64 228, !10, i64 232, !10, i64 236, !10, i64 240, !10, i64 244, !10, i64 248, !10, i64 252, !10, i64 256, !10, i64 260, !10, i64 264, !10, i64 268, !10, i64 272, !10, i64 276, !10, i64 280, !10, i64 284, !10, i64 288, !10, i64 292, !10, i64 296, !7, i64 300, !10, i64 416, !10, i64 420, !10, i64 424, !10, i64 428, !10, i64 432, !10, i64 436, !10, i64 440, !10, i64 444, !13, i64 448, !13, i64 456, !13, i64 464, !10, i64 472, !10, i64 476, !10, i64 480, !10, i64 484, !10, i64 488, !10, i64 492, !10, i64 496, !10, i64 500, !10, i64 504, !10, i64 508, !10, i64 512, !10, i64 516, !10, i64 520, !10, i64 524, !10, i64 528, !10, i64 532, !10, i64 536, !10, i64 540, !10, i64 544, !13, i64 552, !10, i64 560, !10, i64 564, !10, i64 568, !10, i64 572, !10, i64 576, !10, i64 580, !10, i64 584, !10, i64 588, !13, i64 592, !10, i64 600, !6, i64 608, !6, i64 616, !10, i64 624, !10, i64 628, !10, i64 632, !10, i64 636, !10, i64 640, !6, i64 648, !10, i64 656, !6, i64 664, !10, i64 672, !7, i64 676, !10, i64 932, !7, i64 936, !7, i64 1192, !10, i64 1704, !10, i64 1708, !10, i64 1712, !10, i64 1716, !10, i64 1720, !10, i64 1724, !6, i64 1728, !6, i64 1736, !6, i64 1744, !6, i64 1752, !13, i64 1760, !13, i64 1768, !13, i64 1776, !13, i64 1784, !13, i64 1792, !13, i64 1800, !13, i64 1808, !13, i64 1816, !13, i64 1824, !13, i64 1832, !13, i64 1840, !13, i64 1848, !13, i64 1856, !13, i64 1864, !6, i64 1872, !13, i64 1880, !13, i64 1888, !13, i64 1896, !13, i64 1904, !10, i64 1912, !7, i64 1916, !7, i64 1928, !7, i64 2128, !7, i64 2168, !7, i64 2368, !6, i64 2408, !6, i64 2416, !6, i64 2424, !6, i64 2432, !10, i64 2440, !10, i64 2444, !10, i64 2448, !6, i64 2456, !6, i64 2464, !6, i64 2472, !6, i64 2480, !6, i64 2488, !10, i64 2496, !10, i64 2500, !6, i64 2504, !10, i64 2512, !6, i64 2520, !10, i64 2528, !6, i64 2536, !6, i64 2544, !6, i64 2552, !6, i64 2560, !10, i64 2568, !10, i64 2572, !10, i64 2576, !10, i64 2580, !10, i64 2584, !10, i64 2588, !10, i64 2592, !10, i64 2596, !14, i64 2600, !10, i64 2608, !10, i64 2612, !10, i64 2616, !10, i64 2620, !10, i64 2624, !6, i64 2632, !6, i64 2640, !10, i64 2648, !10, i64 2652, !10, i64 2656, !13, i64 2664, !10, i64 2672, !13, i64 2680, !13, i64 2688, !13, i64 2696, !10, i64 2704, !10, i64 2708, !10, i64 2712, !10, i64 2716, !10, i64 2720, !13, i64 2728, !13, i64 2736, !10, i64 2744, !10, i64 2748, !10, i64 2752, !10, i64 2756, !10, i64 2760, !10, i64 2764, !13, i64 2768, !13, i64 2776, !10, i64 2784, !10, i64 2788, !10, i64 2792, !10, i64 2796, !6, i64 2800, !6, i64 2808, !6, i64 2816, !6, i64 2824, !6, i64 2832, !6, i64 2840, !6, i64 2848, !6, i64 2856, !6, i64 2864, !10, i64 2872, !6, i64 2880, !6, i64 2888, !10, i64 2896, !10, i64 2900, !10, i64 2904, !6, i64 2912, !13, i64 2920, !13, i64 2928, !13, i64 2936, !13, i64 2944, !10, i64 2952, !10, i64 2956, !10, i64 2960, !10, i64 2964, !10, i64 2968, !10, i64 2972, !6, i64 2976, !6, i64 2984, !10, i64 2992}
!13 = !{!"double", !7, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = !{!12, !6, i64 2424}
!16 = !{!17, !6, i64 56}
!17 = !{!"facetT", !13, i64 0, !13, i64 8, !13, i64 16, !6, i64 24, !7, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !10, i64 104, !10, i64 108, !10, i64 112, !10, i64 113, !10, i64 113, !10, i64 113, !10, i64 113, !10, i64 113, !10, i64 113, !10, i64 113, !10, i64 114, !10, i64 114, !10, i64 114, !10, i64 114, !10, i64 114, !10, i64 114, !10, i64 114, !10, i64 114, !10, i64 115, !10, i64 115, !10, i64 115, !10, i64 115, !10, i64 115, !10, i64 115, !10, i64 115, !10, i64 115}
!18 = !{!17, !6, i64 24}
!19 = !{!17, !10, i64 108}
!20 = !{!17, !6, i64 80}
!21 = !{!7, !7, i64 0}
!22 = !{!12, !10, i64 560}
!23 = !{!12, !10, i64 536}
!24 = !{!25, !10, i64 88}
!25 = !{!"qhmemT", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !10, i64 64, !6, i64 72, !6, i64 80, !10, i64 88, !10, i64 92, !10, i64 96, !10, i64 100, !10, i64 104, !10, i64 108, !10, i64 112, !10, i64 116, !10, i64 120, !10, i64 124, !10, i64 128, !10, i64 132, !10, i64 136, !10, i64 140, !10, i64 144}
!26 = !{!17, !6, i64 64}
!27 = distinct !{!27, !28}
!28 = !{!"llvm.loop.mustprogress"}
!29 = distinct !{!29, !28}
!30 = distinct !{!30, !28}
!31 = distinct !{!31, !28}
!32 = !{!12, !6, i64 2480}
!33 = distinct !{!33, !28}


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

%struct.qhT = type { i32, i32, i32, i32, i32, i32, double, i32, i32, i32, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, i32, i32, ptr, i32, i32, ptr, i32, i32, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, double, double, i32, i32, double, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, [29 x i32], i32, i32, i32, i32, i32, i32, i32, i32, double, double, double, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, double, i32, i32, i32, i32, i32, i32, i32, i32, double, i32, ptr, ptr, i32, i32, i32, i32, i32, ptr, i32, ptr, i32, [256 x i8], i32, [256 x i8], [512 x i8], i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, double, double, double, double, double, double, double, double, double, double, double, double, double, double, ptr, double, double, double, double, i32, [6 x i8], [1 x %struct.__jmp_buf_tag], [40 x i8], [1 x %struct.__jmp_buf_tag], [40 x i8], ptr, ptr, ptr, ptr, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, i32, i32, ptr, i32, ptr, i32, ptr, ptr, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i64, i32, i32, i32, i32, i32, ptr, ptr, i32, i32, i32, double, i32, double, double, double, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, ptr, ptr, i32, i32, i32, ptr, double, double, double, double, i32, i32, i32, i32, i32, i32, ptr, ptr, i32 }
%struct.__jmp_buf_tag = type { [8 x i64], i32, %struct.__sigset_t }
%struct.__sigset_t = type { [16 x i64] }
%struct.qhstatT = type { [249 x %union.intrealT], [259 x i8], [249 x ptr], [249 x i16], [249 x i8], [249 x i8], [9 x %union.intrealT], i32, i32, i32, i32, double }
%union.intrealT = type { double }
%struct.qhmemT = type { i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, i32, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32 }

@qh_qh = external local_unnamed_addr global %struct.qhT, align 8
@qh_qhstat = external local_unnamed_addr global %struct.qhstatT, align 8
@qhmem = external local_unnamed_addr global %struct.qhmemT, align 8
@.str.142 = external hidden unnamed_addr constant [125 x i8], align 1
@.str.143 = external hidden unnamed_addr constant [62 x i8], align 1
@.str.144 = external hidden unnamed_addr constant [104 x i8], align 1

declare void @qh_fprintf(ptr noundef, i32 noundef, ptr noundef, ...) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
define dso_local void @qh_mergecycle_all(ptr noundef %0, ptr nocapture noundef writeonly %1) local_unnamed_addr #1 {
  %3 = load i32, ptr getelementptr inbounds (i8, ptr @qh_qh, i64 136), align 8, !tbaa !5
  %4 = icmp sgt i32 %3, 1
  br i1 %4, label %5, label %7

5:                                                ; preds = %2
  %6 = load ptr, ptr getelementptr inbounds (i8, ptr @qh_qh, i64 2424), align 8, !tbaa !13
  tail call void (ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %6, i32 noundef 2031, ptr noundef nonnull @.str.142) #2
  br label %7

7:                                                ; preds = %5, %2
  %.not113 = icmp eq ptr %0, null
  br i1 %.not113, label %.critedge.thread, label %.lr.ph118

.lr.ph118:                                        ; preds = %7, %96
  %.0116 = phi ptr [ %.283, %96 ], [ %0, %7 ]
  %.075114 = phi i32 [ %.176, %96 ], [ 0, %7 ]
  %8 = getelementptr inbounds i8, ptr %.0116, i64 56
  %9 = load ptr, ptr %8, align 8, !tbaa !14
  %.not89 = icmp eq ptr %9, null
  br i1 %.not89, label %.critedge, label %10

10:                                               ; preds = %.lr.ph118
  %11 = getelementptr inbounds i8, ptr %.0116, i64 24
  %12 = load ptr, ptr %11, align 8, !tbaa !16
  %.not94 = icmp eq ptr %12, null
  br i1 %.not94, label %13, label %96

13:                                               ; preds = %10
  %14 = getelementptr inbounds i8, ptr %.0116, i64 112
  %15 = load i32, ptr %14, align 8
  %16 = and i32 %15, 33554432
  %.not95 = icmp eq i32 %16, 0
  br i1 %.not95, label %17, label %21

17:                                               ; preds = %13
  %18 = load ptr, ptr getelementptr inbounds (i8, ptr @qh_qh, i64 2424), align 8, !tbaa !13
  %19 = getelementptr inbounds i8, ptr %.0116, i64 108
  %20 = load i32, ptr %19, align 4, !tbaa !17
  tail call void (ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %18, i32 noundef 6225, ptr noundef nonnull @.str.143, i32 noundef %20) #2
  tail call void @qh_errexit(i32 noundef 5, ptr noundef nonnull %.0116, ptr noundef null) #2
  br label %21

21:                                               ; preds = %17, %13
  %22 = getelementptr inbounds i8, ptr %.0116, i64 80
  %23 = load ptr, ptr %22, align 8, !tbaa !18
  %24 = getelementptr inbounds i8, ptr %23, i64 8
  %25 = load ptr, ptr %24, align 8, !tbaa !19
  %26 = getelementptr inbounds i8, ptr %.0116, i64 32
  %27 = load ptr, ptr %26, align 8, !tbaa !19
  %28 = icmp eq ptr %27, %.0116
  br i1 %28, label %29, label %select.unfold.preheader

select.unfold.preheader:                          ; preds = %21
  %.not96106 = icmp eq ptr %27, null
  br i1 %.not96106, label %.preheader105, label %.lr.ph

29:                                               ; preds = %21
  %30 = load i32, ptr getelementptr inbounds (i8, ptr @qh_qh, i64 560), align 8, !tbaa !20
  %31 = add nsw i32 %30, -1
  %32 = load i32, ptr getelementptr inbounds (i8, ptr @qh_qhstat, i64 1728), align 8, !tbaa !19
  %33 = icmp eq i32 %31, %32
  br i1 %33, label %34, label %36

34:                                               ; preds = %29
  %35 = load i32, ptr getelementptr inbounds (i8, ptr @qh_qh, i64 536), align 8, !tbaa !21
  store i32 %35, ptr getelementptr inbounds (i8, ptr @qh_qh, i64 136), align 8, !tbaa !5
  store i32 %35, ptr getelementptr inbounds (i8, ptr @qhmem, i64 88), align 8, !tbaa !22
  br label %36

36:                                               ; preds = %34, %29
  %37 = load i32, ptr getelementptr inbounds (i8, ptr @qh_qhstat, i64 1352), align 8, !tbaa !19
  %38 = add nsw i32 %37, 1
  store i32 %38, ptr getelementptr inbounds (i8, ptr @qh_qhstat, i64 1352), align 8, !tbaa !19
  %39 = getelementptr inbounds i8, ptr %.0116, i64 64
  %40 = load ptr, ptr %39, align 8, !tbaa !24
  %41 = getelementptr inbounds i8, ptr %40, i64 8
  %42 = load ptr, ptr %41, align 8, !tbaa !19
  %.not103111 = icmp eq ptr %42, null
  br i1 %.not103111, label %._crit_edge, label %.lr.ph112.preheader

.lr.ph112.preheader:                              ; preds = %36
  %43 = getelementptr inbounds i8, ptr %40, i64 16
  br label %.lr.ph112

.lr.ph112:                                        ; preds = %.lr.ph112.preheader, %50
  %44 = phi ptr [ %51, %50 ], [ %43, %.lr.ph112.preheader ]
  %45 = phi ptr [ %.pr, %50 ], [ %42, %.lr.ph112.preheader ]
  %.not104 = icmp eq ptr %45, %42
  br i1 %.not104, label %50, label %46

46:                                               ; preds = %.lr.ph112
  %47 = getelementptr inbounds i8, ptr %45, i64 40
  %48 = load i8, ptr %47, align 8
  %49 = or i8 %48, 8
  store i8 %49, ptr %47, align 8
  br label %50

50:                                               ; preds = %46, %.lr.ph112
  %.pr = load ptr, ptr %44, align 8, !tbaa !25
  %51 = getelementptr inbounds i8, ptr %44, i64 8
  %.not103 = icmp eq ptr %.pr, null
  br i1 %.not103, label %._crit_edge, label %.lr.ph112, !llvm.loop !26

._crit_edge:                                      ; preds = %50, %36
  %52 = getelementptr inbounds i8, ptr %25, i64 32
  store ptr null, ptr %52, align 8, !tbaa !19
  tail call void @qh_mergefacet(ptr noundef nonnull %.0116, ptr noundef %25, i32 noundef 13, ptr noundef null, ptr noundef null, i32 noundef 1)
  br label %94

.preheader105:                                    ; preds = %select.unfold, %select.unfold.preheader
  %.072.lcssa = phi i32 [ 0, %select.unfold.preheader ], [ %.1, %select.unfold ]
  br label %70

.lr.ph:                                           ; preds = %select.unfold.preheader, %select.unfold
  %.072109 = phi i32 [ %.1, %select.unfold ], [ 0, %select.unfold.preheader ]
  %.078108 = phi ptr [ %54, %select.unfold ], [ %27, %select.unfold.preheader ]
  %.079107 = phi ptr [ %.180, %select.unfold ], [ %.0116, %select.unfold.preheader ]
  %53 = getelementptr inbounds i8, ptr %.078108, i64 32
  %54 = load ptr, ptr %53, align 8, !tbaa !19
  %55 = getelementptr inbounds i8, ptr %.078108, i64 112
  %56 = load i32, ptr %55, align 8
  %57 = and i32 %56, 67110912
  %or.cond = icmp eq i32 %57, 0
  br i1 %or.cond, label %59, label %58

58:                                               ; preds = %.lr.ph
  tail call void @qh_infiniteloop(ptr noundef nonnull %.078108) #2
  %.pre = load i32, ptr %55, align 8
  br label %59

59:                                               ; preds = %.lr.ph, %58
  %60 = phi i32 [ %56, %.lr.ph ], [ %.pre, %58 ]
  %61 = or i32 %60, 67108864
  store i32 %61, ptr %55, align 8
  %62 = getelementptr inbounds i8, ptr %.078108, i64 24
  %63 = load ptr, ptr %62, align 8, !tbaa !16
  %.not101 = icmp eq ptr %63, null
  br i1 %.not101, label %67, label %64

64:                                               ; preds = %59
  %65 = load ptr, ptr %53, align 8, !tbaa !19
  %66 = getelementptr inbounds i8, ptr %.079107, i64 32
  store ptr %65, ptr %66, align 8, !tbaa !19
  store ptr null, ptr %53, align 8, !tbaa !19
  br label %select.unfold

67:                                               ; preds = %59
  %68 = add nsw i32 %.072109, 1
  br label %select.unfold

select.unfold:                                    ; preds = %64, %67
  %.180 = phi ptr [ %.079107, %64 ], [ %.078108, %67 ]
  %.1 = phi i32 [ %.072109, %64 ], [ %68, %67 ]
  %69 = icmp eq ptr %.078108, %.0116
  %.not96130 = icmp eq ptr %54, null
  %.not96 = select i1 %69, i1 true, i1 %.not96130
  br i1 %.not96, label %.preheader105, label %.lr.ph

70:                                               ; preds = %.preheader105, %74
  %.081110 = phi ptr [ %9, %.preheader105 ], [ %76, %74 ]
  %71 = getelementptr inbounds i8, ptr %.081110, i64 112
  %72 = load i32, ptr %71, align 8
  %73 = and i32 %72, 67108864
  %.not98 = icmp eq i32 %73, 0
  br i1 %.not98, label %.critedge2, label %74

74:                                               ; preds = %70
  %75 = getelementptr inbounds i8, ptr %.081110, i64 56
  %76 = load ptr, ptr %75, align 8, !tbaa !14
  %.not97 = icmp eq ptr %76, null
  br i1 %.not97, label %.critedge2, label %70, !llvm.loop !28

.critedge2:                                       ; preds = %74, %70
  %.081.lcssa = phi ptr [ null, %74 ], [ %.081110, %70 ]
  %77 = getelementptr inbounds i8, ptr %25, i64 32
  store ptr null, ptr %77, align 8, !tbaa !19
  tail call void @qh_mergecycle(ptr noundef nonnull %.0116, ptr noundef %25)
  %78 = getelementptr inbounds i8, ptr %25, i64 112
  %79 = load i32, ptr %78, align 8
  %80 = and i32 %79, 511
  %81 = add nsw i32 %80, %.072.lcssa
  %82 = icmp sgt i32 %81, 511
  %83 = and i32 %81, 511
  %84 = and i32 %79, -512
  %85 = or disjoint i32 %83, %84
  %86 = or i32 %79, 511
  %storemerge = select i1 %82, i32 %86, i32 %85
  store i32 %storemerge, ptr %78, align 8
  %87 = load i32, ptr getelementptr inbounds (i8, ptr @qh_qhstat, i64 360), align 8, !tbaa !19
  %88 = add nsw i32 %87, 1
  store i32 %88, ptr getelementptr inbounds (i8, ptr @qh_qhstat, i64 360), align 8, !tbaa !19
  %89 = load i32, ptr getelementptr inbounds (i8, ptr @qh_qhstat, i64 352), align 8, !tbaa !19
  %90 = add nsw i32 %89, %.072.lcssa
  store i32 %90, ptr getelementptr inbounds (i8, ptr @qh_qhstat, i64 352), align 8, !tbaa !19
  %91 = load i32, ptr getelementptr inbounds (i8, ptr @qh_qhstat, i64 344), align 8, !tbaa !19
  %92 = icmp slt i32 %91, %.072.lcssa
  br i1 %92, label %93, label %94

93:                                               ; preds = %.critedge2
  store i32 %.072.lcssa, ptr getelementptr inbounds (i8, ptr @qh_qhstat, i64 344), align 8, !tbaa !19
  br label %94

94:                                               ; preds = %.critedge2, %93, %._crit_edge
  %.182 = phi ptr [ %9, %._crit_edge ], [ %.081.lcssa, %93 ], [ %.081.lcssa, %.critedge2 ]
  %95 = add nsw i32 %.075114, 1
  br label %96

96:                                               ; preds = %10, %94
  %.283 = phi ptr [ %9, %10 ], [ %.182, %94 ]
  %.176 = phi i32 [ %.075114, %10 ], [ %95, %94 ]
  %.not = icmp eq ptr %.283, null
  br i1 %.not, label %.critedge, label %.lr.ph118, !llvm.loop !29

.critedge:                                        ; preds = %.lr.ph118, %96
  %.075.lcssa = phi i32 [ %.075114, %.lr.ph118 ], [ %.176, %96 ]
  %.not90 = icmp eq i32 %.075.lcssa, 0
  br i1 %.not90, label %.critedge.thread, label %.preheader

.preheader:                                       ; preds = %.critedge
  %.084122 = load ptr, ptr getelementptr inbounds (i8, ptr @qh_qh, i64 2480), align 8, !tbaa !25
  %.not91123 = icmp eq ptr %.084122, null
  br i1 %.not91123, label %.critedge4, label %.lr.ph125

.lr.ph125:                                        ; preds = %.preheader, %106
  %.084124 = phi ptr [ %.084, %106 ], [ %.084122, %.preheader ]
  %97 = getelementptr inbounds i8, ptr %.084124, i64 56
  %98 = load ptr, ptr %97, align 8, !tbaa !25
  %.not92 = icmp eq ptr %98, null
  br i1 %.not92, label %.critedge4, label %99

99:                                               ; preds = %.lr.ph125
  %100 = getelementptr inbounds i8, ptr %.084124, i64 112
  %101 = load i32, ptr %100, align 8
  %102 = and i32 %101, 16777216
  %.not93 = icmp eq i32 %102, 0
  br i1 %.not93, label %106, label %103

103:                                              ; preds = %99
  tail call void @qh_test_redundant_neighbors(ptr noundef nonnull %.084124)
  tail call void @qh_maybe_duplicateridges(ptr noundef nonnull %.084124)
  %104 = load i32, ptr %100, align 8
  %105 = and i32 %104, -16777217
  store i32 %105, ptr %100, align 8
  %.084.pre = load ptr, ptr %97, align 8, !tbaa !25
  br label %106

106:                                              ; preds = %99, %103
  %.084 = phi ptr [ %98, %99 ], [ %.084.pre, %103 ]
  %.not91 = icmp eq ptr %.084, null
  br i1 %.not91, label %.critedge4, label %.lr.ph125, !llvm.loop !30

.critedge4:                                       ; preds = %.lr.ph125, %106, %.preheader
  %107 = tail call i32 @qh_merge_degenredundant()
  store i32 1, ptr %1, align 4, !tbaa !31
  %108 = load i32, ptr getelementptr inbounds (i8, ptr @qh_qh, i64 136), align 8, !tbaa !5
  %109 = icmp sgt i32 %108, 0
  br i1 %109, label %110, label %.critedge.thread

110:                                              ; preds = %.critedge4
  %111 = load ptr, ptr getelementptr inbounds (i8, ptr @qh_qh, i64 2424), align 8, !tbaa !13
  tail call void (ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %111, i32 noundef 1013, ptr noundef nonnull @.str.144, i32 noundef %.075.lcssa, i32 noundef %107) #2
  br label %.critedge.thread

.critedge.thread:                                 ; preds = %7, %.critedge4, %110, %.critedge
  ret void
}

; Function Attrs: nounwind uwtable
declare dso_local i32 @qh_merge_degenredundant() local_unnamed_addr #1

declare void @qh_errexit(i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #0

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

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

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

declare void @qh_infiniteloop(ptr noundef) local_unnamed_addr #0

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

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 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nounwind }

!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 136}
!6 = !{!"qhT", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16, !7, i64 20, !10, i64 24, !7, i64 32, !7, i64 36, !7, i64 40, !7, i64 44, !7, i64 48, !7, i64 52, !7, i64 56, !7, i64 60, !10, i64 64, !10, i64 72, !7, i64 80, !7, i64 84, !7, i64 88, !7, i64 92, !7, i64 96, !7, i64 100, !11, i64 104, !7, i64 112, !7, i64 116, !11, i64 120, !7, i64 128, !7, i64 132, !7, i64 136, !7, i64 140, !7, i64 144, !7, i64 148, !7, i64 152, !10, i64 160, !10, i64 168, !7, i64 176, !7, i64 180, !7, i64 184, !7, i64 188, !10, i64 192, !10, i64 200, !7, i64 208, !7, i64 212, !10, i64 216, !7, i64 224, !7, i64 228, !7, i64 232, !7, i64 236, !7, i64 240, !7, i64 244, !7, i64 248, !7, i64 252, !7, i64 256, !7, i64 260, !7, i64 264, !7, i64 268, !7, i64 272, !7, i64 276, !7, i64 280, !7, i64 284, !7, i64 288, !7, i64 292, !7, i64 296, !8, i64 300, !7, i64 416, !7, i64 420, !7, i64 424, !7, i64 428, !7, i64 432, !7, i64 436, !7, i64 440, !7, i64 444, !10, i64 448, !10, i64 456, !10, i64 464, !7, i64 472, !7, i64 476, !7, i64 480, !7, i64 484, !7, i64 488, !7, i64 492, !7, i64 496, !7, i64 500, !7, i64 504, !7, i64 508, !7, i64 512, !7, i64 516, !7, i64 520, !7, i64 524, !7, i64 528, !7, i64 532, !7, i64 536, !7, i64 540, !7, i64 544, !10, i64 552, !7, i64 560, !7, i64 564, !7, i64 568, !7, i64 572, !7, i64 576, !7, i64 580, !7, i64 584, !7, i64 588, !10, i64 592, !7, i64 600, !11, i64 608, !11, i64 616, !7, i64 624, !7, i64 628, !7, i64 632, !7, i64 636, !7, i64 640, !11, i64 648, !7, i64 656, !11, i64 664, !7, i64 672, !8, i64 676, !7, i64 932, !8, i64 936, !8, i64 1192, !7, i64 1704, !7, i64 1708, !7, i64 1712, !7, i64 1716, !7, i64 1720, !7, i64 1724, !11, i64 1728, !11, i64 1736, !11, i64 1744, !11, i64 1752, !10, i64 1760, !10, i64 1768, !10, i64 1776, !10, i64 1784, !10, i64 1792, !10, i64 1800, !10, i64 1808, !10, i64 1816, !10, i64 1824, !10, i64 1832, !10, i64 1840, !10, i64 1848, !10, i64 1856, !10, i64 1864, !11, i64 1872, !10, i64 1880, !10, i64 1888, !10, i64 1896, !10, i64 1904, !7, i64 1912, !8, i64 1916, !8, i64 1928, !8, i64 2128, !8, i64 2168, !8, i64 2368, !11, i64 2408, !11, i64 2416, !11, i64 2424, !11, i64 2432, !7, i64 2440, !7, i64 2444, !7, i64 2448, !11, i64 2456, !11, i64 2464, !11, i64 2472, !11, i64 2480, !11, i64 2488, !7, i64 2496, !7, i64 2500, !11, i64 2504, !7, i64 2512, !11, i64 2520, !7, i64 2528, !11, i64 2536, !11, i64 2544, !11, i64 2552, !11, i64 2560, !7, i64 2568, !7, i64 2572, !7, i64 2576, !7, i64 2580, !7, i64 2584, !7, i64 2588, !7, i64 2592, !7, i64 2596, !12, i64 2600, !7, i64 2608, !7, i64 2612, !7, i64 2616, !7, i64 2620, !7, i64 2624, !11, i64 2632, !11, i64 2640, !7, i64 2648, !7, i64 2652, !7, i64 2656, !10, i64 2664, !7, i64 2672, !10, i64 2680, !10, i64 2688, !10, i64 2696, !7, i64 2704, !7, i64 2708, !7, i64 2712, !7, i64 2716, !7, i64 2720, !10, i64 2728, !10, i64 2736, !7, i64 2744, !7, i64 2748, !7, i64 2752, !7, i64 2756, !7, i64 2760, !7, i64 2764, !10, i64 2768, !10, i64 2776, !7, i64 2784, !7, i64 2788, !7, i64 2792, !7, i64 2796, !11, i64 2800, !11, i64 2808, !11, i64 2816, !11, i64 2824, !11, i64 2832, !11, i64 2840, !11, i64 2848, !11, i64 2856, !11, i64 2864, !7, i64 2872, !11, i64 2880, !11, i64 2888, !7, i64 2896, !7, i64 2900, !7, i64 2904, !11, i64 2912, !10, i64 2920, !10, i64 2928, !10, i64 2936, !10, i64 2944, !7, i64 2952, !7, i64 2956, !7, i64 2960, !7, i64 2964, !7, i64 2968, !7, i64 2972, !11, i64 2976, !11, i64 2984, !7, i64 2992}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"double", !8, i64 0}
!11 = !{!"any pointer", !8, i64 0}
!12 = !{!"long", !8, i64 0}
!13 = !{!6, !11, i64 2424}
!14 = !{!15, !11, i64 56}
!15 = !{!"facetT", !10, i64 0, !10, i64 8, !10, i64 16, !11, i64 24, !8, i64 32, !11, i64 40, !11, i64 48, !11, i64 56, !11, i64 64, !11, i64 72, !11, i64 80, !11, i64 88, !11, i64 96, !7, i64 104, !7, i64 108, !7, i64 112, !7, i64 113, !7, i64 113, !7, i64 113, !7, i64 113, !7, i64 113, !7, i64 113, !7, i64 113, !7, i64 114, !7, i64 114, !7, i64 114, !7, i64 114, !7, i64 114, !7, i64 114, !7, i64 114, !7, i64 114, !7, i64 115, !7, i64 115, !7, i64 115, !7, i64 115, !7, i64 115, !7, i64 115, !7, i64 115, !7, i64 115}
!16 = !{!15, !11, i64 24}
!17 = !{!15, !7, i64 108}
!18 = !{!15, !11, i64 80}
!19 = !{!8, !8, i64 0}
!20 = !{!6, !7, i64 560}
!21 = !{!6, !7, i64 536}
!22 = !{!23, !7, i64 88}
!23 = !{!"qhmemT", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16, !7, i64 20, !11, i64 24, !11, i64 32, !11, i64 40, !11, i64 48, !11, i64 56, !7, i64 64, !11, i64 72, !11, i64 80, !7, i64 88, !7, i64 92, !7, i64 96, !7, i64 100, !7, i64 104, !7, i64 108, !7, i64 112, !7, i64 116, !7, i64 120, !7, i64 124, !7, i64 128, !7, i64 132, !7, i64 136, !7, i64 140, !7, i64 144}
!24 = !{!15, !11, i64 64}
!25 = !{!11, !11, i64 0}
!26 = distinct !{!26, !27}
!27 = !{!"llvm.loop.mustprogress"}
!28 = distinct !{!28, !27}
!29 = distinct !{!29, !27}
!30 = distinct !{!30, !27}
!31 = !{!7, !7, i64 0}


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