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

; 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, i32, i32, [1 x %struct.__jmp_buf_tag], [40 x i8], i32, double, ptr, ptr, ptr, %struct.qhmemT, %struct.qhstatT }
%struct.__jmp_buf_tag = type { [8 x i64], i32, %struct.__sigset_t }
%struct.__sigset_t = type { [16 x i64] }
%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.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.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 }

@.str.223 = external hidden unnamed_addr constant [45 x i8], align 1

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

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

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

declare ptr @qh_getcentrum(ptr noundef, ptr noundef) #1

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

declare ptr @qh_makenew_nonsimplicial(ptr noundef, ptr noundef, ptr noundef, ptr noundef) #1

declare ptr @qh_memalloc(ptr noundef, i32 noundef) #1

declare ptr @qh_facetcenter(ptr noundef, ptr noundef) #1

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

16:                                               ; preds = %3
  %17 = load ptr, ptr %4, align 8, !tbaa !5
  %18 = load ptr, ptr %4, align 8, !tbaa !5
  %19 = getelementptr inbounds %struct.qhT, ptr %18, i32 0, i32 158
  %20 = load ptr, ptr %19, align 8, !tbaa !17
  %21 = load ptr, ptr %5, align 8, !tbaa !5
  %22 = getelementptr inbounds %struct.facetT, ptr %21, i32 0, i32 14
  %23 = load i32, ptr %22, align 4, !tbaa !18
  call void (ptr, ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %17, ptr noundef %20, i32 noundef 3020, ptr noundef @.str.223, i32 noundef %23)
  br label %24

24:                                               ; preds = %16, %3
  %25 = load ptr, ptr %4, align 8, !tbaa !5
  %26 = getelementptr inbounds %struct.qhT, ptr %25, i32 0, i32 182
  %27 = load i32, ptr %26, align 8, !tbaa !20
  %28 = load ptr, ptr %4, align 8, !tbaa !5
  %29 = getelementptr inbounds %struct.qhT, ptr %28, i32 0, i32 185
  store i32 %27, ptr %29, align 4, !tbaa !21
  %30 = load ptr, ptr %4, align 8, !tbaa !5
  %31 = getelementptr inbounds %struct.qhT, ptr %30, i32 0, i32 29
  %32 = load i32, ptr %31, align 8, !tbaa !11
  %33 = icmp sge i32 %32, 4
  br i1 %33, label %34, label %40

34:                                               ; preds = %24
  %35 = load ptr, ptr %4, align 8, !tbaa !5
  %36 = load ptr, ptr %4, align 8, !tbaa !5
  %37 = getelementptr inbounds %struct.qhT, ptr %36, i32 0, i32 158
  %38 = load ptr, ptr %37, align 8, !tbaa !17
  %39 = load ptr, ptr %5, align 8, !tbaa !5
  call void @qh_printfacet(ptr noundef %35, ptr noundef %38, ptr noundef %39)
  br label %40

40:                                               ; preds = %34, %24
  store ptr null, ptr %8, align 8, !tbaa !5
  %41 = load ptr, ptr %5, align 8, !tbaa !5
  %42 = getelementptr inbounds %struct.facetT, ptr %41, i32 0, i32 10
  %43 = load ptr, ptr %42, align 8, !tbaa !22
  %44 = icmp ne ptr %43, null
  br i1 %44, label %45, label %68

45:                                               ; preds = %40
  %46 = load ptr, ptr %5, align 8, !tbaa !5
  %47 = getelementptr inbounds %struct.facetT, ptr %46, i32 0, i32 10
  %48 = load ptr, ptr %47, align 8, !tbaa !22
  %49 = getelementptr inbounds %struct.setT, ptr %48, i32 0, i32 1
  %50 = getelementptr inbounds [1 x %union.setelemT], ptr %49, i64 0, i64 0
  store ptr %50, ptr %9, align 8, !tbaa !5
  br label %51

51:                                               ; preds = %56, %45
  %52 = load ptr, ptr %9, align 8, !tbaa !5
  %53 = getelementptr inbounds ptr, ptr %52, i32 1
  store ptr %53, ptr %9, align 8, !tbaa !5
  %54 = load ptr, ptr %52, align 8, !tbaa !5
  store ptr %54, ptr %8, align 8, !tbaa !5
  %55 = icmp ne ptr %54, null
  br i1 %55, label %56, label %67

56:                                               ; preds = %51
  %57 = load ptr, ptr %8, align 8, !tbaa !5
  %58 = getelementptr inbounds %struct.facetT, ptr %57, i32 0, i32 15
  %59 = load i32, ptr %58, align 8
  %60 = and i32 %59, -16385
  %61 = or i32 %60, 0
  store i32 %61, ptr %58, align 8
  %62 = load ptr, ptr %8, align 8, !tbaa !5
  %63 = getelementptr inbounds %struct.facetT, ptr %62, i32 0, i32 15
  %64 = load i32, ptr %63, align 8
  %65 = and i32 %64, -16777217
  %66 = or i32 %65, 0
  store i32 %66, ptr %63, align 8
  br label %51, !llvm.loop !23

67:                                               ; preds = %51
  br label %68

68:                                               ; preds = %67, %40
  %69 = load ptr, ptr %4, align 8, !tbaa !5
  %70 = getelementptr inbounds %struct.qhT, ptr %69, i32 0, i32 189
  %71 = load i32, ptr %70, align 8, !tbaa !25
  %72 = icmp eq i32 %71, 1
  br i1 %72, label %73, label %128

