; LLVM IR from jrl-umi3218/mc_rtc :: 3rd-party/qhull/src/libqhull_r (merge_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.vertexT = type { ptr, ptr, ptr, ptr, i32, i32, i8 }
%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 }

@mergetypes = external dso_local global [14 x ptr], align 16
@.str.182 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.237 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.238 = external hidden unnamed_addr constant [94 x i8], align 1
@.str.239 = external hidden unnamed_addr constant [53 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, ptr noundef, i32 noundef, ptr noundef, ...) #1

declare void @qh_printlists(ptr noundef) #1

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

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

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

; Function Attrs: nounwind uwtable
define dso_local void @qh_tracemerge(ptr noundef %0, ptr noundef %1, ptr noundef %2, i32 noundef %3) #2 {
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  store i32 %3, ptr %8, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #3
  store i32 0, ptr %9, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #3
  %11 = load i32, ptr %8, align 4, !tbaa !9
  %12 = icmp ugt i32 %11, 0
  br i1 %12, label %13, label %22

13:                                               ; preds = %4
  %14 = load i32, ptr %8, align 4, !tbaa !9
  %15 = zext i32 %14 to i64
  %16 = icmp ult i64 %15, 14
  br i1 %16, label %17, label %22

17:                                               ; preds = %13
  %18 = load i32, ptr %8, align 4, !tbaa !9
  %19 = zext i32 %18 to i64
  %20 = getelementptr inbounds [14 x ptr], ptr @mergetypes, i64 0, i64 %19
  %21 = load ptr, ptr %20, align 8, !tbaa !5
  store ptr %21, ptr %10, align 8, !tbaa !5
  br label %24

22:                                               ; preds = %13, %4
  %23 = load ptr, ptr @mergetypes, align 16, !tbaa !5
  store ptr %23, ptr %10, align 8, !tbaa !5
  br label %24

24:                                               ; preds = %22, %17
  %25 = load ptr, ptr %5, align 8, !tbaa !5
  %26 = getelementptr inbounds %struct.qhT, ptr %25, i32 0, i32 29
  %27 = load i32, ptr %26, align 8, !tbaa !11
  %28 = icmp sge i32 %27, 4
  br i1 %28, label %29, label %32

29:                                               ; preds = %24
  %30 = load ptr, ptr %5, align 8, !tbaa !5
  %31 = load ptr, ptr %7, align 8, !tbaa !5
  call void @qh_errprint(ptr noundef %30, ptr noundef @.str.237, ptr noundef %31, ptr noundef null, ptr noundef null, ptr noundef null)
  br label %32

32:                                               ; preds = %29, %24
  %33 = load ptr, ptr %7, align 8, !tbaa !5
  %34 = load ptr, ptr %5, align 8, !tbaa !5
  %35 = getelementptr inbounds %struct.qhT, ptr %34, i32 0, i32 170
  %36 = load ptr, ptr %35, align 8, !tbaa !17
  %37 = icmp eq ptr %33, %36
  br i1 %37, label %53, label %38

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

43:                                               ; preds = %38
  %44 = load ptr, ptr %5, align 8, !tbaa !5
  %45 = getelementptr inbounds %struct.qhT, ptr %44, i32 0, i32 174
  %46 = load ptr, ptr %45, align 8, !tbaa !18
  %47 = getelementptr inbounds %struct.vertexT, ptr %46, i32 0, i32 6
  %48 = load i8, ptr %47, align 8
  %49 = lshr i8 %48, 4
  %50 = and i8 %49, 1
  %51 = zext i8 %50 to i32
  %52 = icmp ne i32 %51, 0
  br i1 %52, label %53, label %106

