; LLVM IR from Slingshot-Physics/slingshot-community :: common/geometry/src (gauss_map)

; 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.geometry::types::polygon50_t" = type { i32, [50 x %class.Vector3] }
%class.Vector3 = type { [3 x float] }
%"class.std::set" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<unsigned int, unsigned int, std::_Identity<unsigned int>, std::less<unsigned int>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<unsigned int, unsigned int, std::_Identity<unsigned int>, std::less<unsigned int>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"struct.std::pair" = type <{ %"struct.std::_Rb_tree_const_iterator", i8, [7 x i8] }>
%"struct.std::_Rb_tree_const_iterator" = type { ptr }
%"struct.geometry::types::gaussMapMesh_t" = type { i32, i32, i32, [1000 x %"struct.geometry::types::leanNeighborTriangle_t"], [500 x %class.Vector3], [1000 x %"struct.geometry::types::gaussMapFace_t"] }
%"struct.geometry::types::leanNeighborTriangle_t" = type { [3 x i32], [3 x i32] }
%"struct.geometry::types::gaussMapFace_t" = type { %class.Vector3, i32, i32 }

@_ZN8geometry4mesh17TriangleGraphBase9edgeVertsE = external constant [3 x [2 x i32]], align 16

; 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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN8geometry4mesh15polygonFromFaceERKNS_5types14gaussMapMesh_tEj(ptr dead_on_unwind noalias writable sret(%"struct.geometry::types::polygon50_t") align 4 %0, ptr noundef nonnull align 4 dereferenceable(50012) %1, i32 noundef %2) #1 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca %"class.std::set", align 8
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca ptr, align 8
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca ptr, align 8
  %19 = alloca i32, align 4
  %20 = alloca %"struct.std::pair", align 8
  %21 = alloca i32, align 4
  %22 = alloca %"struct.std::pair", align 8
  %23 = alloca ptr, align 8
  %24 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %25 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %26 = alloca i32, align 4
  store ptr %0, ptr %4, align 8
  store ptr %1, ptr %5, align 8, !tbaa !5
  store i32 %2, ptr %6, align 4, !tbaa !9
  call void @_ZN8geometry5types11polygon50_tC2Ev(ptr noundef nonnull align 4 dereferenceable(604) %0)
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #4
  %27 = getelementptr inbounds %"struct.geometry::types::polygon50_t", ptr %0, i32 0, i32 0
  store ptr %27, ptr %7, align 8, !tbaa !5
  %28 = load ptr, ptr %7, align 8, !tbaa !5
  store i32 0, ptr %28, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #4
  %29 = load ptr, ptr %5, align 8, !tbaa !5
  %30 = getelementptr inbounds %"struct.geometry::types::gaussMapMesh_t", ptr %29, i32 0, i32 5
  %31 = load i32, ptr %6, align 4, !tbaa !9
  %32 = zext i32 %31 to i64
  %33 = getelementptr inbounds [1000 x %"struct.geometry::types::gaussMapFace_t"], ptr %30, i64 0, i64 %32
  store ptr %33, ptr %8, align 8, !tbaa !5
  %34 = load ptr, ptr %8, align 8, !tbaa !5
  %35 = getelementptr inbounds %"struct.geometry::types::gaussMapFace_t", ptr %34, i32 0, i32 2
  %36 = load i32, ptr %35, align 4, !tbaa !11
  %37 = icmp eq i32 %36, 1
  br i1 %37, label %38, label %74

38:                                               ; preds = %3
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #4
  store i32 0, ptr %9, align 4, !tbaa !9
  br label %39

39:                                               ; preds = %70, %38
  %40 = load i32, ptr %9, align 4, !tbaa !9
  %41 = icmp slt i32 %40, 3
  br i1 %41, label %43, label %42

42:                                               ; preds = %39
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #4
  br label %73