73:                                               ; preds = %68
  %74 = load ptr, ptr %5, align 8, !tbaa !5
  %75 = getelementptr inbounds %struct.facetT, ptr %74, i32 0, i32 5
  %76 = load ptr, ptr %75, align 8, !tbaa !26
  %77 = icmp ne ptr %76, null
  br i1 %77, label %128, label %78

78:                                               ; preds = %73
  %79 = load ptr, ptr %5, align 8, !tbaa !5
  %80 = getelementptr inbounds %struct.facetT, ptr %79, i32 0, i32 3
  %81 = load ptr, ptr %80, align 8, !tbaa !27
  %82 = load ptr, ptr %4, align 8, !tbaa !5
  %83 = getelementptr inbounds %struct.qhT, ptr %82, i32 0, i32 110
  %84 = load i32, ptr %83, align 8, !tbaa !28
  %85 = sub nsw i32 %84, 1
  %86 = sext i32 %85 to i64
  %87 = getelementptr inbounds double, ptr %81, i64 %86
  %88 = load double, ptr %87, align 8, !tbaa !29
  %89 = fcmp olt double %88, 0.000000e+00
  br i1 %89, label %90, label %102

90:                                               ; preds = %78
  %91 = load ptr, ptr %5, align 8, !tbaa !5
  %92 = getelementptr inbounds %struct.facetT, ptr %91, i32 0, i32 3
  %93 = load ptr, ptr %92, align 8, !tbaa !27
  %94 = load ptr, ptr %4, align 8, !tbaa !5
  %95 = getelementptr inbounds %struct.qhT, ptr %94, i32 0, i32 110
  %96 = load i32, ptr %95, align 8, !tbaa !28
  %97 = sub nsw i32 %96, 1
  %98 = sext i32 %97 to i64
  %99 = getelementptr inbounds double, ptr %93, i64 %98
  %100 = load double, ptr %99, align 8, !tbaa !29
  %101 = fneg double %100
  br label %113

102:                                              ; preds = %78
  %103 = load ptr, ptr %5, align 8, !tbaa !5
  %104 = getelementptr inbounds %struct.facetT, ptr %103, i32 0, i32 3
  %105 = load ptr, ptr %104, align 8, !tbaa !27
  %106 = load ptr, ptr %4, align 8, !tbaa !5
  %107 = getelementptr inbounds %struct.qhT, ptr %106, i32 0, i32 110
  %108 = load i32, ptr %107, align 8, !tbaa !28
  %109 = sub nsw i32 %108, 1
  %110 = sext i32 %109 to i64
  %111 = getelementptr inbounds double, ptr %105, i64 %110
  %112 = load double, ptr %111, align 8, !tbaa !29
  br label %113

113:                                              ; preds = %102, %90
  %114 = phi double [ %101, %90 ], [ %112, %102 ]
  %115 = load ptr, ptr %4, align 8, !tbaa !5
  %116 = getelementptr inbounds %struct.qhT, ptr %115, i32 0, i32 131
  %117 = load double, ptr %116, align 8, !tbaa !30
  %118 = fmul double %117, 2.000000e+00
  %119 = fcmp oge double %114, %118
  br i1 %119, label %120, label %128

120:                                              ; preds = %113
  %121 = load ptr, ptr %4, align 8, !tbaa !5
  %122 = load ptr, ptr %5, align 8, !tbaa !5
  %123 = getelementptr inbounds %struct.facetT, ptr %122, i32 0, i32 8
  %124 = load ptr, ptr %123, align 8, !tbaa !31
  %125 = call ptr @qh_facetcenter(ptr noundef %121, ptr noundef %124)
  %126 = load ptr, ptr %5, align 8, !tbaa !5
  %127 = getelementptr inbounds %struct.facetT, ptr %126, i32 0, i32 5
  store ptr %125, ptr %127, align 8, !tbaa !26
  br label %128

128:                                              ; preds = %120, %113, %73, %68
  %129 = load ptr, ptr %4, align 8, !tbaa !5
  %130 = getelementptr inbounds %struct.qhT, ptr %129, i32 0, i32 164
  %131 = load ptr, ptr %130, align 8, !tbaa !32
  %132 = load ptr, ptr %4, align 8, !tbaa !5
  %133 = getelementptr inbounds %struct.qhT, ptr %132, i32 0, i32 166
  store ptr %131, ptr %133, align 8, !tbaa !33
  %134 = load ptr, ptr %4, align 8, !tbaa !5
  %135 = getelementptr inbounds %struct.qhT, ptr %134, i32 0, i32 167
  store ptr %131, ptr %135, align 8, !tbaa !34
  %136 = load ptr, ptr %4, align 8, !tbaa !5
  %137 = getelementptr inbounds %struct.qhT, ptr %136, i32 0, i32 217
  %138 = load i32, ptr %137, align 8, !tbaa !35
  %139 = load ptr, ptr %5, align 8, !tbaa !5
  %140 = getelementptr inbounds %struct.facetT, ptr %139, i32 0, i32 13
  store i32 %138, ptr %140, align 8, !tbaa !36
  %141 = load ptr, ptr %5, align 8, !tbaa !5
  %142 = getelementptr inbounds %struct.facetT, ptr %141, i32 0, i32 8
  %143 = load ptr, ptr %142, align 8, !tbaa !31
  %144 = getelementptr inbounds %struct.setT, ptr %143, i32 0, i32 1
  %145 = getelementptr inbounds [1 x %union.setelemT], ptr %144, i64 0, i64 0
  %146 = load ptr, ptr %145, align 8, !tbaa !37
  store ptr %146, ptr %10, align 8, !tbaa !5
  %147 = load ptr, ptr %4, align 8, !tbaa !5
  %148 = load ptr, ptr %5, align 8, !tbaa !5
  %149 = load ptr, ptr %10, align 8, !tbaa !5
  %150 = call ptr @qh_makenew_nonsimplicial(ptr noundef %147, ptr noundef %148, ptr noundef %149, ptr noundef %11)
  %151 = load ptr, ptr %4, align 8, !tbaa !5
  %152 = load ptr, ptr %5, align 8, !tbaa !5
  call void @qh_willdelete(ptr noundef %151, ptr noundef %152, ptr noundef null)
  %153 = load ptr, ptr %4, align 8, !tbaa !5
  %154 = getelementptr inbounds %struct.qhT, ptr %153, i32 0, i32 166
  %155 = load ptr, ptr %154, align 8, !tbaa !33
  store ptr %155, ptr %7, align 8, !tbaa !5
  br label %156