53:                                               ; preds = %43, %32
  %54 = load ptr, ptr %5, align 8, !tbaa !5
  %55 = load ptr, ptr %5, align 8, !tbaa !5
  %56 = getelementptr inbounds %struct.qhT, ptr %55, i32 0, i32 158
  %57 = load ptr, ptr %56, align 8, !tbaa !19
  %58 = load ptr, ptr %6, align 8, !tbaa !5
  %59 = getelementptr inbounds %struct.facetT, ptr %58, i32 0, i32 14
  %60 = load i32, ptr %59, align 4, !tbaa !20
  %61 = load ptr, ptr %7, align 8, !tbaa !5
  %62 = getelementptr inbounds %struct.facetT, ptr %61, i32 0, i32 14
  %63 = load i32, ptr %62, align 4, !tbaa !20
  %64 = load i32, ptr %8, align 4, !tbaa !9
  %65 = load ptr, ptr %10, align 8, !tbaa !5
  %66 = load ptr, ptr %5, align 8, !tbaa !5
  %67 = getelementptr inbounds %struct.qhT, ptr %66, i32 0, i32 190
  %68 = load i32, ptr %67, align 4, !tbaa !22
  call void (ptr, ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %54, ptr noundef %57, i32 noundef 8085, ptr noundef @.str.238, i32 noundef %60, i32 noundef %63, i32 noundef %64, ptr noundef %65, i32 noundef %68)
  %69 = load ptr, ptr %7, align 8, !tbaa !5
  %70 = load ptr, ptr %5, align 8, !tbaa !5
  %71 = getelementptr inbounds %struct.qhT, ptr %70, i32 0, i32 170
  %72 = load ptr, ptr %71, align 8, !tbaa !17
  %73 = icmp ne ptr %69, %72
  br i1 %73, label %74, label %105

74:                                               ; preds = %53
  %75 = load ptr, ptr %5, align 8, !tbaa !5
  %76 = load ptr, ptr %5, align 8, !tbaa !5
  %77 = getelementptr inbounds %struct.qhT, ptr %76, i32 0, i32 170
  %78 = load ptr, ptr %77, align 8, !tbaa !17
  %79 = load ptr, ptr %5, align 8, !tbaa !5
  %80 = getelementptr inbounds %struct.qhT, ptr %79, i32 0, i32 174
  %81 = load ptr, ptr %80, align 8, !tbaa !18
  %82 = icmp ne ptr %81, null
  br i1 %82, label %83, label %99

83:                                               ; preds = %74
  %84 = load ptr, ptr %5, align 8, !tbaa !5
  %85 = getelementptr inbounds %struct.qhT, ptr %84, i32 0, i32 174
  %86 = load ptr, ptr %85, align 8, !tbaa !18
  %87 = getelementptr inbounds %struct.vertexT, ptr %86, i32 0, i32 3
  %88 = load ptr, ptr %87, align 8, !tbaa !23
  %89 = icmp ne ptr %88, null
  br i1 %89, label %90, label %99

90:                                               ; preds = %83
  %91 = load ptr, ptr %5, align 8, !tbaa !5
  %92 = getelementptr inbounds %struct.qhT, ptr %91, i32 0, i32 174
  %93 = load ptr, ptr %92, align 8, !tbaa !18
  %94 = getelementptr inbounds %struct.vertexT, ptr %93, i32 0, i32 3
  %95 = load ptr, ptr %94, align 8, !tbaa !23
  %96 = getelementptr inbounds %struct.setT, ptr %95, i32 0, i32 1
  %97 = getelementptr inbounds [1 x %union.setelemT], ptr %96, i64 0, i64 0
  %98 = load ptr, ptr %97, align 8, !tbaa !25
  br label %100

99:                                               ; preds = %83, %74
  br label %100

100:                                              ; preds = %99, %90
  %101 = phi ptr [ %98, %90 ], [ null, %99 ]
  %102 = load ptr, ptr %5, align 8, !tbaa !5
  %103 = getelementptr inbounds %struct.qhT, ptr %102, i32 0, i32 174
  %104 = load ptr, ptr %103, align 8, !tbaa !18
  call void @qh_errprint(ptr noundef %75, ptr noundef @.str.182, ptr noundef %78, ptr noundef %101, ptr noundef null, ptr noundef %104)
  br label %105

105:                                              ; preds = %100, %53
  br label %106

106:                                              ; preds = %105, %43, %38
  %107 = load ptr, ptr %5, align 8, !tbaa !5
  %108 = getelementptr inbounds %struct.qhT, ptr %107, i32 0, i32 174
  %109 = load ptr, ptr %108, align 8, !tbaa !18
  %110 = icmp ne ptr %109, null
  br i1 %110, label %111, label %135