43:                                               ; preds = %39
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #4
  %44 = load ptr, ptr %5, align 8, !tbaa !5
  %45 = getelementptr inbounds %"struct.geometry::types::gaussMapMesh_t", ptr %44, i32 0, i32 3
  %46 = load ptr, ptr %8, align 8, !tbaa !5
  %47 = getelementptr inbounds %"struct.geometry::types::gaussMapFace_t", ptr %46, i32 0, i32 1
  %48 = load i32, ptr %47, align 4, !tbaa !14
  %49 = zext i32 %48 to i64
  %50 = getelementptr inbounds [1000 x %"struct.geometry::types::leanNeighborTriangle_t"], ptr %45, i64 0, i64 %49
  %51 = getelementptr inbounds %"struct.geometry::types::leanNeighborTriangle_t", ptr %50, i32 0, i32 0
  %52 = load i32, ptr %9, align 4, !tbaa !9
  %53 = sext i32 %52 to i64
  %54 = getelementptr inbounds [3 x i32], ptr %51, i64 0, i64 %53
  %55 = load i32, ptr %54, align 4, !tbaa !9
  store i32 %55, ptr %10, align 4, !tbaa !9
  %56 = load ptr, ptr %5, align 8, !tbaa !5
  %57 = getelementptr inbounds %"struct.geometry::types::gaussMapMesh_t", ptr %56, i32 0, i32 4
  %58 = load i32, ptr %10, align 4, !tbaa !9
  %59 = zext i32 %58 to i64
  %60 = getelementptr inbounds [500 x %class.Vector3], ptr %57, i64 0, i64 %59
  %61 = getelementptr inbounds %"struct.geometry::types::polygon50_t", ptr %0, i32 0, i32 1
  %62 = load ptr, ptr %7, align 8, !tbaa !5
  %63 = load i32, ptr %62, align 4, !tbaa !9
  %64 = zext i32 %63 to i64
  %65 = getelementptr inbounds [50 x %class.Vector3], ptr %61, i64 0, i64 %64
  %66 = call noundef nonnull align 4 dereferenceable(12) ptr @_ZN7Vector3aSERKS_(ptr noundef nonnull align 4 dereferenceable(12) %65, ptr noundef nonnull align 4 dereferenceable(12) %60)
  %67 = load ptr, ptr %7, align 8, !tbaa !5
  %68 = load i32, ptr %67, align 4, !tbaa !9
  %69 = add i32 %68, 1
  store i32 %69, ptr %67, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #4
  br label %70

70:                                               ; preds = %43
  %71 = load i32, ptr %9, align 4, !tbaa !9
  %72 = add nsw i32 %71, 1
  store i32 %72, ptr %9, align 4, !tbaa !9
  br label %39, !llvm.loop !15

73:                                               ; preds = %42
  store i32 1, ptr %11, align 4
  br label %218

74:                                               ; preds = %3
  call void @llvm.lifetime.start.p0(i64 48, ptr %12) #4
  call void @_ZNSt3setIjSt4lessIjESaIjEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %12) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #4
  store i32 0, ptr %13, align 4, !tbaa !9
  br label %75

75:                                               ; preds = %170, %74
  %76 = load i32, ptr %13, align 4, !tbaa !9
  %77 = load ptr, ptr %8, align 8, !tbaa !5
  %78 = getelementptr inbounds %"struct.geometry::types::gaussMapFace_t", ptr %77, i32 0, i32 2
  %79 = load i32, ptr %78, align 4, !tbaa !11
  %80 = icmp ult i32 %76, %79
  br i1 %80, label %82, label %81

81:                                               ; preds = %75
  store i32 5, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #4
  br label %173

82:                                               ; preds = %75
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #4
  %83 = load ptr, ptr %8, align 8, !tbaa !5
  %84 = getelementptr inbounds %"struct.geometry::types::gaussMapFace_t", ptr %83, i32 0, i32 1
  %85 = load i32, ptr %84, align 4, !tbaa !14
  %86 = load i32, ptr %13, align 4, !tbaa !9
  %87 = add i32 %85, %86
  store i32 %87, ptr %14, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #4
  %88 = load ptr, ptr %5, align 8, !tbaa !5
  %89 = getelementptr inbounds %"struct.geometry::types::gaussMapMesh_t", ptr %88, i32 0, i32 3
  %90 = load i32, ptr %14, align 4, !tbaa !9
  %91 = zext i32 %90 to i64
  %92 = getelementptr inbounds [1000 x %"struct.geometry::types::leanNeighborTriangle_t"], ptr %89, i64 0, i64 %91
  store ptr %92, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #4
  store i32 0, ptr %16, align 4, !tbaa !9
  br label %93

93:                                               ; preds = %165, %82
  %94 = load i32, ptr %16, align 4, !tbaa !9
  %95 = icmp slt i32 %94, 3
  br i1 %95, label %97, label %96

96:                                               ; preds = %93
  store i32 8, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #4
  br label %169

97:                                               ; preds = %93
  %98 = load ptr, ptr %15, align 8, !tbaa !5
  %99 = getelementptr inbounds %"struct.geometry::types::leanNeighborTriangle_t", ptr %98, i32 0, i32 1
  %100 = load i32, ptr %16, align 4, !tbaa !9
  %101 = sext i32 %100 to i64
  %102 = getelementptr inbounds [3 x i32], ptr %99, i64 0, i64 %101
  %103 = load i32, ptr %102, align 4, !tbaa !9
  %104 = load ptr, ptr %8, align 8, !tbaa !5
  %105 = getelementptr inbounds %"struct.geometry::types::gaussMapFace_t", ptr %104, i32 0, i32 1
  %106 = load i32, ptr %105, align 4, !tbaa !14
  %107 = icmp slt i32 %103, %106
  br i1 %107, label %123, label %108