156:                                              ; preds = %304, %128
  %157 = load ptr, ptr %7, align 8, !tbaa !5
  %158 = icmp ne ptr %157, null
  br i1 %158, label %159, label %164

159:                                              ; preds = %156
  %160 = load ptr, ptr %7, align 8, !tbaa !5
  %161 = getelementptr inbounds %struct.facetT, ptr %160, i32 0, i32 7
  %162 = load ptr, ptr %161, align 8, !tbaa !38
  %163 = icmp ne ptr %162, null
  br label %164

164:                                              ; preds = %159, %156
  %165 = phi i1 [ false, %156 ], [ %163, %159 ]
  br i1 %165, label %166, label %308

166:                                              ; preds = %164
  %167 = load ptr, ptr %7, align 8, !tbaa !5
  %168 = getelementptr inbounds %struct.facetT, ptr %167, i32 0, i32 15
  %169 = load i32, ptr %168, align 8
  %170 = and i32 %169, -513
  %171 = or i32 %170, 512
  store i32 %171, ptr %168, align 8
  %172 = load ptr, ptr %5, align 8, !tbaa !5
  %173 = load ptr, ptr %7, align 8, !tbaa !5
  %174 = getelementptr inbounds %struct.facetT, ptr %173, i32 0, i32 4
  store ptr %172, ptr %174, align 8, !tbaa !37
  %175 = load ptr, ptr %7, align 8, !tbaa !5
  %176 = getelementptr inbounds %struct.facetT, ptr %175, i32 0, i32 15
  %177 = load i32, ptr %176, align 8
  %178 = and i32 %177, -1073741825
  %179 = or i32 %178, 0
  store i32 %179, ptr %176, align 8
  %180 = load ptr, ptr %5, align 8, !tbaa !5
  %181 = getelementptr inbounds %struct.facetT, ptr %180, i32 0, i32 15
  %182 = load i32, ptr %181, align 8
  %183 = lshr i32 %182, 17
  %184 = and i32 %183, 1
  %185 = load ptr, ptr %7, align 8, !tbaa !5
  %186 = getelementptr inbounds %struct.facetT, ptr %185, i32 0, i32 15
  %187 = load i32, ptr %186, align 8
  %188 = and i32 %184, 1
  %189 = shl i32 %188, 17
  %190 = and i32 %187, -131073
  %191 = or i32 %190, %189
  store i32 %191, ptr %186, align 8
  %192 = load ptr, ptr %5, align 8, !tbaa !5
  %193 = getelementptr inbounds %struct.facetT, ptr %192, i32 0, i32 15
  %194 = load i32, ptr %193, align 8
  %195 = lshr i32 %194, 19
  %196 = and i32 %195, 1
  %197 = load ptr, ptr %7, align 8, !tbaa !5
  %198 = getelementptr inbounds %struct.facetT, ptr %197, i32 0, i32 15
  %199 = load i32, ptr %198, align 8
  %200 = and i32 %196, 1
  %201 = shl i32 %200, 19
  %202 = and i32 %199, -524289
  %203 = or i32 %202, %201
  store i32 %203, ptr %198, align 8
  %204 = load ptr, ptr %4, align 8, !tbaa !5
  %205 = getelementptr inbounds %struct.qhT, ptr %204, i32 0, i32 98
  %206 = load i32, ptr %205, align 8, !tbaa !39
  %207 = icmp ne i32 %206, 0
  br i1 %207, label %208, label %277

208:                                              ; preds = %166
  %209 = load ptr, ptr %7, align 8, !tbaa !5
  %210 = getelementptr inbounds %struct.facetT, ptr %209, i32 0, i32 15
  %211 = load i32, ptr %210, align 8
  %212 = and i32 %211, -268435457
  %213 = or i32 %212, 268435456
  store i32 %213, ptr %210, align 8
  %214 = load ptr, ptr %5, align 8, !tbaa !5
  %215 = getelementptr inbounds %struct.facetT, ptr %214, i32 0, i32 3
  %216 = load ptr, ptr %215, align 8, !tbaa !27
  %217 = icmp ne ptr %216, null
  br i1 %217, label %218, label %236