111:                                              ; preds = %106
  %112 = load ptr, ptr %5, align 8, !tbaa !5
  %113 = getelementptr inbounds %struct.qhT, ptr %112, i32 0, i32 174
  %114 = load ptr, ptr %113, align 8, !tbaa !18
  %115 = getelementptr inbounds %struct.vertexT, ptr %114, i32 0, i32 6
  %116 = load i8, ptr %115, align 8
  %117 = lshr i8 %116, 2
  %118 = and i8 %117, 1
  %119 = zext i8 %118 to i32
  %120 = icmp ne i32 %119, 0
  br i1 %120, label %121, label %129

121:                                              ; preds = %111
  %122 = load ptr, ptr %5, align 8, !tbaa !5
  %123 = load ptr, ptr %5, align 8, !tbaa !5
  %124 = getelementptr inbounds %struct.qhT, ptr %123, i32 0, i32 158
  %125 = load ptr, ptr %124, align 8, !tbaa !19
  %126 = load ptr, ptr %5, align 8, !tbaa !5
  %127 = getelementptr inbounds %struct.qhT, ptr %126, i32 0, i32 190
  %128 = load i32, ptr %127, align 4, !tbaa !22
  call void (ptr, ptr, i32, ptr, ...) @qh_fprintf(ptr noundef %122, ptr noundef %125, i32 noundef 8086, ptr noundef @.str.239, i32 noundef %128)
  br label %134

129:                                              ; preds = %111
  %130 = load ptr, ptr %5, align 8, !tbaa !5
  %131 = load ptr, ptr %5, align 8, !tbaa !5
  %132 = getelementptr inbounds %struct.qhT, ptr %131, i32 0, i32 174
  %133 = load ptr, ptr %132, align 8, !tbaa !18
  call void @qh_checkvertex(ptr noundef %130, ptr noundef %133, i32 noundef 1, ptr noundef %9)
  br label %134

134:                                              ; preds = %129, %121
  br label %135

135:                                              ; preds = %134, %106
  %136 = load ptr, ptr %5, align 8, !tbaa !5
  %137 = getelementptr inbounds %struct.qhT, ptr %136, i32 0, i32 170
  %138 = load ptr, ptr %137, align 8, !tbaa !17
  %139 = icmp ne ptr %138, null
  br i1 %139, label %140, label %161

140:                                              ; preds = %135
  %141 = load ptr, ptr %5, align 8, !tbaa !5
  %142 = getelementptr inbounds %struct.qhT, ptr %141, i32 0, i32 170
  %143 = load ptr, ptr %142, align 8, !tbaa !17
  %144 = getelementptr inbounds %struct.facetT, ptr %143, i32 0, i32 3
  %145 = load ptr, ptr %144, align 8, !tbaa !26
  %146 = icmp ne ptr %145, null
  br i1 %146, label %147, label %161

147:                                              ; preds = %140
  %148 = load ptr, ptr %5, align 8, !tbaa !5
  %149 = getelementptr inbounds %struct.qhT, ptr %148, i32 0, i32 170
  %150 = load ptr, ptr %149, align 8, !tbaa !17
  %151 = getelementptr inbounds %struct.facetT, ptr %150, i32 0, i32 15
  %152 = load i32, ptr %151, align 8
  %153 = lshr i32 %152, 11
  %154 = and i32 %153, 1
  %155 = icmp ne i32 %154, 0
  br i1 %155, label %161, label %156

156:                                              ; preds = %147
  %157 = load ptr, ptr %5, align 8, !tbaa !5
  %158 = load ptr, ptr %5, align 8, !tbaa !5
  %159 = getelementptr inbounds %struct.qhT, ptr %158, i32 0, i32 170
  %160 = load ptr, ptr %159, align 8, !tbaa !17
  call void @qh_checkfacet(ptr noundef %157, ptr noundef %160, i32 noundef 1, ptr noundef %9)
  br label %161