108:                                              ; preds = %97
  %109 = load ptr, ptr %15, align 8, !tbaa !5
  %110 = getelementptr inbounds %"struct.geometry::types::leanNeighborTriangle_t", ptr %109, i32 0, i32 1
  %111 = load i32, ptr %16, align 4, !tbaa !9
  %112 = sext i32 %111 to i64
  %113 = getelementptr inbounds [3 x i32], ptr %110, i64 0, i64 %112
  %114 = load i32, ptr %113, align 4, !tbaa !9
  %115 = load ptr, ptr %8, align 8, !tbaa !5
  %116 = getelementptr inbounds %"struct.geometry::types::gaussMapFace_t", ptr %115, i32 0, i32 1
  %117 = load i32, ptr %116, align 4, !tbaa !14
  %118 = load ptr, ptr %8, align 8, !tbaa !5
  %119 = getelementptr inbounds %"struct.geometry::types::gaussMapFace_t", ptr %118, i32 0, i32 2
  %120 = load i32, ptr %119, align 4, !tbaa !11
  %121 = add i32 %117, %120
  %122 = icmp sge i32 %114, %121
  br i1 %122, label %123, label %164

123:                                              ; preds = %108, %97
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #4
  %124 = load ptr, ptr %15, align 8, !tbaa !5
  %125 = getelementptr inbounds %"struct.geometry::types::leanNeighborTriangle_t", ptr %124, i32 0, i32 0
  %126 = load i32, ptr %16, align 4, !tbaa !9
  %127 = sext i32 %126 to i64
  %128 = getelementptr inbounds [3 x [2 x i32]], ptr @_ZN8geometry4mesh17TriangleGraphBase9edgeVertsE, i64 0, i64 %127
  %129 = getelementptr inbounds [2 x i32], ptr %128, i64 0, i64 0
  %130 = load i32, ptr %129, align 8, !tbaa !9
  %131 = zext i32 %130 to i64
  %132 = getelementptr inbounds [3 x i32], ptr %125, i64 0, i64 %131
  %133 = load i32, ptr %132, align 4, !tbaa !9
  store i32 %133, ptr %17, align 4, !tbaa !9
  %134 = invoke { ptr, i8 } @_ZNSt3setIjSt4lessIjESaIjEE6insertEOj(ptr noundef nonnull align 8 dereferenceable(48) %12, ptr noundef nonnull align 4 dereferenceable(4) %17)
          to label %135 unwind label %156

135:                                              ; preds = %123
  %136 = getelementptr inbounds { ptr, i8 }, ptr %20, i32 0, i32 0
  %137 = extractvalue { ptr, i8 } %134, 0
  store ptr %137, ptr %136, align 8
  %138 = getelementptr inbounds { ptr, i8 }, ptr %20, i32 0, i32 1
  %139 = extractvalue { ptr, i8 } %134, 1
  store i8 %139, ptr %138, align 8
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #4
  %140 = load ptr, ptr %15, align 8, !tbaa !5
  %141 = getelementptr inbounds %"struct.geometry::types::leanNeighborTriangle_t", ptr %140, i32 0, i32 0
  %142 = load i32, ptr %16, align 4, !tbaa !9
  %143 = sext i32 %142 to i64
  %144 = getelementptr inbounds [3 x [2 x i32]], ptr @_ZN8geometry4mesh17TriangleGraphBase9edgeVertsE, i64 0, i64 %143
  %145 = getelementptr inbounds [2 x i32], ptr %144, i64 0, i64 1
  %146 = load i32, ptr %145, align 4, !tbaa !9
  %147 = zext i32 %146 to i64
  %148 = getelementptr inbounds [3 x i32], ptr %141, i64 0, i64 %147
  %149 = load i32, ptr %148, align 4, !tbaa !9
  store i32 %149, ptr %21, align 4, !tbaa !9
  %150 = invoke { ptr, i8 } @_ZNSt3setIjSt4lessIjESaIjEE6insertEOj(ptr noundef nonnull align 8 dereferenceable(48) %12, ptr noundef nonnull align 4 dereferenceable(4) %21)
          to label %151 unwind label %160

151:                                              ; preds = %135
  %152 = getelementptr inbounds { ptr, i8 }, ptr %22, i32 0, i32 0
  %153 = extractvalue { ptr, i8 } %150, 0
  store ptr %153, ptr %152, align 8
  %154 = getelementptr inbounds { ptr, i8 }, ptr %22, i32 0, i32 1
  %155 = extractvalue { ptr, i8 } %150, 1
  store i8 %155, ptr %154, align 8
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #4
  br label %164

156:                                              ; preds = %123
  %157 = landingpad { ptr, i32 }
          cleanup
  %158 = extractvalue { ptr, i32 } %157, 0
  store ptr %158, ptr %18, align 8
  %159 = extractvalue { ptr, i32 } %157, 1
  store i32 %159, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #4
  br label %168