218:                                              ; preds = %208
  %219 = load ptr, ptr %4, align 8, !tbaa !5
  %220 = load ptr, ptr %4, align 8, !tbaa !5
  %221 = getelementptr inbounds %struct.qhT, ptr %220, i32 0, i32 160
  %222 = load i32, ptr %221, align 8, !tbaa !40
  %223 = call ptr @qh_memalloc(ptr noundef %219, i32 noundef %222)
  %224 = load ptr, ptr %7, align 8, !tbaa !5
  %225 = getelementptr inbounds %struct.facetT, ptr %224, i32 0, i32 3
  store ptr %223, ptr %225, align 8, !tbaa !27
  %226 = load ptr, ptr %7, align 8, !tbaa !5
  %227 = getelementptr inbounds %struct.facetT, ptr %226, i32 0, i32 3
  %228 = load ptr, ptr %227, align 8, !tbaa !27
  %229 = load ptr, ptr %5, align 8, !tbaa !5
  %230 = getelementptr inbounds %struct.facetT, ptr %229, i32 0, i32 3
  %231 = load ptr, ptr %230, align 8, !tbaa !27
  %232 = load ptr, ptr %4, align 8, !tbaa !5
  %233 = getelementptr inbounds %struct.qhT, ptr %232, i32 0, i32 160
  %234 = load i32, ptr %233, align 8, !tbaa !40
  %235 = sext i32 %234 to i64
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 %228, ptr align 8 %231, i64 %235, i1 false)
  br label %236

236:                                              ; preds = %218, %208
  %237 = load ptr, ptr %4, align 8, !tbaa !5
  %238 = getelementptr inbounds %struct.qhT, ptr %237, i32 0, i32 189
  %239 = load i32, ptr %238, align 8, !tbaa !25
  %240 = icmp eq i32 %239, 2
  br i1 %240, label %241, label %247

241:                                              ; preds = %236
  %242 = load ptr, ptr %4, align 8, !tbaa !5
  %243 = load ptr, ptr %7, align 8, !tbaa !5
  %244 = call ptr @qh_getcentrum(ptr noundef %242, ptr noundef %243)
  %245 = load ptr, ptr %7, align 8, !tbaa !5
  %246 = getelementptr inbounds %struct.facetT, ptr %245, i32 0, i32 5
  store ptr %244, ptr %246, align 8, !tbaa !26
  br label %276

247:                                              ; preds = %236
  %248 = load ptr, ptr %4, align 8, !tbaa !5
  %249 = getelementptr inbounds %struct.qhT, ptr %248, i32 0, i32 189
  %250 = load i32, ptr %249, align 8, !tbaa !25
  %251 = icmp eq i32 %250, 1
  br i1 %251, label %252, label %275

252:                                              ; preds = %247
  %253 = load ptr, ptr %5, align 8, !tbaa !5
  %254 = getelementptr inbounds %struct.facetT, ptr %253, i32 0, i32 5
  %255 = load ptr, ptr %254, align 8, !tbaa !26
  %256 = icmp ne ptr %255, null
  br i1 %256, label %257, label %275

257:                                              ; preds = %252
  %258 = load ptr, ptr %4, align 8, !tbaa !5
  %259 = load ptr, ptr %4, align 8, !tbaa !5
  %260 = getelementptr inbounds %struct.qhT, ptr %259, i32 0, i32 161
  %261 = load i32, ptr %260, align 4, !tbaa !41
  %262 = call ptr @qh_memalloc(ptr noundef %258, i32 noundef %261)
  %263 = load ptr, ptr %7, align 8, !tbaa !5
  %264 = getelementptr inbounds %struct.facetT, ptr %263, i32 0, i32 5
  store ptr %262, ptr %264, align 8, !tbaa !26
  %265 = load ptr, ptr %7, align 8, !tbaa !5
  %266 = getelementptr inbounds %struct.facetT, ptr %265, i32 0, i32 5
  %267 = load ptr, ptr %266, align 8, !tbaa !26
  %268 = load ptr, ptr %5, align 8, !tbaa !5
  %269 = getelementptr inbounds %struct.facetT, ptr %268, i32 0, i32 5
  %270 = load ptr, ptr %269, align 8, !tbaa !26
  %271 = load ptr, ptr %4, align 8, !tbaa !5
  %272 = getelementptr inbounds %struct.qhT, ptr %271, i32 0, i32 161
  %273 = load i32, ptr %272, align 4, !tbaa !41
  %274 = sext i32 %273 to i64
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 %267, ptr align 8 %270, i64 %274, i1 false)
  br label %275

275:                                              ; preds = %257, %252, %247
  br label %276

276:                                              ; preds = %275, %241
  br label %293

277:                                              ; preds = %166
  %278 = load ptr, ptr %7, align 8, !tbaa !5
  %279 = getelementptr inbounds %struct.facetT, ptr %278, i32 0, i32 15
  %280 = load i32, ptr %279, align 8
  %281 = and i32 %280, -268435457
  %282 = or i32 %281, 0
  store i32 %282, ptr %279, align 8
  %283 = load ptr, ptr %5, align 8, !tbaa !5
  %284 = getelementptr inbounds %struct.facetT, ptr %283, i32 0, i32 3
  %285 = load ptr, ptr %284, align 8, !tbaa !27
  %286 = load ptr, ptr %7, align 8, !tbaa !5
  %287 = getelementptr inbounds %struct.facetT, ptr %286, i32 0, i32 3
  store ptr %285, ptr %287, align 8, !tbaa !27
  %288 = load ptr, ptr %5, align 8, !tbaa !5
  %289 = getelementptr inbounds %struct.facetT, ptr %288, i32 0, i32 5
  %290 = load ptr, ptr %289, align 8, !tbaa !26
  %291 = load ptr, ptr %7, align 8, !tbaa !5
  %292 = getelementptr inbounds %struct.facetT, ptr %291, i32 0, i32 5
  store ptr %290, ptr %292, align 8, !tbaa !26
  br label %293