161:                                              ; preds = %156, %147, %140, %135
  %162 = load ptr, ptr %5, align 8, !tbaa !5
  %163 = getelementptr inbounds %struct.qhT, ptr %162, i32 0, i32 14
  %164 = load i32, ptr %163, align 4, !tbaa !27
  %165 = icmp ne i32 %164, 0
  br i1 %165, label %171, label %166

166:                                              ; preds = %161
  %167 = load ptr, ptr %5, align 8, !tbaa !5
  %168 = getelementptr inbounds %struct.qhT, ptr %167, i32 0, i32 29
  %169 = load i32, ptr %168, align 8, !tbaa !11
  %170 = icmp sge i32 %169, 4
  br i1 %170, label %171, label %186

171:                                              ; preds = %166, %161
  %172 = load ptr, ptr %5, align 8, !tbaa !5
  %173 = getelementptr inbounds %struct.qhT, ptr %172, i32 0, i32 29
  %174 = load i32, ptr %173, align 8, !tbaa !11
  %175 = icmp sge i32 %174, 4
  br i1 %175, label %176, label %183

176:                                              ; preds = %171
  %177 = load ptr, ptr %5, align 8, !tbaa !5
  %178 = getelementptr inbounds %struct.qhT, ptr %177, i32 0, i32 178
  %179 = load i32, ptr %178, align 8, !tbaa !28
  %180 = icmp slt i32 %179, 500
  br i1 %180, label %181, label %183

181:                                              ; preds = %176
  %182 = load ptr, ptr %5, align 8, !tbaa !5
  call void @qh_printlists(ptr noundef %182)
  br label %183

183:                                              ; preds = %181, %176, %171
  %184 = load ptr, ptr %5, align 8, !tbaa !5
  %185 = load ptr, ptr %7, align 8, !tbaa !5
  call void @qh_checkfacet(ptr noundef %184, ptr noundef %185, i32 noundef 1, ptr noundef %9)
  br label %186

186:                                              ; preds = %183, %166
  %187 = load i32, ptr %9, align 4, !tbaa !9
  %188 = icmp ne i32 %187, 0
  br i1 %188, label %189, label %191

189:                                              ; preds = %186
  %190 = load ptr, ptr %5, align 8, !tbaa !5
  call void @qh_errexit(ptr noundef %190, i32 noundef 5, ptr noundef null, ptr noundef null)
  br label %191

191:                                              ; preds = %189, %186
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #3
  ret void
}

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