160:                                              ; preds = %135
  %161 = landingpad { ptr, i32 }
          cleanup
  %162 = extractvalue { ptr, i32 } %161, 0
  store ptr %162, ptr %18, align 8
  %163 = extractvalue { ptr, i32 } %161, 1
  store i32 %163, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #4
  br label %168

164:                                              ; preds = %151, %108
  br label %165

165:                                              ; preds = %164
  %166 = load i32, ptr %16, align 4, !tbaa !9
  %167 = add nsw i32 %166, 1
  store i32 %167, ptr %16, align 4, !tbaa !9
  br label %93, !llvm.loop !17

168:                                              ; preds = %160, %156
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #4
  br label %217

169:                                              ; preds = %96
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #4
  br label %170

170:                                              ; preds = %169
  %171 = load i32, ptr %13, align 4, !tbaa !9
  %172 = add i32 %171, 1
  store i32 %172, ptr %13, align 4, !tbaa !9
  br label %75, !llvm.loop !18

173:                                              ; preds = %81
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #4
  store ptr %12, ptr %23, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #4
  %174 = load ptr, ptr %23, align 8, !tbaa !5
  %175 = call ptr @_ZNKSt3setIjSt4lessIjESaIjEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %174) #4
  %176 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator", ptr %24, i32 0, i32 0
  store ptr %175, ptr %176, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #4
  %177 = load ptr, ptr %23, align 8, !tbaa !5
  %178 = call ptr @_ZNKSt3setIjSt4lessIjESaIjEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %177) #4
  %179 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator", ptr %25, i32 0, i32 0
  store ptr %178, ptr %179, align 8
  br label %180

180:                                              ; preds = %209, %173
  %181 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIjES2_(ptr noundef nonnull align 8 dereferenceable(8) %24, ptr noundef nonnull align 8 dereferenceable(8) %25) #4
  br i1 %181, label %183, label %182

182:                                              ; preds = %180
  store i32 11, ptr %11, align 4
  br label %215

183:                                              ; preds = %180
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #4
  %184 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt23_Rb_tree_const_iteratorIjEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %24) #4
  %185 = load i32, ptr %184, align 4, !tbaa !9
  store i32 %185, ptr %26, align 4, !tbaa !9
  %186 = load ptr, ptr %7, align 8, !tbaa !5
  %187 = load i32, ptr %186, align 4, !tbaa !9
  %188 = icmp ugt i32 %187, 49
  br i1 %188, label %189, label %190

189:                                              ; preds = %183
  store i32 11, ptr %11, align 4
  br label %206

190:                                              ; preds = %183
  %191 = load ptr, ptr %5, align 8, !tbaa !5
  %192 = getelementptr inbounds %"struct.geometry::types::gaussMapMesh_t", ptr %191, i32 0, i32 4
  %193 = load i32, ptr %26, align 4, !tbaa !9
  %194 = zext i32 %193 to i64
  %195 = getelementptr inbounds [500 x %class.Vector3], ptr %192, i64 0, i64 %194
  %196 = getelementptr inbounds %"struct.geometry::types::polygon50_t", ptr %0, i32 0, i32 1
  %197 = load ptr, ptr %7, align 8, !tbaa !5
  %198 = load i32, ptr %197, align 4, !tbaa !9
  %199 = zext i32 %198 to i64
  %200 = getelementptr inbounds [50 x %class.Vector3], ptr %196, i64 0, i64 %199
  %201 = invoke noundef nonnull align 4 dereferenceable(12) ptr @_ZN7Vector3aSERKS_(ptr noundef nonnull align 4 dereferenceable(12) %200, ptr noundef nonnull align 4 dereferenceable(12) %195)
          to label %202 unwind label %211

202:                                              ; preds = %190
  %203 = load ptr, ptr %7, align 8, !tbaa !5
  %204 = load i32, ptr %203, align 4, !tbaa !9
  %205 = add i32 %204, 1
  store i32 %205, ptr %203, align 4, !tbaa !9
  store i32 0, ptr %11, align 4
  br label %206

206:                                              ; preds = %202, %189
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #4
  %207 = load i32, ptr %11, align 4
  switch i32 %207, label %215 [
    i32 0, label %208
  ]

208:                                              ; preds = %206
  br label %209

209:                                              ; preds = %208
  %210 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorIjEppEv(ptr noundef nonnull align 8 dereferenceable(8) %24) #4
  br label %180

211:                                              ; preds = %190
  %212 = landingpad { ptr, i32 }
          cleanup
  %213 = extractvalue { ptr, i32 } %212, 0
  store ptr %213, ptr %18, align 8
  %214 = extractvalue { ptr, i32 } %212, 1
  store i32 %214, ptr %19, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #4
  br label %217

215:                                              ; preds = %206, %182
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #4
  br label %216