293:                                              ; preds = %277, %276
  %294 = load ptr, ptr %5, align 8, !tbaa !5
  %295 = getelementptr inbounds %struct.facetT, ptr %294, i32 0, i32 2
  %296 = load double, ptr %295, align 8, !tbaa !42
  %297 = load ptr, ptr %7, align 8, !tbaa !5
  %298 = getelementptr inbounds %struct.facetT, ptr %297, i32 0, i32 2
  store double %296, ptr %298, align 8, !tbaa !42
  %299 = load ptr, ptr %5, align 8, !tbaa !5
  %300 = getelementptr inbounds %struct.facetT, ptr %299, i32 0, i32 1
  %301 = load double, ptr %300, align 8, !tbaa !43
  %302 = load ptr, ptr %7, align 8, !tbaa !5
  %303 = getelementptr inbounds %struct.facetT, ptr %302, i32 0, i32 1
  store double %301, ptr %303, align 8, !tbaa !43
  br label %304

304:                                              ; preds = %293
  %305 = load ptr, ptr %7, align 8, !tbaa !5
  %306 = getelementptr inbounds %struct.facetT, ptr %305, i32 0, i32 7
  %307 = load ptr, ptr %306, align 8, !tbaa !38
  store ptr %307, ptr %7, align 8, !tbaa !5
  br label %156, !llvm.loop !44

308:                                              ; preds = %164
  %309 = load ptr, ptr %4, align 8, !tbaa !5
  %310 = call double @qh_matchnewfacets(ptr noundef %309)
  %311 = load ptr, ptr %4, align 8, !tbaa !5
  %312 = getelementptr inbounds %struct.qhT, ptr %311, i32 0, i32 258
  %313 = getelementptr inbounds %struct.qhstatT, ptr %312, i32 0, i32 0
  %314 = getelementptr inbounds [249 x %union.intrealT], ptr %313, i64 0, i64 222
  %315 = load i32, ptr %314, align 8, !tbaa !37
  %316 = add nsw i32 %315, 1
  store i32 %316, ptr %314, align 8, !tbaa !37
  %317 = load i32, ptr %11, align 4, !tbaa !9
  %318 = load ptr, ptr %4, align 8, !tbaa !5
  %319 = getelementptr inbounds %struct.qhT, ptr %318, i32 0, i32 258
  %320 = getelementptr inbounds %struct.qhstatT, ptr %319, i32 0, i32 0
  %321 = getelementptr inbounds [249 x %union.intrealT], ptr %320, i64 0, i64 224
  %322 = load i32, ptr %321, align 8, !tbaa !37
  %323 = add nsw i32 %322, %317
  store i32 %323, ptr %321, align 8, !tbaa !37
  %324 = load ptr, ptr %4, align 8, !tbaa !5
  %325 = getelementptr inbounds %struct.qhT, ptr %324, i32 0, i32 258
  %326 = getelementptr inbounds %struct.qhstatT, ptr %325, i32 0, i32 0
  %327 = getelementptr inbounds [249 x %union.intrealT], ptr %326, i64 0, i64 223
  %328 = load i32, ptr %327, align 8, !tbaa !37
  %329 = load i32, ptr %11, align 4, !tbaa !9
  %330 = icmp slt i32 %328, %329
  br i1 %330, label %331, label %337

331:                                              ; preds = %308
  %332 = load i32, ptr %11, align 4, !tbaa !9
  %333 = load ptr, ptr %4, align 8, !tbaa !5
  %334 = getelementptr inbounds %struct.qhT, ptr %333, i32 0, i32 258
  %335 = getelementptr inbounds %struct.qhstatT, ptr %334, i32 0, i32 0
  %336 = getelementptr inbounds [249 x %union.intrealT], ptr %335, i64 0, i64 223
  store i32 %332, ptr %336, align 8, !tbaa !37
  br label %337

337:                                              ; preds = %331, %308
  %338 = load ptr, ptr %6, align 8, !tbaa !5
  %339 = load ptr, ptr %338, align 8, !tbaa !5
  %340 = icmp ne ptr %339, null
  br i1 %340, label %346, label %341

341:                                              ; preds = %337
  %342 = load ptr, ptr %4, align 8, !tbaa !5
  %343 = getelementptr inbounds %struct.qhT, ptr %342, i32 0, i32 177
  %344 = load ptr, ptr %343, align 8, !tbaa !45
  %345 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %344, ptr %345, align 8, !tbaa !5
  br label %346

346:                                              ; preds = %341, %337
  %347 = load ptr, ptr %4, align 8, !tbaa !5
  %348 = getelementptr inbounds %struct.qhT, ptr %347, i32 0, i32 177
  store ptr null, ptr %348, align 8, !tbaa !45
  %349 = load ptr, ptr %4, align 8, !tbaa !5
  %350 = getelementptr inbounds %struct.qhT, ptr %349, i32 0, i32 167
  store ptr null, ptr %350, align 8, !tbaa !34
  %351 = load ptr, ptr %4, align 8, !tbaa !5
  call void @qh_update_vertexneighbors(ptr noundef %351)
  %352 = load ptr, ptr %4, align 8, !tbaa !5
  call void @qh_resetlists(ptr noundef %352, i32 noundef 0, i32 noundef 0)
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #4
  ret void
}

declare void @qh_update_vertexneighbors(ptr noundef) #1

declare void @qh_printfacet(ptr noundef, ptr noundef, ptr noundef) #1

declare void @qh_willdelete(ptr noundef, ptr noundef, ptr noundef) #1

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #3