declare void @qh_checkfacet(ptr noundef, ptr noundef, i32 noundef, 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 = { 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 2504}
!18 = !{!12, !6, i64 2536}
!19 = !{!12, !6, i64 2424}
!20 = !{!21, !10, i64 108}
!21 = !{!"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}
!22 = !{!12, !10, i64 2620}
!23 = !{!24, !6, i64 24}
!24 = !{!"vertexT", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !10, i64 32, !10, i64 36, !10, i64 40, !10, i64 40, !10, i64 40, !10, i64 40, !10, i64 40, !10, i64 40}
!25 = !{!7, !7, i64 0}
!26 = !{!21, !6, i64 24}
!27 = !{!12, !10, i64 60}
!28 = !{!12, !10, i64 2568}


; 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"

@mergetypes = external dso_local local_unnamed_addr global [14 x ptr], align 16
@.str.182 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.237 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.238 = external hidden unnamed_addr constant [94 x i8], align 1
@.str.239 = external hidden unnamed_addr constant [53 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

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

declare void @qh_printlists(ptr noundef) local_unnamed_addr #1

; 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_errexit(ptr noundef, i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

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

; Function Attrs: nounwind uwtable
define dso_local void @qh_tracemerge(ptr noundef %0, ptr nocapture noundef readonly %1, ptr noundef %2, i32 noundef %3) local_unnamed_addr #2 {
  %5 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #3
  store i32 0, ptr %5, align 4, !tbaa !5
  %6 = add i32 %3, -1
  %or.cond = icmp ult i32 %6, 13
  %7 = zext nneg i32 %3 to i64
  %8 = getelementptr inbounds [14 x ptr], ptr @mergetypes, i64 0, i64 %7
  %.0.in = select i1 %or.cond, ptr %8, ptr @mergetypes
  %.0 = load ptr, ptr %.0.in, align 8, !tbaa !9
  %9 = getelementptr inbounds i8, ptr %0, i64 136
  %10 = load i32, ptr %9, align 8, !tbaa !11
  %11 = icmp sgt i32 %10, 3
  br i1 %11, label %12, label %13

12:                                               ; preds = %4
  tail call void @qh_errprint(ptr noundef nonnull %0, ptr noundef nonnull @.str.237, ptr noundef %2, ptr noundef null, ptr noundef null, ptr noundef null) #3
  br label %13

13:                                               ; preds = %12, %4
  %14 = getelementptr inbounds i8, ptr %0, i64 2504
  %15 = load ptr, ptr %14, align 8, !tbaa !17
  %16 = icmp eq ptr %15, %2
  br i1 %16, label %24, label %17

17:                                               ; preds = %13
  %18 = getelementptr inbounds i8, ptr %0, i64 2536
  %19 = load ptr, ptr %18, align 8, !tbaa !18
  %.not = icmp eq ptr %19, null
  br i1 %.not, label %45, label %20

20:                                               ; preds = %17
  %21 = getelementptr inbounds i8, ptr %19, i64 40
  %22 = load i8, ptr %21, align 8
  %23 = and i8 %22, 16
  %.not53 = icmp eq i8 %23, 0
  br i1 %.not53, label %45, label %24

24:                                               ; preds = %20, %13
  %25 = getelementptr inbounds i8, ptr %0, i64 2424
  %26 = load ptr, ptr %25, align 8, !tbaa !19
  %27 = getelementptr inbounds i8, ptr %1, i64 108
  %28 = load i32, ptr %27, align 4, !tbaa !20
  %29 = getelementptr inbounds i8, ptr %2, i64 108
  %30 = load i32, ptr %29, align 4, !tbaa !20
  %31 = getelementptr inbounds i8, ptr %0, i64 2620
  %32 = load i32, ptr %31, align 4, !tbaa !22
  tail call void (ptr, ptr, i32, ptr, ...) @qh_fprintf(ptr noundef nonnull %0, ptr noundef %26, i32 noundef 8085, ptr noundef nonnull @.str.238, i32 noundef %28, i32 noundef %30, i32 noundef %3, ptr noundef %.0, i32 noundef %32) #3
  %33 = load ptr, ptr %14, align 8, !tbaa !17
  %.not54 = icmp eq ptr %33, %2
  br i1 %.not54, label %45, label %34

34:                                               ; preds = %24
  %35 = getelementptr inbounds i8, ptr %0, i64 2536
  %36 = load ptr, ptr %35, align 8, !tbaa !18
  %.not55 = icmp eq ptr %36, null
  br i1 %.not55, label %43, label %37

37:                                               ; preds = %34
  %38 = getelementptr inbounds i8, ptr %36, i64 24
  %39 = load ptr, ptr %38, align 8, !tbaa !23
  %.not56 = icmp eq ptr %39, null
  br i1 %.not56, label %43, label %40

40:                                               ; preds = %37
  %41 = getelementptr inbounds i8, ptr %39, i64 8
  %42 = load ptr, ptr %41, align 8, !tbaa !25
  br label %43

43:                                               ; preds = %34, %37, %40
  %44 = phi ptr [ %42, %40 ], [ null, %37 ], [ null, %34 ]
  tail call void @qh_errprint(ptr noundef nonnull %0, ptr noundef nonnull @.str.182, ptr noundef %33, ptr noundef %44, ptr noundef null, ptr noundef %36) #3
  br label %45

45:                                               ; preds = %24, %43, %20, %17
  %46 = getelementptr inbounds i8, ptr %0, i64 2536
  %47 = load ptr, ptr %46, align 8, !tbaa !18
  %.not57 = icmp eq ptr %47, null
  br i1 %.not57, label %58, label %48

48:                                               ; preds = %45
  %49 = getelementptr inbounds i8, ptr %47, i64 40
  %50 = load i8, ptr %49, align 8
  %51 = and i8 %50, 4
  %.not58 = icmp eq i8 %51, 0
  br i1 %.not58, label %57, label %52

52:                                               ; preds = %48
  %53 = getelementptr inbounds i8, ptr %0, i64 2424
  %54 = load ptr, ptr %53, align 8, !tbaa !19
  %55 = getelementptr inbounds i8, ptr %0, i64 2620
  %56 = load i32, ptr %55, align 4, !tbaa !22
  tail call void (ptr, ptr, i32, ptr, ...) @qh_fprintf(ptr noundef nonnull %0, ptr noundef %54, i32 noundef 8086, ptr noundef nonnull @.str.239, i32 noundef %56) #3
  br label %58

57:                                               ; preds = %48
  call void @qh_checkvertex(ptr noundef nonnull %0, ptr noundef nonnull %47, i32 noundef 1, ptr noundef nonnull %5) #3
  br label %58

58:                                               ; preds = %52, %57, %45
  %59 = load ptr, ptr %14, align 8, !tbaa !17
  %.not59 = icmp eq ptr %59, null
  br i1 %.not59, label %68, label %60

60:                                               ; preds = %58
  %61 = getelementptr inbounds i8, ptr %59, i64 24
  %62 = load ptr, ptr %61, align 8, !tbaa !26
  %.not60 = icmp eq ptr %62, null
  br i1 %.not60, label %68, label %63

63:                                               ; preds = %60
  %64 = getelementptr inbounds i8, ptr %59, i64 112
  %65 = load i32, ptr %64, align 8
  %66 = and i32 %65, 2048
  %.not61 = icmp eq i32 %66, 0
  br i1 %.not61, label %67, label %68

67:                                               ; preds = %63
  call void @qh_checkfacet(ptr noundef nonnull %0, ptr noundef nonnull %59, i32 noundef 1, ptr noundef nonnull %5) #3
  br label %68

68:                                               ; preds = %67, %63, %60, %58
  %69 = getelementptr inbounds i8, ptr %0, i64 60
  %70 = load i32, ptr %69, align 4, !tbaa !27
  %.not62 = icmp eq i32 %70, 0
  %71 = load i32, ptr %9, align 8, !tbaa !11
  %72 = icmp sgt i32 %71, 3
  br i1 %.not62, label %73, label %74

73:                                               ; preds = %68
  br i1 %72, label %.thread, label %80

74:                                               ; preds = %68
  br i1 %72, label %.thread, label %79

.thread:                                          ; preds = %73, %74
  %75 = getelementptr inbounds i8, ptr %0, i64 2568
  %76 = load i32, ptr %75, align 8, !tbaa !28
  %77 = icmp slt i32 %76, 500
  br i1 %77, label %78, label %79

78:                                               ; preds = %.thread
  call void @qh_printlists(ptr noundef nonnull %0) #3
  br label %79

79:                                               ; preds = %78, %.thread, %74
  call void @qh_checkfacet(ptr noundef nonnull %0, ptr noundef %2, i32 noundef 1, ptr noundef nonnull %5) #3
  br label %80

80:                                               ; preds = %79, %73
  %81 = load i32, ptr %5, align 4, !tbaa !5
  %.not63 = icmp eq i32 %81, 0
  br i1 %.not63, label %83, label %82

82:                                               ; preds = %80
  call void @qh_errexit(ptr noundef nonnull %0, i32 noundef 5, ptr noundef null, ptr noundef null) #3
  br label %83

83:                                               ; preds = %82, %80
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #3
  ret void
}

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

declare void @qh_checkfacet(ptr noundef, ptr noundef, i32 noundef, 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 = { 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, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !6, i64 136}
!12 = !{!"qhT", !6, i64 0, !6, i64 4, !6, i64 8, !6, i64 12, !6, i64 16, !6, i64 20, !13, 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, !13, i64 64, !13, i64 72, !6, i64 80, !6, i64 84, !6, i64 88, !6, i64 92, !6, i64 96, !6, i64 100, !10, i64 104, !6, i64 112, !6, i64 116, !10, i64 120, !6, i64 128, !6, i64 132, !6, i64 136, !6, i64 140, !6, i64 144, !6, i64 148, !6, i64 152, !13, i64 160, !13, i64 168, !6, i64 176, !6, i64 180, !6, i64 184, !6, i64 188, !13, i64 192, !13, i64 200, !6, i64 208, !6, i64 212, !13, 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, !13, i64 448, !13, i64 456, !13, 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, !13, 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, !13, i64 592, !6, i64 600, !10, i64 608, !10, i64 616, !6, i64 624, !6, i64 628, !6, i64 632, !6, i64 636, !6, i64 640, !10, i64 648, !6, i64 656, !10, 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, !10, i64 1728, !10, i64 1736, !10, i64 1744, !10, 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, !10, i64 1872, !13, i64 1880, !13, i64 1888, !13, i64 1896, !13, i64 1904, !6, i64 1912, !7, i64 1916, !7, i64 1928, !7, i64 2128, !7, i64 2168, !7, i64 2368, !10, i64 2408, !10, i64 2416, !10, i64 2424, !10, i64 2432, !6, i64 2440, !6, i64 2444, !6, i64 2448, !10, i64 2456, !10, i64 2464, !10, i64 2472, !10, i64 2480, !10, i64 2488, !6, i64 2496, !6, i64 2500, !10, i64 2504, !6, i64 2512, !10, i64 2520, !6, i64 2528, !10, i64 2536, !10, i64 2544, !10, i64 2552, !10, 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, !14, i64 2600, !6, i64 2608, !6, i64 2612, !6, i64 2616, !6, i64 2620, !6, i64 2624, !10, i64 2632, !10, i64 2640, !6, i64 2648, !6, i64 2652, !6, i64 2656, !13, i64 2664, !6, i64 2672, !13, i64 2680, !13, i64 2688, !13, i64 2696, !6, i64 2704, !6, i64 2708, !6, i64 2712, !6, i64 2716, !6, i64 2720, !13, i64 2728, !13, i64 2736, !6, i64 2744, !6, i64 2748, !6, i64 2752, !6, i64 2756, !6, i64 2760, !6, i64 2764, !13, i64 2768, !13, i64 2776, !6, i64 2784, !6, i64 2788, !6, i64 2792, !6, i64 2796, !10, i64 2800, !10, i64 2808, !10, i64 2816, !10, i64 2824, !10, i64 2832, !10, i64 2840, !10, i64 2848, !10, i64 2856, !10, i64 2864, !6, i64 2872, !10, i64 2880, !10, i64 2888, !6, i64 2896, !6, i64 2900, !6, i64 2904, !10, i64 2912, !13, i64 2920, !13, i64 2928, !13, i64 2936, !13, i64 2944, !6, i64 2952, !6, i64 2956, !6, i64 2960, !6, i64 2964, !6, i64 2968, !6, i64 2972, !10, i64 2976, !6, i64 2984, !6, i64 2988, !7, i64 2992, !7, i64 3192, !6, i64 3232, !13, i64 3240, !10, i64 3248, !10, i64 3256, !10, i64 3264, !15, i64 3272, !16, i64 3424}
!13 = !{!"double", !7, i64 0}
!14 = !{!"long", !7, i64 0}
!15 = !{!"qhmemT", !6, i64 0, !6, i64 4, !6, i64 8, !6, i64 12, !6, i64 16, !6, i64 20, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !6, i64 64, !10, i64 72, !10, 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}
!16 = !{!"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, !13, i64 5336}
!17 = !{!12, !10, i64 2504}
!18 = !{!12, !10, i64 2536}
!19 = !{!12, !10, i64 2424}
!20 = !{!21, !6, i64 108}
!21 = !{!"facetT", !13, i64 0, !13, i64 8, !13, i64 16, !10, i64 24, !7, 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, !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}
!22 = !{!12, !6, i64 2620}
!23 = !{!24, !10, i64 24}
!24 = !{!"vertexT", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !6, i64 32, !6, i64 36, !6, i64 40, !6, i64 40, !6, i64 40, !6, i64 40, !6, i64 40, !6, i64 40}
!25 = !{!7, !7, i64 0}
!26 = !{!21, !10, i64 24}
!27 = !{!12, !6, i64 60}
!28 = !{!12, !6, i64 2568}


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