216:                                              ; preds = %215
  store i32 1, ptr %11, align 4
  call void @_ZNSt3setIjSt4lessIjESaIjEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %12) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %12) #4
  br label %218

217:                                              ; preds = %211, %168
  call void @_ZNSt3setIjSt4lessIjESaIjEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %12) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #4
  br label %219

218:                                              ; preds = %216, %73
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #4
  ret void

219:                                              ; preds = %217
  %220 = load ptr, ptr %18, align 8
  %221 = load i32, ptr %19, align 4
  %222 = insertvalue { ptr, i32 } poison, ptr %220, 0
  %223 = insertvalue { ptr, i32 } %222, i32 %221, 1
  resume { ptr, i32 } %223
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN8geometry5types11polygon50_tC2Ev(ptr noundef nonnull align 4 dereferenceable(604)) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 4 dereferenceable(12) ptr @_ZN7Vector3aSERKS_(ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12)) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt3setIjSt4lessIjESaIjEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i8 } @_ZNSt3setIjSt4lessIjESaIjEE6insertEOj(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) #1 align 2

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNKSt3setIjSt4lessIjESaIjEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48)) #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNKSt3setIjSt4lessIjESaIjEE3endEv(ptr noundef nonnull align 8 dereferenceable(48)) #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIjES2_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt23_Rb_tree_const_iteratorIjEdeEv(ptr noundef nonnull align 8 dereferenceable(8)) #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorIjEppEv(ptr noundef nonnull align 8 dereferenceable(8)) #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt3setIjSt4lessIjESaIjEED2Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #3 align 2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress 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 = { inlinehint mustprogress 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 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 #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++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !10, i64 16}
!12 = !{!"_ZTSN8geometry5types14gaussMapFace_tE", !13, i64 0, !10, i64 12, !10, i64 16}
!13 = !{!"_ZTS7Vector3", !7, i64 0}
!14 = !{!12, !10, i64 12}
!15 = distinct !{!15, !16}
!16 = !{!"llvm.loop.mustprogress"}
!17 = distinct !{!17, !16}
!18 = distinct !{!18, !16}


; 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.geometry::types::polygon50_t" = type { i32, [50 x %class.Vector3] }
%class.Vector3 = type { [3 x float] }
%"class.std::set" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<unsigned int, unsigned int, std::_Identity<unsigned int>, std::less<unsigned int>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<unsigned int, unsigned int, std::_Identity<unsigned int>, std::less<unsigned int>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"struct.std::_Rb_tree_const_iterator" = type { ptr }
%"struct.geometry::types::gaussMapFace_t" = type { %class.Vector3, i32, i32 }
%"struct.geometry::types::leanNeighborTriangle_t" = type { [3 x i32], [3 x i32] }

@_ZN8geometry4mesh17TriangleGraphBase9edgeVertsE = external local_unnamed_addr constant [3 x [2 x i32]], align 16

; 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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN8geometry4mesh15polygonFromFaceERKNS_5types14gaussMapMesh_tEj(ptr dead_on_unwind noalias nonnull writable sret(%"struct.geometry::types::polygon50_t") align 4 %0, ptr noundef nonnull align 4 dereferenceable(50012) %1, i32 noundef %2) local_unnamed_addr #1 personality ptr @__gxx_personality_v0 {
  %4 = alloca %"class.std::set", align 8
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  %8 = alloca %"struct.std::_Rb_tree_const_iterator", align 8
  tail call void @_ZN8geometry5types11polygon50_tC2Ev(ptr noundef nonnull align 4 dereferenceable(604) %0)
  store i32 0, ptr %0, align 4, !tbaa !5
  %9 = getelementptr inbounds i8, ptr %1, i64 30012
  %10 = zext i32 %2 to i64
  %11 = getelementptr inbounds [1000 x %"struct.geometry::types::gaussMapFace_t"], ptr %9, i64 0, i64 %10
  %12 = getelementptr inbounds i8, ptr %11, i64 16
  %13 = load i32, ptr %12, align 4, !tbaa !9
  %14 = icmp eq i32 %13, 1
  br i1 %14, label %.preheader, label %50