declare double @qh_matchnewfacets(ptr noundef) #1

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 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { 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, !10, i64 2984, !10, i64 2988, !7, i64 2992, !7, i64 3192, !10, i64 3232, !13, i64 3240, !6, i64 3248, !6, i64 3256, !6, i64 3264, !15, i64 3272, !16, i64 3424}
!13 = !{!"double", !7, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = !{!"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}
!16 = !{!"qhstatT", !7, i64 0, !7, i64 1992, !7, i64 2256, !7, i64 4248, !7, i64 4746, !7, i64 4995, !7, i64 5248, !10, i64 5320, !10, i64 5324, !10, i64 5328, !10, i64 5332, !13, i64 5336}
!17 = !{!12, !6, i64 2424}
!18 = !{!19, !10, i64 108}
!19 = !{!"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}
!20 = !{!12, !10, i64 2584}
!21 = !{!12, !10, i64 2596}
!22 = !{!19, !6, i64 80}
!23 = distinct !{!23, !24}
!24 = !{!"llvm.loop.mustprogress"}
!25 = !{!12, !10, i64 2616}
!26 = !{!19, !6, i64 40}
!27 = !{!19, !6, i64 24}
!28 = !{!12, !10, i64 632}
!29 = !{!13, !13, i64 0}
!30 = !{!12, !13, i64 1760}
!31 = !{!19, !6, i64 64}
!32 = !{!12, !6, i64 2464}
!33 = !{!12, !6, i64 2480}
!34 = !{!12, !6, i64 2488}
!35 = !{!12, !10, i64 2784}
!36 = !{!19, !10, i64 104}
!37 = !{!7, !7, i64 0}
!38 = !{!19, !6, i64 56}
!39 = !{!12, !10, i64 568}
!40 = !{!12, !10, i64 2440}
!41 = !{!12, !10, i64 2444}
!42 = !{!19, !13, i64 16}
!43 = !{!19, !13, i64 8}
!44 = distinct !{!44, !24}
!45 = !{!12, !6, i64 2560}


; 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.223 = external hidden unnamed_addr constant [45 x i8], align 1

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

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

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

declare ptr @qh_getcentrum(ptr noundef, ptr noundef) local_unnamed_addr #1

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

declare ptr @qh_makenew_nonsimplicial(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

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

declare ptr @qh_facetcenter(ptr noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
define dso_local void @qh_triangulate_facet(ptr noundef %0, ptr noundef %1, ptr nocapture noundef %2) local_unnamed_addr #2 {
  %4 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #4
  store i32 0, ptr %4, align 4, !tbaa !5
  %5 = getelementptr inbounds i8, ptr %0, i64 136
  %6 = load i32, ptr %5, align 8, !tbaa !9
  %7 = icmp sgt i32 %6, 2
  br i1 %7, label %11, label %.thread

.thread:                                          ; preds = %3
  %8 = getelementptr inbounds i8, ptr %0, i64 2584
  %9 = load i32, ptr %8, align 8, !tbaa !16
  %10 = getelementptr inbounds i8, ptr %0, i64 2596
  store i32 %9, ptr %10, align 4, !tbaa !17
  br label %22

11:                                               ; preds = %3
  %12 = getelementptr inbounds i8, ptr %0, i64 2424
  %13 = load ptr, ptr %12, align 8, !tbaa !18
  %14 = getelementptr inbounds i8, ptr %1, i64 108
  %15 = load i32, ptr %14, align 4, !tbaa !19
  tail call void (ptr, ptr, i32, ptr, ...) @qh_fprintf(ptr noundef nonnull %0, ptr noundef %13, i32 noundef 3020, ptr noundef nonnull @.str.223, i32 noundef %15) #4
  %.pr = load i32, ptr %5, align 8, !tbaa !9
  %16 = getelementptr inbounds i8, ptr %0, i64 2584
  %17 = load i32, ptr %16, align 8, !tbaa !16
  %18 = getelementptr inbounds i8, ptr %0, i64 2596
  store i32 %17, ptr %18, align 4, !tbaa !17
  %19 = icmp sgt i32 %.pr, 3
  br i1 %19, label %20, label %22

20:                                               ; preds = %11
  %21 = load ptr, ptr %12, align 8, !tbaa !18
  tail call void @qh_printfacet(ptr noundef nonnull %0, ptr noundef %21, ptr noundef nonnull %1) #4
  br label %22

22:                                               ; preds = %.thread, %20, %11
  %23 = getelementptr inbounds i8, ptr %1, i64 80
  %24 = load ptr, ptr %23, align 8, !tbaa !21
  %.not = icmp eq ptr %24, null
  br i1 %.not, label %.loopexit, label %.preheader

.preheader:                                       ; preds = %22
  %.092106 = getelementptr inbounds i8, ptr %24, i64 8
  %25 = load ptr, ptr %.092106, align 8, !tbaa !22
  %.not98107 = icmp eq ptr %25, null
  br i1 %.not98107, label %.loopexit, label %.lr.ph

.lr.ph:                                           ; preds = %.preheader, %.lr.ph
  %26 = phi ptr [ %30, %.lr.ph ], [ %25, %.preheader ]
  %.092108 = phi ptr [ %.092, %.lr.ph ], [ %.092106, %.preheader ]
  %27 = getelementptr inbounds i8, ptr %26, i64 112
  %28 = load i32, ptr %27, align 8
  %29 = and i32 %28, -16793601
  store i32 %29, ptr %27, align 8
  %.092 = getelementptr inbounds i8, ptr %.092108, i64 8
  %30 = load ptr, ptr %.092, align 8, !tbaa !22
  %.not98 = icmp eq ptr %30, null
  br i1 %.not98, label %.loopexit, label %.lr.ph, !llvm.loop !23

.loopexit:                                        ; preds = %.lr.ph, %.preheader, %22
  %31 = getelementptr inbounds i8, ptr %0, i64 2616
  %32 = load i32, ptr %31, align 8, !tbaa !25
  %33 = icmp eq i32 %32, 1
  br i1 %33, label %34, label %57

34:                                               ; preds = %.loopexit
  %35 = getelementptr inbounds i8, ptr %1, i64 40
  %36 = load ptr, ptr %35, align 8, !tbaa !26
  %.not99 = icmp eq ptr %36, null
  br i1 %.not99, label %37, label %57

37:                                               ; preds = %34
  %38 = getelementptr inbounds i8, ptr %1, i64 24
  %39 = load ptr, ptr %38, align 8, !tbaa !27
  %40 = getelementptr inbounds i8, ptr %0, i64 632
  %41 = load i32, ptr %40, align 8, !tbaa !28
  %42 = sext i32 %41 to i64
  %43 = getelementptr double, ptr %39, i64 %42
  %44 = getelementptr i8, ptr %43, i64 -8
  %45 = load double, ptr %44, align 8, !tbaa !29
  %46 = fcmp olt double %45, 0.000000e+00
  %47 = fneg double %45
  %48 = select i1 %46, double %47, double %45
  %49 = getelementptr inbounds i8, ptr %0, i64 1760
  %50 = load double, ptr %49, align 8, !tbaa !30
  %51 = fmul double %50, 2.000000e+00
  %52 = fcmp ult double %48, %51
  br i1 %52, label %57, label %53

53:                                               ; preds = %37
  %54 = getelementptr inbounds i8, ptr %1, i64 64
  %55 = load ptr, ptr %54, align 8, !tbaa !31
  %56 = tail call ptr @qh_facetcenter(ptr noundef nonnull %0, ptr noundef %55) #4
  store ptr %56, ptr %35, align 8, !tbaa !26
  br label %57

57:                                               ; preds = %53, %37, %34, %.loopexit
  %58 = getelementptr inbounds i8, ptr %0, i64 2464
  %59 = load ptr, ptr %58, align 8, !tbaa !32
  %60 = getelementptr inbounds i8, ptr %0, i64 2480
  store ptr %59, ptr %60, align 8, !tbaa !33
  %61 = getelementptr inbounds i8, ptr %0, i64 2488
  store ptr %59, ptr %61, align 8, !tbaa !34
  %62 = getelementptr inbounds i8, ptr %0, i64 2784
  %63 = load i32, ptr %62, align 8, !tbaa !35
  %64 = getelementptr inbounds i8, ptr %1, i64 104
  store i32 %63, ptr %64, align 8, !tbaa !36
  %65 = getelementptr inbounds i8, ptr %1, i64 64
  %66 = load ptr, ptr %65, align 8, !tbaa !31
  %67 = getelementptr inbounds i8, ptr %66, i64 8
  %68 = load ptr, ptr %67, align 8, !tbaa !37
  %69 = call ptr @qh_makenew_nonsimplicial(ptr noundef nonnull %0, ptr noundef %1, ptr noundef %68, ptr noundef nonnull %4) #4
  call void @qh_willdelete(ptr noundef nonnull %0, ptr noundef %1, ptr noundef null) #4
  %.0109 = load ptr, ptr %60, align 8, !tbaa !22
  %.not100110 = icmp eq ptr %.0109, null
  br i1 %.not100110, label %.critedge, label %.lr.ph112

.lr.ph112:                                        ; preds = %57
  %70 = getelementptr inbounds i8, ptr %1, i64 112
  %71 = getelementptr inbounds i8, ptr %0, i64 568
  %72 = getelementptr inbounds i8, ptr %1, i64 24
  %73 = getelementptr inbounds i8, ptr %0, i64 2440
  %74 = getelementptr inbounds i8, ptr %1, i64 40
  %75 = getelementptr inbounds i8, ptr %0, i64 2444
  %76 = getelementptr inbounds i8, ptr %1, i64 8
  br label %77

77:                                               ; preds = %.lr.ph112, %125
  %.0111 = phi ptr [ %.0109, %.lr.ph112 ], [ %.0, %125 ]
  %78 = getelementptr inbounds i8, ptr %.0111, i64 56
  %79 = load ptr, ptr %78, align 8, !tbaa !38
  %.not101 = icmp eq ptr %79, null
  br i1 %.not101, label %.critedge, label %80

80:                                               ; preds = %77
  %81 = getelementptr inbounds i8, ptr %.0111, i64 112
  %82 = load i32, ptr %81, align 8
  %83 = or i32 %82, 512
  %84 = getelementptr inbounds i8, ptr %.0111, i64 32
  store ptr %1, ptr %84, align 8, !tbaa !37
  %85 = and i32 %83, -1073741825
  store i32 %85, ptr %81, align 8
  %86 = load i32, ptr %70, align 8
  %87 = and i32 %86, 131072
  %88 = and i32 %83, -1073872897
  %89 = or disjoint i32 %87, %88
  store i32 %89, ptr %81, align 8
  %90 = load i32, ptr %70, align 8
  %91 = and i32 %90, 524288
  %92 = and i32 %89, -1074266113
  %93 = or disjoint i32 %92, %91
  store i32 %93, ptr %81, align 8
  %94 = load i32, ptr %71, align 8, !tbaa !39
  %.not103 = icmp eq i32 %94, 0
  br i1 %.not103, label %119, label %95

95:                                               ; preds = %80
  %96 = or i32 %93, 268435456
  store i32 %96, ptr %81, align 8
  %97 = load ptr, ptr %72, align 8, !tbaa !27
  %.not104 = icmp eq ptr %97, null
  br i1 %.not104, label %105, label %98

98:                                               ; preds = %95
  %99 = load i32, ptr %73, align 8, !tbaa !40
  %100 = call ptr @qh_memalloc(ptr noundef nonnull %0, i32 noundef %99) #4
  %101 = getelementptr inbounds i8, ptr %.0111, i64 24
  store ptr %100, ptr %101, align 8, !tbaa !27
  %102 = load ptr, ptr %72, align 8, !tbaa !27
  %103 = load i32, ptr %73, align 8, !tbaa !40
  %104 = sext i32 %103 to i64
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 %100, ptr align 8 %102, i64 %104, i1 false)
  br label %105

105:                                              ; preds = %98, %95
  %106 = load i32, ptr %31, align 8, !tbaa !25
  switch i32 %106, label %125 [
    i32 2, label %107
    i32 1, label %110
  ]

107:                                              ; preds = %105
  %108 = call ptr @qh_getcentrum(ptr noundef nonnull %0, ptr noundef nonnull %.0111) #4
  %109 = getelementptr inbounds i8, ptr %.0111, i64 40
  store ptr %108, ptr %109, align 8, !tbaa !26
  br label %125

110:                                              ; preds = %105
  %111 = load ptr, ptr %74, align 8, !tbaa !26
  %.not105 = icmp eq ptr %111, null
  br i1 %.not105, label %125, label %112

112:                                              ; preds = %110
  %113 = load i32, ptr %75, align 4, !tbaa !41
  %114 = call ptr @qh_memalloc(ptr noundef nonnull %0, i32 noundef %113) #4
  %115 = getelementptr inbounds i8, ptr %.0111, i64 40
  store ptr %114, ptr %115, align 8, !tbaa !26
  %116 = load ptr, ptr %74, align 8, !tbaa !26
  %117 = load i32, ptr %75, align 4, !tbaa !41
  %118 = sext i32 %117 to i64
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 %114, ptr align 8 %116, i64 %118, i1 false)
  br label %125

119:                                              ; preds = %80
  %120 = and i32 %93, -1342177281
  store i32 %120, ptr %81, align 8
  %121 = load ptr, ptr %72, align 8, !tbaa !27
  %122 = getelementptr inbounds i8, ptr %.0111, i64 24
  store ptr %121, ptr %122, align 8, !tbaa !27
  %123 = load ptr, ptr %74, align 8, !tbaa !26
  %124 = getelementptr inbounds i8, ptr %.0111, i64 40
  store ptr %123, ptr %124, align 8, !tbaa !26
  br label %125

125:                                              ; preds = %105, %107, %112, %110, %119
  %126 = getelementptr inbounds i8, ptr %.0111, i64 8
  %127 = load <2 x double>, ptr %76, align 8, !tbaa !29
  store <2 x double> %127, ptr %126, align 8, !tbaa !29
  %.0 = load ptr, ptr %78, align 8, !tbaa !22
  %.not100 = icmp eq ptr %.0, null
  br i1 %.not100, label %.critedge, label %77, !llvm.loop !42

.critedge:                                        ; preds = %77, %125, %57
  %128 = call double @qh_matchnewfacets(ptr noundef nonnull %0) #4
  %129 = getelementptr inbounds i8, ptr %0, i64 5200
  %130 = load i32, ptr %129, align 8, !tbaa !37
  %131 = add nsw i32 %130, 1
  store i32 %131, ptr %129, align 8, !tbaa !37
  %132 = load i32, ptr %4, align 4, !tbaa !5
  %133 = getelementptr inbounds i8, ptr %0, i64 5216
  %134 = load i32, ptr %133, align 8, !tbaa !37
  %135 = add nsw i32 %134, %132
  store i32 %135, ptr %133, align 8, !tbaa !37
  %136 = getelementptr inbounds i8, ptr %0, i64 5208
  %137 = load i32, ptr %136, align 8, !tbaa !37
  %138 = icmp slt i32 %137, %132
  br i1 %138, label %139, label %140

139:                                              ; preds = %.critedge
  store i32 %132, ptr %136, align 8, !tbaa !37
  br label %140

140:                                              ; preds = %139, %.critedge
  %141 = load ptr, ptr %2, align 8, !tbaa !22
  %.not102 = icmp eq ptr %141, null
  br i1 %.not102, label %142, label %145

142:                                              ; preds = %140
  %143 = getelementptr inbounds i8, ptr %0, i64 2560
  %144 = load ptr, ptr %143, align 8, !tbaa !43
  store ptr %144, ptr %2, align 8, !tbaa !22
  br label %145

145:                                              ; preds = %142, %140
  %146 = getelementptr inbounds i8, ptr %0, i64 2560
  store ptr null, ptr %146, align 8, !tbaa !43
  store ptr null, ptr %61, align 8, !tbaa !34
  call void @qh_update_vertexneighbors(ptr noundef nonnull %0) #4
  call void @qh_resetlists(ptr noundef nonnull %0, i32 noundef 0, i32 noundef 0)
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #4
  ret void
}

declare void @qh_update_vertexneighbors(ptr noundef) local_unnamed_addr #1

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

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

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #3

declare double @qh_matchnewfacets(ptr noundef) local_unnamed_addr #1

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


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