; LLVM IR from Discngine/fpocket :: src/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, double, i32, i32, i32, i32, i32, i32, i32, double, double, i32, i32, i32, i32, i32, ptr, i32, i32, ptr, i32, i32, i32, i32, i32, i32, i32, double, double, i32, i32, i32, double, double, i32, double, i32, 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, i32, double, double, double, 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, i32, ptr, double, double, double, double, [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, ptr, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i64, i32, i32, i32, i32, ptr, i32, i32, double, i32, double, double, double, i32, i32, i32, i32, double, double, i32, i32, i32, i32, double, double, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, ptr, ptr, i32, i32, i32, ptr, double, double, double, 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.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
@.str.87 = external hidden unnamed_addr constant [62 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: 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 void @qh_makeridges(ptr noundef) #2

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

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

68:                                               ; preds = %2
  %69 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %69, ptr %9, align 8, !tbaa !5
  %70 = load ptr, ptr %8, align 8, !tbaa !5
  store ptr %70, ptr %10, align 8, !tbaa !5
  %71 = load ptr, ptr %13, align 8, !tbaa !5
  store ptr %71, ptr %15, align 8, !tbaa !5
  %72 = load ptr, ptr %11, align 8, !tbaa !5
  store ptr %72, ptr %16, align 8, !tbaa !5
  br label %98

73:                                               ; preds = %2
  %74 = load ptr, ptr %5, align 8, !tbaa !5
  %75 = load ptr, ptr %8, align 8, !tbaa !5
  %76 = icmp eq ptr %74, %75
  br i1 %76, label %77, label %82

77:                                               ; preds = %73
  %78 = load ptr, ptr %6, align 8, !tbaa !5
  store ptr %78, ptr %9, align 8, !tbaa !5
  %79 = load ptr, ptr %7, align 8, !tbaa !5
  store ptr %79, ptr %10, align 8, !tbaa !5
  %80 = load ptr, ptr %14, align 8, !tbaa !5
  store ptr %80, ptr %15, align 8, !tbaa !5
  %81 = load ptr, ptr %11, align 8, !tbaa !5
  store ptr %81, ptr %16, align 8, !tbaa !5
  br label %97

82:                                               ; preds = %73
  %83 = load ptr, ptr %6, align 8, !tbaa !5
  %84 = load ptr, ptr %7, align 8, !tbaa !5
  %85 = icmp eq ptr %83, %84
  br i1 %85, label %86, label %91

86:                                               ; preds = %82
  %87 = load ptr, ptr %5, align 8, !tbaa !5
  store ptr %87, ptr %9, align 8, !tbaa !5
  %88 = load ptr, ptr %8, align 8, !tbaa !5
  store ptr %88, ptr %10, align 8, !tbaa !5
  %89 = load ptr, ptr %13, align 8, !tbaa !5
  store ptr %89, ptr %15, align 8, !tbaa !5
  %90 = load ptr, ptr %12, align 8, !tbaa !5
  store ptr %90, ptr %16, align 8, !tbaa !5
  br label %96

91:                                               ; preds = %82
  %92 = load ptr, ptr %5, align 8, !tbaa !5
  store ptr %92, ptr %9, align 8, !tbaa !5
  %93 = load ptr, ptr %7, align 8, !tbaa !5
  store ptr %93, ptr %10, align 8, !tbaa !5
  %94 = load ptr, ptr %14, align 8, !tbaa !5
  store ptr %94, ptr %15, align 8, !tbaa !5
  %95 = load ptr, ptr %12, align 8, !tbaa !5
  store ptr %95, ptr %16, align 8, !tbaa !5
  br label %96

96:                                               ; preds = %91, %86
  br label %97

97:                                               ; preds = %96, %77
  br label %98

98:                                               ; preds = %97, %68
  %99 = load ptr, ptr %9, align 8, !tbaa !5
  %100 = getelementptr inbounds %struct.vertexT, ptr %99, i32 0, i32 4
  %101 = load i32, ptr %100, align 8, !tbaa !15
  %102 = load ptr, ptr %10, align 8, !tbaa !5
  %103 = getelementptr inbounds %struct.vertexT, ptr %102, i32 0, i32 4
  %104 = load i32, ptr %103, align 8, !tbaa !15
  %105 = icmp ugt i32 %101, %104
  br i1 %105, label %106, label %151

106:                                              ; preds = %98
  %107 = load ptr, ptr %9, align 8, !tbaa !5
  %108 = load ptr, ptr %4, align 8, !tbaa !5
  %109 = getelementptr inbounds %struct.facetT, ptr %108, i32 0, i32 8
  %110 = load ptr, ptr %109, align 8, !tbaa !9
  %111 = getelementptr inbounds %struct.setT, ptr %110, i32 0, i32 1
  %112 = getelementptr inbounds [1 x %union.setelemT], ptr %111, i64 0, i64 0
  store ptr %107, ptr %112, align 8, !tbaa !13
  %113 = load ptr, ptr %10, align 8, !tbaa !5
  %114 = load ptr, ptr %4, align 8, !tbaa !5
  %115 = getelementptr inbounds %struct.facetT, ptr %114, i32 0, i32 8
  %116 = load ptr, ptr %115, align 8, !tbaa !9
  %117 = getelementptr inbounds %struct.setT, ptr %116, i32 0, i32 1
  %118 = getelementptr inbounds [1 x %union.setelemT], ptr %117, i64 0, i64 1
  store ptr %113, ptr %118, align 8, !tbaa !13
  %119 = load ptr, ptr %10, align 8, !tbaa !5
  %120 = load ptr, ptr %7, align 8, !tbaa !5
  %121 = icmp eq ptr %119, %120
  br i1 %121, label %122, label %138

122:                                              ; preds = %106
  %123 = load ptr, ptr %4, align 8, !tbaa !5
  %124 = getelementptr inbounds %struct.facetT, ptr %123, i32 0, i32 15
  %125 = load i32, ptr %124, align 8
  %126 = lshr i32 %125, 12
  %127 = and i32 %126, 1
  %128 = icmp ne i32 %127, 0
  %129 = xor i1 %128, true
  %130 = zext i1 %129 to i32
  %131 = load ptr, ptr %4, align 8, !tbaa !5
  %132 = getelementptr inbounds %struct.facetT, ptr %131, i32 0, i32 15
  %133 = load i32, ptr %132, align 8
  %134 = and i32 %130, 1
  %135 = shl i32 %134, 12
  %136 = and i32 %133, -4097
  %137 = or i32 %136, %135
  store i32 %137, ptr %132, align 8
  br label %138

138:                                              ; preds = %122, %106
  %139 = load ptr, ptr %15, align 8, !tbaa !5
  %140 = load ptr, ptr %4, align 8, !tbaa !5
  %141 = getelementptr inbounds %struct.facetT, ptr %140, i32 0, i32 10
  %142 = load ptr, ptr %141, align 8, !tbaa !14
  %143 = getelementptr inbounds %struct.setT, ptr %142, i32 0, i32 1
  %144 = getelementptr inbounds [1 x %union.setelemT], ptr %143, i64 0, i64 0
  store ptr %139, ptr %144, align 8, !tbaa !13
  %145 = load ptr, ptr %16, align 8, !tbaa !5
  %146 = load ptr, ptr %4, align 8, !tbaa !5
  %147 = getelementptr inbounds %struct.facetT, ptr %146, i32 0, i32 10
  %148 = load ptr, ptr %147, align 8, !tbaa !14
  %149 = getelementptr inbounds %struct.setT, ptr %148, i32 0, i32 1
  %150 = getelementptr inbounds [1 x %union.setelemT], ptr %149, i64 0, i64 1
  store ptr %145, ptr %150, align 8, !tbaa !13
  br label %196

151:                                              ; preds = %98
  %152 = load ptr, ptr %10, align 8, !tbaa !5
  %153 = load ptr, ptr %4, align 8, !tbaa !5
  %154 = getelementptr inbounds %struct.facetT, ptr %153, i32 0, i32 8
  %155 = load ptr, ptr %154, align 8, !tbaa !9
  %156 = getelementptr inbounds %struct.setT, ptr %155, i32 0, i32 1
  %157 = getelementptr inbounds [1 x %union.setelemT], ptr %156, i64 0, i64 0
  store ptr %152, ptr %157, align 8, !tbaa !13
  %158 = load ptr, ptr %9, align 8, !tbaa !5
  %159 = load ptr, ptr %4, align 8, !tbaa !5
  %160 = getelementptr inbounds %struct.facetT, ptr %159, i32 0, i32 8
  %161 = load ptr, ptr %160, align 8, !tbaa !9
  %162 = getelementptr inbounds %struct.setT, ptr %161, i32 0, i32 1
  %163 = getelementptr inbounds [1 x %union.setelemT], ptr %162, i64 0, i64 1
  store ptr %158, ptr %163, align 8, !tbaa !13
  %164 = load ptr, ptr %10, align 8, !tbaa !5
  %165 = load ptr, ptr %8, align 8, !tbaa !5
  %166 = icmp eq ptr %164, %165
  br i1 %166, label %167, label %183

167:                                              ; preds = %151
  %168 = load ptr, ptr %4, align 8, !tbaa !5
  %169 = getelementptr inbounds %struct.facetT, ptr %168, i32 0, i32 15
  %170 = load i32, ptr %169, align 8
  %171 = lshr i32 %170, 12
  %172 = and i32 %171, 1
  %173 = icmp ne i32 %172, 0
  %174 = xor i1 %173, true
  %175 = zext i1 %174 to i32
  %176 = load ptr, ptr %4, align 8, !tbaa !5
  %177 = getelementptr inbounds %struct.facetT, ptr %176, i32 0, i32 15
  %178 = load i32, ptr %177, align 8
  %179 = and i32 %175, 1
  %180 = shl i32 %179, 12
  %181 = and i32 %178, -4097
  %182 = or i32 %181, %180
  store i32 %182, ptr %177, align 8
  br label %183

183:                                              ; preds = %167, %151
  %184 = load ptr, ptr %16, align 8, !tbaa !5
  %185 = load ptr, ptr %4, align 8, !tbaa !5
  %186 = getelementptr inbounds %struct.facetT, ptr %185, i32 0, i32 10
  %187 = load ptr, ptr %186, align 8, !tbaa !14
  %188 = getelementptr inbounds %struct.setT, ptr %187, i32 0, i32 1
  %189 = getelementptr inbounds [1 x %union.setelemT], ptr %188, i64 0, i64 0
  store ptr %184, ptr %189, align 8, !tbaa !13
  %190 = load ptr, ptr %15, align 8, !tbaa !5
  %191 = load ptr, ptr %4, align 8, !tbaa !5
  %192 = getelementptr inbounds %struct.facetT, ptr %191, i32 0, i32 10
  %193 = load ptr, ptr %192, align 8, !tbaa !14
  %194 = getelementptr inbounds %struct.setT, ptr %193, i32 0, i32 1
  %195 = getelementptr inbounds [1 x %union.setelemT], ptr %194, i64 0, i64 1
  store ptr %190, ptr %195, align 8, !tbaa !13
  br label %196

196:                                              ; preds = %183, %138
  %197 = load ptr, ptr %16, align 8, !tbaa !5
  call void @qh_makeridges(ptr noundef %197)
  %198 = load ptr, ptr %16, align 8, !tbaa !5
  %199 = getelementptr inbounds %struct.facetT, ptr %198, i32 0, i32 10
  %200 = load ptr, ptr %199, align 8, !tbaa !14
  %201 = load ptr, ptr %3, align 8, !tbaa !5
  %202 = load ptr, ptr %4, align 8, !tbaa !5
  call void @qh_setreplace(ptr noundef %200, ptr noundef %201, ptr noundef %202)
  %203 = load i32, ptr getelementptr inbounds (%struct.qhT, ptr @qh_qh, i32 0, i32 24), align 8, !tbaa !17
  %204 = icmp sge i32 %203, 4
  br i1 %204, label %205, label %219

205:                                              ; preds = %196
  %206 = load ptr, ptr getelementptr inbounds (%struct.qhT, ptr @qh_qh, i32 0, i32 151), align 8, !tbaa !20
  %207 = load ptr, ptr %9, align 8, !tbaa !5
  %208 = getelementptr inbounds %struct.vertexT, ptr %207, i32 0, i32 4
  %209 = load i32, ptr %208, align 8, !tbaa !15
  %210 = load ptr, ptr %16, align 8, !tbaa !5
  %211 = getelementptr inbounds %struct.facetT, ptr %210, i32 0, i32 14
  %212 = load i32, ptr %211, align 4, !tbaa !21
  %213 = load ptr, ptr %3, align 8, !tbaa !5
  %214 = getelementptr inbounds %struct.facetT, ptr %213, i32 0, i32 14
  %215 = load i32, ptr %214, align 4, !tbaa !21
  %216 = load ptr, ptr %4, align 8, !tbaa !5
  %217 = getelementptr inbounds %struct.facetT, ptr %216, i32 0, i32 14
  %218 = load i32, ptr %217, align 4, !tbaa !21
  call void (ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %206, i32 noundef 4036, ptr noundef @.str.87, i32 noundef %209, i32 noundef %212, i32 noundef %215, i32 noundef %218)
  br label %219

219:                                              ; preds = %205, %196
  call void @llvm.lifetime.end.p0(i64 8, 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
}

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, !6, i64 64}
!10 = !{!"facetT", !11, i64 0, !11, i64 8, !11, 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, !12, i64 104, !12, i64 108, !12, i64 112, !12, i64 113, !12, i64 113, !12, i64 113, !12, i64 113, !12, i64 113, !12, i64 113, !12, i64 113, !12, i64 114, !12, i64 114, !12, i64 114, !12, i64 114, !12, i64 114, !12, i64 114, !12, i64 114, !12, i64 114, !12, i64 115, !12, i64 115, !12, i64 115, !12, i64 115, !12, i64 115, !12, i64 115, !12, i64 115, !12, i64 115}
!11 = !{!"double", !7, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!7, !7, i64 0}
!14 = !{!10, !6, i64 80}
!15 = !{!16, !12, i64 32}
!16 = !{!"vertexT", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !12, i64 32, !12, i64 36, !12, i64 40, !12, i64 40, !12, i64 40, !12, i64 40, !12, i64 40}
!17 = !{!18, !12, i64 128}
!18 = !{!"qhT", !12, i64 0, !12, i64 4, !12, i64 8, !11, i64 16, !12, i64 24, !12, i64 28, !12, i64 32, !12, i64 36, !12, i64 40, !12, i64 44, !12, i64 48, !11, i64 56, !11, i64 64, !12, i64 72, !12, i64 76, !12, i64 80, !12, i64 84, !12, i64 88, !6, i64 96, !12, i64 104, !12, i64 108, !6, i64 112, !12, i64 120, !12, i64 124, !12, i64 128, !12, i64 132, !12, i64 136, !12, i64 140, !12, i64 144, !11, i64 152, !11, i64 160, !12, i64 168, !12, i64 172, !12, i64 176, !11, i64 184, !11, i64 192, !12, i64 200, !11, i64 208, !12, i64 216, !12, i64 220, !12, i64 224, !12, i64 228, !12, i64 232, !12, i64 236, !12, i64 240, !12, i64 244, !12, i64 248, !12, i64 252, !12, i64 256, !12, i64 260, !12, i64 264, !12, i64 268, !12, i64 272, !12, i64 276, !12, i64 280, !12, i64 284, !12, i64 288, !12, i64 292, !7, i64 296, !12, i64 412, !12, i64 416, !12, i64 420, !12, i64 424, !12, i64 428, !12, i64 432, !12, i64 436, !12, i64 440, !12, i64 444, !11, i64 448, !11, i64 456, !11, i64 464, !12, i64 472, !12, i64 476, !12, i64 480, !12, i64 484, !12, i64 488, !12, i64 492, !12, i64 496, !12, i64 500, !12, i64 504, !12, i64 508, !12, i64 512, !12, i64 516, !12, i64 520, !12, i64 524, !12, i64 528, !12, i64 532, !12, i64 536, !12, i64 540, !11, i64 544, !12, i64 552, !12, i64 556, !12, i64 560, !12, i64 564, !12, i64 568, !12, i64 572, !12, i64 576, !12, i64 580, !11, i64 584, !12, i64 592, !6, i64 600, !6, i64 608, !12, i64 616, !12, i64 620, !12, i64 624, !12, i64 628, !12, i64 632, !6, i64 640, !12, i64 648, !6, i64 656, !12, i64 664, !7, i64 668, !12, i64 924, !7, i64 928, !7, i64 1184, !12, i64 1696, !12, i64 1700, !12, i64 1704, !12, i64 1708, !12, i64 1712, !12, i64 1716, !6, i64 1720, !6, i64 1728, !6, i64 1736, !6, i64 1744, !11, 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, !12, i64 1856, !6, i64 1864, !11, i64 1872, !11, i64 1880, !11, i64 1888, !11, i64 1896, !7, i64 1904, !7, i64 1912, !7, i64 2112, !7, i64 2152, !7, i64 2352, !6, i64 2392, !6, i64 2400, !6, i64 2408, !6, i64 2416, !12, i64 2424, !12, i64 2428, !12, i64 2432, !6, i64 2440, !6, i64 2448, !6, i64 2456, !6, i64 2464, !6, i64 2472, !12, i64 2480, !12, i64 2484, !6, i64 2488, !12, i64 2496, !6, i64 2504, !6, i64 2512, !6, i64 2520, !6, i64 2528, !12, i64 2536, !12, i64 2540, !12, i64 2544, !12, i64 2548, !12, i64 2552, !12, i64 2556, !12, i64 2560, !19, i64 2568, !12, i64 2576, !12, i64 2580, !12, i64 2584, !12, i64 2588, !6, i64 2592, !12, i64 2600, !12, i64 2604, !11, i64 2608, !12, i64 2616, !11, i64 2624, !11, i64 2632, !11, i64 2640, !12, i64 2648, !12, i64 2652, !12, i64 2656, !12, i64 2660, !11, i64 2664, !11, i64 2672, !12, i64 2680, !12, i64 2684, !12, i64 2688, !12, i64 2692, !11, i64 2696, !11, i64 2704, !12, i64 2712, !12, i64 2716, !12, i64 2720, !12, i64 2724, !6, i64 2728, !6, i64 2736, !6, i64 2744, !6, i64 2752, !6, i64 2760, !6, i64 2768, !6, i64 2776, !6, i64 2784, !12, i64 2792, !6, i64 2800, !6, i64 2808, !12, i64 2816, !12, i64 2820, !12, i64 2824, !6, i64 2832, !11, i64 2840, !11, i64 2848, !11, i64 2856, !12, i64 2864, !12, i64 2868, !6, i64 2872, !6, i64 2880, !12, i64 2888}
!19 = !{!"long", !7, i64 0}
!20 = !{!18, !6, i64 2408}
!21 = !{!10, !12, i64 108}


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

@qh_qh = external local_unnamed_addr global %struct.qhT, align 8
@.str.87 = external hidden unnamed_addr constant [62 x i8], align 1

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

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

declare void @qh_setreplace(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
define dso_local void @qh_mergefacet2d(ptr noundef %0, ptr noundef %1) local_unnamed_addr #1 {
  %3 = getelementptr inbounds i8, ptr %0, i64 64
  %4 = load ptr, ptr %3, align 8, !tbaa !5
  %5 = getelementptr inbounds i8, ptr %4, i64 8
  %6 = load ptr, ptr %5, align 8, !tbaa !12
  %7 = getelementptr inbounds i8, ptr %4, i64 16
  %8 = load ptr, ptr %7, align 8, !tbaa !12
  %9 = getelementptr inbounds i8, ptr %1, i64 64
  %10 = load ptr, ptr %9, align 8, !tbaa !5
  %11 = getelementptr inbounds i8, ptr %10, i64 8
  %12 = load ptr, ptr %11, align 8, !tbaa !12
  %13 = getelementptr inbounds i8, ptr %10, i64 16
  %14 = load ptr, ptr %13, align 8, !tbaa !12
  %15 = getelementptr inbounds i8, ptr %0, i64 80
  %16 = load ptr, ptr %15, align 8, !tbaa !13
  %17 = getelementptr inbounds i8, ptr %16, i64 8
  %18 = load ptr, ptr %17, align 8, !tbaa !12
  %19 = getelementptr inbounds i8, ptr %16, i64 16
  %20 = load ptr, ptr %19, align 8, !tbaa !12
  %21 = getelementptr inbounds i8, ptr %1, i64 80
  %22 = load ptr, ptr %21, align 8, !tbaa !13
  %23 = getelementptr inbounds i8, ptr %22, i64 8
  %24 = load ptr, ptr %23, align 8, !tbaa !12
  %25 = getelementptr inbounds i8, ptr %22, i64 16
  %26 = load ptr, ptr %25, align 8, !tbaa !12
  %27 = icmp eq ptr %6, %12
  br i1 %27, label %32, label %28

28:                                               ; preds = %2
  %29 = icmp eq ptr %6, %14
  br i1 %29, label %32, label %30

30:                                               ; preds = %28
  %31 = icmp eq ptr %8, %12
  %. = select i1 %31, ptr %14, ptr %12
  %.70 = select i1 %31, ptr %24, ptr %26
  br label %32

32:                                               ; preds = %30, %28, %2
  %.066 = phi ptr [ %14, %2 ], [ %12, %28 ], [ %., %30 ]
  %.065 = phi ptr [ %8, %2 ], [ %8, %28 ], [ %6, %30 ]
  %.064 = phi ptr [ %24, %2 ], [ %26, %28 ], [ %.70, %30 ]
  %.0 = phi ptr [ %18, %2 ], [ %18, %28 ], [ %20, %30 ]
  %33 = getelementptr inbounds i8, ptr %.065, i64 32
  %34 = load i32, ptr %33, align 8, !tbaa !14
  %35 = getelementptr inbounds i8, ptr %.066, i64 32
  %36 = load i32, ptr %35, align 8, !tbaa !14
  %37 = icmp ugt i32 %34, %36
  br i1 %37, label %38, label %42

38:                                               ; preds = %32
  store ptr %.065, ptr %11, align 8, !tbaa !12
  %39 = load ptr, ptr %9, align 8, !tbaa !5
  %40 = getelementptr inbounds i8, ptr %39, i64 16
  store ptr %.066, ptr %40, align 8, !tbaa !12
  %41 = icmp eq ptr %.066, %12
  br i1 %41, label %.sink.split, label %49

42:                                               ; preds = %32
  store ptr %.066, ptr %11, align 8, !tbaa !12
  %43 = load ptr, ptr %9, align 8, !tbaa !5
  %44 = getelementptr inbounds i8, ptr %43, i64 16
  store ptr %.065, ptr %44, align 8, !tbaa !12
  %45 = icmp eq ptr %.066, %14
  br i1 %45, label %.sink.split, label %49

.sink.split:                                      ; preds = %42, %38
  %.0.sink.ph = phi ptr [ %.064, %38 ], [ %.0, %42 ]
  %.064.sink.ph = phi ptr [ %.0, %38 ], [ %.064, %42 ]
  %46 = getelementptr inbounds i8, ptr %1, i64 112
  %47 = load i32, ptr %46, align 8
  %48 = xor i32 %47, 4096
  store i32 %48, ptr %46, align 8
  br label %49

49:                                               ; preds = %.sink.split, %42, %38
  %.0.sink = phi ptr [ %.064, %38 ], [ %.0, %42 ], [ %.0.sink.ph, %.sink.split ]
  %.064.sink = phi ptr [ %.0, %38 ], [ %.064, %42 ], [ %.064.sink.ph, %.sink.split ]
  %50 = load ptr, ptr %21, align 8, !tbaa !13
  %51 = getelementptr inbounds i8, ptr %50, i64 8
  store ptr %.0.sink, ptr %51, align 8, !tbaa !12
  %52 = load ptr, ptr %21, align 8, !tbaa !13
  %53 = getelementptr inbounds i8, ptr %52, i64 16
  store ptr %.064.sink, ptr %53, align 8, !tbaa !12
  tail call void @qh_makeridges(ptr noundef %.0)
  %54 = getelementptr inbounds i8, ptr %.0, i64 80
  %55 = load ptr, ptr %54, align 8, !tbaa !13
  tail call void @qh_setreplace(ptr noundef %55, ptr noundef nonnull %0, ptr noundef nonnull %1) #2
  %56 = load i32, ptr getelementptr inbounds (i8, ptr @qh_qh, i64 128), align 8, !tbaa !16
  %57 = icmp sgt i32 %56, 3
  br i1 %57, label %58, label %67

58:                                               ; preds = %49
  %59 = load ptr, ptr getelementptr inbounds (i8, ptr @qh_qh, i64 2408), align 8, !tbaa !19
  %60 = load i32, ptr %33, align 8, !tbaa !14
  %61 = getelementptr inbounds i8, ptr %.0, i64 108
  %62 = load i32, ptr %61, align 4, !tbaa !20
  %63 = getelementptr inbounds i8, ptr %0, i64 108
  %64 = load i32, ptr %63, align 4, !tbaa !20
  %65 = getelementptr inbounds i8, ptr %1, i64 108
  %66 = load i32, ptr %65, align 4, !tbaa !20
  tail call void (ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %59, i32 noundef 4036, ptr noundef nonnull @.str.87, i32 noundef %60, i32 noundef %62, i32 noundef %64, i32 noundef %66) #2
  br label %67

67:                                               ; preds = %58, %49
  ret void
}

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, !10, i64 64}
!6 = !{!"facetT", !7, i64 0, !7, i64 8, !7, i64 16, !10, i64 24, !8, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !10, i64 72, !10, i64 80, !10, i64 88, !10, i64 96, !11, i64 104, !11, i64 108, !11, i64 112, !11, i64 113, !11, i64 113, !11, i64 113, !11, i64 113, !11, i64 113, !11, i64 113, !11, i64 113, !11, i64 114, !11, i64 114, !11, i64 114, !11, i64 114, !11, i64 114, !11, i64 114, !11, i64 114, !11, i64 114, !11, i64 115, !11, i64 115, !11, i64 115, !11, i64 115, !11, i64 115, !11, i64 115, !11, i64 115, !11, i64 115}
!7 = !{!"double", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"int", !8, i64 0}
!12 = !{!8, !8, i64 0}
!13 = !{!6, !10, i64 80}
!14 = !{!15, !11, i64 32}
!15 = !{!"vertexT", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !11, i64 32, !11, i64 36, !11, i64 40, !11, i64 40, !11, i64 40, !11, i64 40, !11, i64 40}
!16 = !{!17, !11, i64 128}
!17 = !{!"qhT", !11, i64 0, !11, i64 4, !11, i64 8, !7, i64 16, !11, i64 24, !11, i64 28, !11, i64 32, !11, i64 36, !11, i64 40, !11, i64 44, !11, i64 48, !7, i64 56, !7, i64 64, !11, i64 72, !11, i64 76, !11, i64 80, !11, i64 84, !11, i64 88, !10, i64 96, !11, i64 104, !11, i64 108, !10, i64 112, !11, i64 120, !11, i64 124, !11, i64 128, !11, i64 132, !11, i64 136, !11, i64 140, !11, i64 144, !7, i64 152, !7, i64 160, !11, i64 168, !11, i64 172, !11, i64 176, !7, i64 184, !7, i64 192, !11, i64 200, !7, i64 208, !11, i64 216, !11, i64 220, !11, i64 224, !11, i64 228, !11, i64 232, !11, i64 236, !11, i64 240, !11, i64 244, !11, i64 248, !11, i64 252, !11, i64 256, !11, i64 260, !11, i64 264, !11, i64 268, !11, i64 272, !11, i64 276, !11, i64 280, !11, i64 284, !11, i64 288, !11, i64 292, !8, i64 296, !11, i64 412, !11, i64 416, !11, i64 420, !11, i64 424, !11, i64 428, !11, i64 432, !11, i64 436, !11, i64 440, !11, i64 444, !7, i64 448, !7, i64 456, !7, i64 464, !11, i64 472, !11, i64 476, !11, i64 480, !11, i64 484, !11, i64 488, !11, i64 492, !11, i64 496, !11, i64 500, !11, i64 504, !11, i64 508, !11, i64 512, !11, i64 516, !11, i64 520, !11, i64 524, !11, i64 528, !11, i64 532, !11, i64 536, !11, i64 540, !7, i64 544, !11, i64 552, !11, i64 556, !11, i64 560, !11, i64 564, !11, i64 568, !11, i64 572, !11, i64 576, !11, i64 580, !7, i64 584, !11, i64 592, !10, i64 600, !10, i64 608, !11, i64 616, !11, i64 620, !11, i64 624, !11, i64 628, !11, i64 632, !10, i64 640, !11, i64 648, !10, i64 656, !11, i64 664, !8, i64 668, !11, i64 924, !8, i64 928, !8, i64 1184, !11, i64 1696, !11, i64 1700, !11, i64 1704, !11, i64 1708, !11, i64 1712, !11, i64 1716, !10, i64 1720, !10, i64 1728, !10, i64 1736, !10, i64 1744, !7, i64 1752, !7, i64 1760, !7, i64 1768, !7, i64 1776, !7, i64 1784, !7, i64 1792, !7, i64 1800, !7, i64 1808, !7, i64 1816, !7, i64 1824, !7, i64 1832, !7, i64 1840, !7, i64 1848, !11, i64 1856, !10, i64 1864, !7, i64 1872, !7, i64 1880, !7, i64 1888, !7, i64 1896, !8, i64 1904, !8, i64 1912, !8, i64 2112, !8, i64 2152, !8, i64 2352, !10, i64 2392, !10, i64 2400, !10, i64 2408, !10, i64 2416, !11, i64 2424, !11, i64 2428, !11, i64 2432, !10, i64 2440, !10, i64 2448, !10, i64 2456, !10, i64 2464, !10, i64 2472, !11, i64 2480, !11, i64 2484, !10, i64 2488, !11, i64 2496, !10, i64 2504, !10, i64 2512, !10, i64 2520, !10, i64 2528, !11, i64 2536, !11, i64 2540, !11, i64 2544, !11, i64 2548, !11, i64 2552, !11, i64 2556, !11, i64 2560, !18, i64 2568, !11, i64 2576, !11, i64 2580, !11, i64 2584, !11, i64 2588, !10, i64 2592, !11, i64 2600, !11, i64 2604, !7, i64 2608, !11, i64 2616, !7, i64 2624, !7, i64 2632, !7, i64 2640, !11, i64 2648, !11, i64 2652, !11, i64 2656, !11, i64 2660, !7, i64 2664, !7, i64 2672, !11, i64 2680, !11, i64 2684, !11, i64 2688, !11, i64 2692, !7, i64 2696, !7, i64 2704, !11, i64 2712, !11, i64 2716, !11, i64 2720, !11, i64 2724, !10, i64 2728, !10, i64 2736, !10, i64 2744, !10, i64 2752, !10, i64 2760, !10, i64 2768, !10, i64 2776, !10, i64 2784, !11, i64 2792, !10, i64 2800, !10, i64 2808, !11, i64 2816, !11, i64 2820, !11, i64 2824, !10, i64 2832, !7, i64 2840, !7, i64 2848, !7, i64 2856, !11, i64 2864, !11, i64 2868, !10, i64 2872, !10, i64 2880, !11, i64 2888}
!18 = !{!"long", !8, i64 0}
!19 = !{!17, !10, i64 2408}
!20 = !{!6, !11, i64 108}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,SROAPass,SimplifyCFGPass,TailCallElimPass