.preheader:                                       ; preds = %3
  %15 = getelementptr inbounds i8, ptr %1, i64 12
  %16 = getelementptr inbounds i8, ptr %11, i64 12
  %17 = getelementptr inbounds i8, ptr %1, i64 24012
  %18 = getelementptr inbounds i8, ptr %0, i64 4
  %19 = load i32, ptr %16, align 4, !tbaa !12
  %20 = zext i32 %19 to i64
  %21 = getelementptr inbounds [1000 x %"struct.geometry::types::leanNeighborTriangle_t"], ptr %15, i64 0, i64 %20
  %22 = load i32, ptr %21, align 4, !tbaa !5
  %23 = zext i32 %22 to i64
  %24 = getelementptr inbounds [500 x %class.Vector3], ptr %17, i64 0, i64 %23
  %25 = tail call noundef nonnull align 4 dereferenceable(12) ptr @_ZN7Vector3aSERKS_(ptr noundef nonnull align 4 dereferenceable(12) %18, ptr noundef nonnull align 4 dereferenceable(12) %24)
  %26 = load i32, ptr %0, align 4, !tbaa !5
  %27 = add i32 %26, 1
  store i32 %27, ptr %0, align 4, !tbaa !5
  %28 = load i32, ptr %16, align 4, !tbaa !12
  %29 = zext i32 %28 to i64
  %30 = getelementptr inbounds [1000 x %"struct.geometry::types::leanNeighborTriangle_t"], ptr %15, i64 0, i64 %29, i32 0, i64 1
  %31 = load i32, ptr %30, align 4, !tbaa !5
  %32 = zext i32 %31 to i64
  %33 = getelementptr inbounds [500 x %class.Vector3], ptr %17, i64 0, i64 %32
  %34 = zext i32 %27 to i64
  %35 = getelementptr inbounds [50 x %class.Vector3], ptr %18, i64 0, i64 %34
  %36 = tail call noundef nonnull align 4 dereferenceable(12) ptr @_ZN7Vector3aSERKS_(ptr noundef nonnull align 4 dereferenceable(12) %35, ptr noundef nonnull align 4 dereferenceable(12) %33)
  %37 = load i32, ptr %0, align 4, !tbaa !5
  %38 = add i32 %37, 1
  store i32 %38, ptr %0, align 4, !tbaa !5
  %39 = load i32, ptr %16, align 4, !tbaa !12
  %40 = zext i32 %39 to i64
  %41 = getelementptr inbounds [1000 x %"struct.geometry::types::leanNeighborTriangle_t"], ptr %15, i64 0, i64 %40, i32 0, i64 2
  %42 = load i32, ptr %41, align 4, !tbaa !5
  %43 = zext i32 %42 to i64
  %44 = getelementptr inbounds [500 x %class.Vector3], ptr %17, i64 0, i64 %43
  %45 = zext i32 %38 to i64
  %46 = getelementptr inbounds [50 x %class.Vector3], ptr %18, i64 0, i64 %45
  %47 = tail call noundef nonnull align 4 dereferenceable(12) ptr @_ZN7Vector3aSERKS_(ptr noundef nonnull align 4 dereferenceable(12) %46, ptr noundef nonnull align 4 dereferenceable(12) %44)
  %48 = load i32, ptr %0, align 4, !tbaa !5
  %49 = add i32 %48, 1
  store i32 %49, ptr %0, align 4, !tbaa !5
  br label %.loopexit

50:                                               ; preds = %3
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %4) #4
  call void @_ZNSt3setIjSt4lessIjESaIjEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  %51 = load i32, ptr %12, align 4, !tbaa !9
  %.not61 = icmp eq i32 %51, 0
  br i1 %.not61, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %50
  %52 = getelementptr inbounds i8, ptr %11, i64 12
  %53 = getelementptr inbounds i8, ptr %1, i64 12
  %54 = load i32, ptr @_ZN8geometry4mesh17TriangleGraphBase9edgeVertsE, align 16
  %55 = zext i32 %54 to i64
  %56 = load i32, ptr getelementptr inbounds (i8, ptr @_ZN8geometry4mesh17TriangleGraphBase9edgeVertsE, i64 4), align 4
  %57 = zext i32 %56 to i64
  %58 = load i32, ptr getelementptr inbounds (i8, ptr @_ZN8geometry4mesh17TriangleGraphBase9edgeVertsE, i64 8), align 8
  %59 = zext i32 %58 to i64
  %60 = load i32, ptr getelementptr inbounds (i8, ptr @_ZN8geometry4mesh17TriangleGraphBase9edgeVertsE, i64 12), align 4
  %61 = zext i32 %60 to i64
  %62 = load i32, ptr getelementptr inbounds (i8, ptr @_ZN8geometry4mesh17TriangleGraphBase9edgeVertsE, i64 16), align 16
  %63 = zext i32 %62 to i64
  %64 = load i32, ptr getelementptr inbounds (i8, ptr @_ZN8geometry4mesh17TriangleGraphBase9edgeVertsE, i64 20), align 4
  %65 = zext i32 %64 to i64
  br label %71

._crit_edge:                                      ; preds = %128, %50
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #4
  %66 = call ptr @_ZNKSt3setIjSt4lessIjESaIjEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  store ptr %66, ptr %7, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #4
  %67 = call ptr @_ZNKSt3setIjSt4lessIjESaIjEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  store ptr %67, ptr %8, align 8
  %68 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIjES2_(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8) #4
  br i1 %68, label %.lr.ph58, label %.critedge

.lr.ph58:                                         ; preds = %._crit_edge
  %69 = getelementptr inbounds i8, ptr %1, i64 24012
  %70 = getelementptr inbounds i8, ptr %0, i64 4
  br label %132

71:                                               ; preds = %.lr.ph, %128
  %72 = phi i32 [ %51, %.lr.ph ], [ %129, %128 ]
  %.04556 = phi i32 [ 0, %.lr.ph ], [ %130, %128 ]
  %73 = load i32, ptr %52, align 4, !tbaa !12
  %74 = add i32 %73, %.04556
  %75 = zext i32 %74 to i64
  %76 = getelementptr inbounds [1000 x %"struct.geometry::types::leanNeighborTriangle_t"], ptr %53, i64 0, i64 %75
  %77 = getelementptr inbounds i8, ptr %76, i64 12
  %78 = load i32, ptr %77, align 4, !tbaa !5
  %79 = icmp sge i32 %78, %73
  %80 = add i32 %72, %73
  %.not = icmp slt i32 %78, %80
  %or.cond = and i1 %79, %.not
  br i1 %or.cond, label %94, label %81

81:                                               ; preds = %71
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #4
  %82 = getelementptr inbounds [3 x i32], ptr %76, i64 0, i64 %55
  %83 = load i32, ptr %82, align 4, !tbaa !5
  store i32 %83, ptr %5, align 4, !tbaa !5
  %84 = invoke { ptr, i8 } @_ZNSt3setIjSt4lessIjESaIjEE6insertEOj(ptr noundef nonnull align 8 dereferenceable(48) %4, ptr noundef nonnull align 4 dereferenceable(4) %5)
          to label %85 unwind label %90

85:                                               ; preds = %81
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #4
  %86 = getelementptr inbounds [3 x i32], ptr %76, i64 0, i64 %57
  %87 = load i32, ptr %86, align 4, !tbaa !5
  store i32 %87, ptr %6, align 4, !tbaa !5
  %88 = invoke { ptr, i8 } @_ZNSt3setIjSt4lessIjESaIjEE6insertEOj(ptr noundef nonnull align 8 dereferenceable(48) %4, ptr noundef nonnull align 4 dereferenceable(4) %6)
          to label %89 unwind label %92

89:                                               ; preds = %85
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #4
  %.pre = load i32, ptr %52, align 4, !tbaa !12
  br label %94

90:                                               ; preds = %119, %102, %81
  %91 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #4
  br label %150

92:                                               ; preds = %123, %106, %85
  %93 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #4
  br label %150

94:                                               ; preds = %71, %89
  %95 = phi i32 [ %.pre, %89 ], [ %73, %71 ]
  %96 = getelementptr inbounds i8, ptr %76, i64 16
  %97 = load i32, ptr %96, align 4, !tbaa !5
  %98 = icmp slt i32 %97, %95
  br i1 %98, label %102, label %99

99:                                               ; preds = %94
  %100 = load i32, ptr %12, align 4, !tbaa !9
  %101 = add i32 %100, %95
  %.not.1 = icmp slt i32 %97, %101
  br i1 %.not.1, label %111, label %102

102:                                              ; preds = %99, %94
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #4
  %103 = getelementptr inbounds [3 x i32], ptr %76, i64 0, i64 %59
  %104 = load i32, ptr %103, align 4, !tbaa !5
  store i32 %104, ptr %5, align 4, !tbaa !5
  %105 = invoke { ptr, i8 } @_ZNSt3setIjSt4lessIjESaIjEE6insertEOj(ptr noundef nonnull align 8 dereferenceable(48) %4, ptr noundef nonnull align 4 dereferenceable(4) %5)
          to label %106 unwind label %90

106:                                              ; preds = %102
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #4
  %107 = getelementptr inbounds [3 x i32], ptr %76, i64 0, i64 %61
  %108 = load i32, ptr %107, align 4, !tbaa !5
  store i32 %108, ptr %6, align 4, !tbaa !5
  %109 = invoke { ptr, i8 } @_ZNSt3setIjSt4lessIjESaIjEE6insertEOj(ptr noundef nonnull align 8 dereferenceable(48) %4, ptr noundef nonnull align 4 dereferenceable(4) %6)
          to label %110 unwind label %92

110:                                              ; preds = %106
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #4
  %.pre64 = load i32, ptr %52, align 4, !tbaa !12
  br label %111

111:                                              ; preds = %110, %99
  %112 = phi i32 [ %.pre64, %110 ], [ %95, %99 ]
  %113 = getelementptr inbounds i8, ptr %76, i64 20
  %114 = load i32, ptr %113, align 4, !tbaa !5
  %115 = icmp slt i32 %114, %112
  br i1 %115, label %119, label %116

116:                                              ; preds = %111
  %117 = load i32, ptr %12, align 4, !tbaa !9
  %118 = add i32 %117, %112
  %.not.2 = icmp slt i32 %114, %118
  br i1 %.not.2, label %128, label %119

119:                                              ; preds = %116, %111
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #4
  %120 = getelementptr inbounds [3 x i32], ptr %76, i64 0, i64 %63
  %121 = load i32, ptr %120, align 4, !tbaa !5
  store i32 %121, ptr %5, align 4, !tbaa !5
  %122 = invoke { ptr, i8 } @_ZNSt3setIjSt4lessIjESaIjEE6insertEOj(ptr noundef nonnull align 8 dereferenceable(48) %4, ptr noundef nonnull align 4 dereferenceable(4) %5)
          to label %123 unwind label %90

123:                                              ; preds = %119
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #4
  %124 = getelementptr inbounds [3 x i32], ptr %76, i64 0, i64 %65
  %125 = load i32, ptr %124, align 4, !tbaa !5
  store i32 %125, ptr %6, align 4, !tbaa !5
  %126 = invoke { ptr, i8 } @_ZNSt3setIjSt4lessIjESaIjEE6insertEOj(ptr noundef nonnull align 8 dereferenceable(48) %4, ptr noundef nonnull align 4 dereferenceable(4) %6)
          to label %127 unwind label %92

127:                                              ; preds = %123
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #4
  %.pre65 = load i32, ptr %12, align 4, !tbaa !9
  br label %128

128:                                              ; preds = %127, %116
  %129 = phi i32 [ %.pre65, %127 ], [ %117, %116 ]
  %130 = add nuw i32 %.04556, 1
  %131 = icmp ult i32 %130, %129
  br i1 %131, label %71, label %._crit_edge, !llvm.loop !13

132:                                              ; preds = %.lr.ph58, %143
  %133 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt23_Rb_tree_const_iteratorIjEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #4
  %134 = load i32, ptr %0, align 4, !tbaa !5
  %135 = icmp ult i32 %134, 50
  br i1 %135, label %136, label %.critedge

136:                                              ; preds = %132
  %137 = load i32, ptr %133, align 4, !tbaa !5
  %138 = zext i32 %137 to i64
  %139 = getelementptr inbounds [500 x %class.Vector3], ptr %69, i64 0, i64 %138
  %140 = zext nneg i32 %134 to i64
  %141 = getelementptr inbounds [50 x %class.Vector3], ptr %70, i64 0, i64 %140
  %142 = invoke noundef nonnull align 4 dereferenceable(12) ptr @_ZN7Vector3aSERKS_(ptr noundef nonnull align 4 dereferenceable(12) %141, ptr noundef nonnull align 4 dereferenceable(12) %139)
          to label %143 unwind label %148

143:                                              ; preds = %136
  %144 = load i32, ptr %0, align 4, !tbaa !5
  %145 = add i32 %144, 1
  store i32 %145, ptr %0, align 4, !tbaa !5
  %146 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorIjEppEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #4
  %147 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIjES2_(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8) #4
  br i1 %147, label %132, label %.critedge

148:                                              ; preds = %136
  %149 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #4
  br label %150

.critedge:                                        ; preds = %143, %132, %._crit_edge
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #4
  call void @_ZNSt3setIjSt4lessIjESaIjEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %4) #4
  br label %.loopexit

150:                                              ; preds = %90, %92, %148
  %.pn.pn = phi { ptr, i32 } [ %149, %148 ], [ %93, %92 ], [ %91, %90 ]
  call void @_ZNSt3setIjSt4lessIjESaIjEED2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #4
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %4) #4
  resume { ptr, i32 } %.pn.pn

.loopexit:                                        ; preds = %.preheader, %.critedge
  ret void
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN8geometry5types11polygon50_tC2Ev(ptr noundef nonnull align 4 dereferenceable(604)) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 4 dereferenceable(12) ptr @_ZN7Vector3aSERKS_(ptr noundef nonnull align 4 dereferenceable(12), ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt3setIjSt4lessIjESaIjEEC2Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, i8 } @_ZNSt3setIjSt4lessIjESaIjEE6insertEOj(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #1 align 2

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNKSt3setIjSt4lessIjESaIjEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local ptr @_ZNKSt3setIjSt4lessIjESaIjEE3endEv(ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorIjES2_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt23_Rb_tree_const_iteratorIjEdeEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorIjEppEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt3setIjSt4lessIjESaIjEED2Ev(ptr noundef nonnull align 8 dereferenceable(48)) unnamed_addr #3 align 2

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress 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 = { inlinehint mustprogress 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 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 #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++ TBAA"}
!9 = !{!10, !6, i64 16}
!10 = !{!"_ZTSN8geometry5types14gaussMapFace_tE", !11, i64 0, !6, i64 12, !6, i64 16}
!11 = !{!"_ZTS7Vector3", !7, i64 0}
!12 = !{!10, !6, i64 12}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}


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