; LLVM IR from SourangshuGhosh/Fluid-Simulation-for-Computer-Graphics :: src (spatialpointgrid)

; 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.GridIndex = type { i32, i32, i32 }
%class.AABB = type { %"class.vmath::vec3", double, double, double }
%"class.vmath::vec3" = type { float, float, float }
%struct.GridPoint = type { %"class.vmath::vec3", %struct.GridPointReference }
%struct.GridPointReference = type { i32 }
%"struct.SpatialPointGrid::CellNode" = type { i32, i32 }
%class.SpatialPointGrid = type { i32, i32, i32, double, %"class.std::vector", %"class.std::vector.0", %class.Array3d, %class.AABB }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<GridPoint, std::allocator<GridPoint>>::_Vector_impl" }
%"struct.std::_Vector_base<GridPoint, std::allocator<GridPoint>>::_Vector_impl" = type { %"struct.std::_Vector_base<GridPoint, std::allocator<GridPoint>>::_Vector_impl_data" }
%"struct.std::_Vector_base<GridPoint, std::allocator<GridPoint>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.Array3d = type { i32, i32, i32, ptr, i8, %"struct.SpatialPointGrid::CellNode", i32 }

declare i32 @__gxx_personality_v0(...)

declare void @_ZN5vmath4vec3C1Ev(ptr noundef nonnull align 4 dereferenceable(12)) unnamed_addr #0

; Function Attrs: nounwind
declare void @_ZN5vmath4vec3D1Ev(ptr noundef nonnull align 4 dereferenceable(12)) unnamed_addr #1

; Function Attrs: nounwind
declare void @_ZN4AABBD1Ev(ptr noundef nonnull align 8 dereferenceable(40)) unnamed_addr #1

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIN5vmath4vec3ESaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(12)) #4 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(16) ptr @_ZNSt6vectorI9GridPointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) #2 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN9GridPointD2Ev(ptr noundef nonnull align 4 dereferenceable(16)) unnamed_addr #6 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN16SpatialPointGrid21queryPointsInsideAABBE4AABBRSt6vectorIN5vmath4vec3ESaIS3_EE(ptr noundef nonnull align 8 dereferenceable(152) %0, ptr noundef %1, ptr noundef nonnull align 8 dereferenceable(24) %2) #4 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca %struct.GridIndex, align 4
  %8 = alloca %struct.GridIndex, align 4
  %9 = alloca %class.AABB, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca %"class.vmath::vec3", align 4
  %13 = alloca %struct.GridPoint, align 4
  %14 = alloca %"struct.SpatialPointGrid::CellNode", align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca %"struct.SpatialPointGrid::CellNode", align 4
  %20 = alloca %"struct.SpatialPointGrid::CellNode", align 4
  %21 = alloca i32, align 4
  %22 = alloca %"class.vmath::vec3", align 4
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  store ptr %2, ptr %6, align 8, !tbaa !5
  %23 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 12, ptr %7) #8
  call void @_ZN9GridIndexC2Ev(ptr noundef nonnull align 4 dereferenceable(12) %7)
  call void @llvm.lifetime.start.p0(i64 12, ptr %8) #8
  call void @_ZN9GridIndexC2Ev(ptr noundef nonnull align 4 dereferenceable(12) %8)
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %9, ptr align 8 %1, i64 40, i1 false), !tbaa.struct !9
  %24 = getelementptr inbounds %class.SpatialPointGrid, ptr %23, i32 0, i32 3
  %25 = load double, ptr %24, align 8, !tbaa !14
  %26 = getelementptr inbounds %class.SpatialPointGrid, ptr %23, i32 0, i32 0
  %27 = load i32, ptr %26, align 8, !tbaa !30
  %28 = getelementptr inbounds %class.SpatialPointGrid, ptr %23, i32 0, i32 1
  %29 = load i32, ptr %28, align 4, !tbaa !31
  %30 = getelementptr inbounds %class.SpatialPointGrid, ptr %23, i32 0, i32 2
  %31 = load i32, ptr %30, align 8, !tbaa !32
  invoke void @_ZN6Grid3d18getGridIndexBoundsE4AABBdiiiP9GridIndexS2_(ptr noundef %9, double noundef %25, i32 noundef %27, i32 noundef %29, i32 noundef %31, ptr noundef %7, ptr noundef %8)
          to label %32 unwind label %43

32:                                               ; preds = %3
  call void @_ZN4AABBD1Ev(ptr noundef nonnull align 8 dereferenceable(40) %9) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr %12) #8
  call void @_ZN5vmath4vec3C1Ev(ptr noundef nonnull align 4 dereferenceable(12) %12)
  call void @llvm.lifetime.start.p0(i64 16, ptr %13) #8
  invoke void @_ZN9GridPointC2Ev(ptr noundef nonnull align 4 dereferenceable(16) %13)
          to label %33 unwind label %47

33:                                               ; preds = %32
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #8
  invoke void @_ZN16SpatialPointGrid8CellNodeC2Ev(ptr noundef nonnull align 4 dereferenceable(8) %14)
          to label %34 unwind label %51

34:                                               ; preds = %33
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #8
  %35 = getelementptr inbounds %struct.GridIndex, ptr %7, i32 0, i32 2
  %36 = load i32, ptr %35, align 4, !tbaa !33
  store i32 %36, ptr %15, align 4, !tbaa !35
  br label %37

37:                                               ; preds = %145, %34
  %38 = load i32, ptr %15, align 4, !tbaa !35
  %39 = getelementptr inbounds %struct.GridIndex, ptr %8, i32 0, i32 2
  %40 = load i32, ptr %39, align 4, !tbaa !33
  %41 = icmp sle i32 %38, %40
  br i1 %41, label %55, label %42

42:                                               ; preds = %37
  store i32 2, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #8
  br label %148

43:                                               ; preds = %3
  %44 = landingpad { ptr, i32 }
          cleanup
  %45 = extractvalue { ptr, i32 } %44, 0
  store ptr %45, ptr %10, align 8
  %46 = extractvalue { ptr, i32 } %44, 1
  store i32 %46, ptr %11, align 4
  call void @_ZN4AABBD1Ev(ptr noundef nonnull align 8 dereferenceable(40) %9) #8
  br label %151

47:                                               ; preds = %32
  %48 = landingpad { ptr, i32 }
          cleanup
  %49 = extractvalue { ptr, i32 } %48, 0
  store ptr %49, ptr %10, align 8
  %50 = extractvalue { ptr, i32 } %48, 1
  store i32 %50, ptr %11, align 4
  br label %150

51:                                               ; preds = %33
  %52 = landingpad { ptr, i32 }
          cleanup
  %53 = extractvalue { ptr, i32 } %52, 0
  store ptr %53, ptr %10, align 8
  %54 = extractvalue { ptr, i32 } %52, 1
  store i32 %54, ptr %11, align 4
  br label %149

55:                                               ; preds = %37
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #8
  %56 = getelementptr inbounds %struct.GridIndex, ptr %7, i32 0, i32 1
  %57 = load i32, ptr %56, align 4, !tbaa !36
  store i32 %57, ptr %17, align 4, !tbaa !35
  br label %58

58:                                               ; preds = %141, %55
  %59 = load i32, ptr %17, align 4, !tbaa !35
  %60 = getelementptr inbounds %struct.GridIndex, ptr %8, i32 0, i32 1
  %61 = load i32, ptr %60, align 4, !tbaa !36
  %62 = icmp sle i32 %59, %61
  br i1 %62, label %64, label %63

63:                                               ; preds = %58
  store i32 5, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #8
  br label %144

64:                                               ; preds = %58
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #8
  %65 = getelementptr inbounds %struct.GridIndex, ptr %7, i32 0, i32 0
  %66 = load i32, ptr %65, align 4, !tbaa !37
  store i32 %66, ptr %18, align 4, !tbaa !35
  br label %67

67:                                               ; preds = %136, %64
  %68 = load i32, ptr %18, align 4, !tbaa !35
  %69 = getelementptr inbounds %struct.GridIndex, ptr %8, i32 0, i32 0
  %70 = load i32, ptr %69, align 4, !tbaa !37
  %71 = icmp sle i32 %68, %70
  br i1 %71, label %73, label %72

72:                                               ; preds = %67
  store i32 8, ptr %16, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #8
  br label %140

73:                                               ; preds = %67
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #8
  %74 = getelementptr inbounds %class.SpatialPointGrid, ptr %23, i32 0, i32 6
  %75 = load i32, ptr %18, align 4, !tbaa !35
  %76 = load i32, ptr %17, align 4, !tbaa !35
  %77 = load i32, ptr %15, align 4, !tbaa !35
  %78 = invoke i64 @_ZN7Array3dIN16SpatialPointGrid8CellNodeEEclEiii(ptr noundef nonnull align 8 dereferenceable(40) %74, i32 noundef %75, i32 noundef %76, i32 noundef %77)
          to label %79 unwind label %101

79:                                               ; preds = %73
  store i64 %78, ptr %19, align 4
  %80 = getelementptr inbounds %"struct.SpatialPointGrid::CellNode", ptr %19, i32 0, i32 1
  %81 = load i32, ptr %80, align 4, !tbaa !38
  %82 = icmp sgt i32 %81, 0
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #8
  br i1 %82, label %83, label %135

83:                                               ; preds = %79
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #8
  %84 = getelementptr inbounds %class.SpatialPointGrid, ptr %23, i32 0, i32 6
  %85 = load i32, ptr %18, align 4, !tbaa !35
  %86 = load i32, ptr %17, align 4, !tbaa !35
  %87 = load i32, ptr %15, align 4, !tbaa !35
  %88 = invoke i64 @_ZN7Array3dIN16SpatialPointGrid8CellNodeEEclEiii(ptr noundef nonnull align 8 dereferenceable(40) %84, i32 noundef %85, i32 noundef %86, i32 noundef %87)
          to label %89 unwind label %105

89:                                               ; preds = %83
  store i64 %88, ptr %20, align 4
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %14, ptr align 4 %20, i64 8, i1 false), !tbaa.struct !39
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #8
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #8
  %90 = getelementptr inbounds %"struct.SpatialPointGrid::CellNode", ptr %14, i32 0, i32 0
  %91 = load i32, ptr %90, align 4, !tbaa !40
  store i32 %91, ptr %21, align 4, !tbaa !35
  br label %92

92:                                               ; preds = %130, %89
  %93 = load i32, ptr %21, align 4, !tbaa !35
  %94 = getelementptr inbounds %"struct.SpatialPointGrid::CellNode", ptr %14, i32 0, i32 0
  %95 = load i32, ptr %94, align 4, !tbaa !40
  %96 = getelementptr inbounds %"struct.SpatialPointGrid::CellNode", ptr %14, i32 0, i32 1
  %97 = load i32, ptr %96, align 4, !tbaa !38
  %98 = add nsw i32 %95, %97
  %99 = icmp slt i32 %93, %98
  br i1 %99, label %109, label %100

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

101:                                              ; preds = %73
  %102 = landingpad { ptr, i32 }
          cleanup
  %103 = extractvalue { ptr, i32 } %102, 0
  store ptr %103, ptr %10, align 8
  %104 = extractvalue { ptr, i32 } %102, 1
  store i32 %104, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #8
  br label %139

105:                                              ; preds = %83
  %106 = landingpad { ptr, i32 }
          cleanup
  %107 = extractvalue { ptr, i32 } %106, 0
  store ptr %107, ptr %10, align 8
  %108 = extractvalue { ptr, i32 } %106, 1
  store i32 %108, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #8
  br label %139

109:                                              ; preds = %92
  %110 = getelementptr inbounds %class.SpatialPointGrid, ptr %23, i32 0, i32 4
  %111 = load i32, ptr %21, align 4, !tbaa !35
  %112 = sext i32 %111 to i64
  %113 = call noundef nonnull align 4 dereferenceable(16) ptr @_ZNSt6vectorI9GridPointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %110, i64 noundef %112) #8
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %13, ptr align 4 %113, i64 16, i1 false), !tbaa.struct !41
  %114 = getelementptr inbounds %struct.GridPoint, ptr %13, i32 0, i32 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %22, ptr align 4 %114, i64 12, i1 false), !tbaa.struct !42
  %115 = invoke noundef zeroext i1 @_ZN4AABB13isPointInsideEN5vmath4vec3E(ptr noundef nonnull align 8 dereferenceable(40) %1, ptr noundef %22)
          to label %116 unwind label %121

116:                                              ; preds = %109
  call void @_ZN5vmath4vec3D1Ev(ptr noundef nonnull align 4 dereferenceable(12) %22) #8
  br i1 %115, label %117, label %129

117:                                              ; preds = %116
  %118 = load ptr, ptr %6, align 8, !tbaa !5
  %119 = getelementptr inbounds %struct.GridPoint, ptr %13, i32 0, i32 0
  invoke void @_ZNSt6vectorIN5vmath4vec3ESaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %118, ptr noundef nonnull align 4 dereferenceable(12) %119)
          to label %120 unwind label %125

120:                                              ; preds = %117
  br label %129

121:                                              ; preds = %109
  %122 = landingpad { ptr, i32 }
          cleanup
  %123 = extractvalue { ptr, i32 } %122, 0
  store ptr %123, ptr %10, align 8
  %124 = extractvalue { ptr, i32 } %122, 1
  store i32 %124, ptr %11, align 4
  call void @_ZN5vmath4vec3D1Ev(ptr noundef nonnull align 4 dereferenceable(12) %22) #8
  br label %133

125:                                              ; preds = %117
  %126 = landingpad { ptr, i32 }
          cleanup
  %127 = extractvalue { ptr, i32 } %126, 0
  store ptr %127, ptr %10, align 8
  %128 = extractvalue { ptr, i32 } %126, 1
  store i32 %128, ptr %11, align 4
  br label %133

129:                                              ; preds = %120, %116
  br label %130

130:                                              ; preds = %129
  %131 = load i32, ptr %21, align 4, !tbaa !35
  %132 = add nsw i32 %131, 1
  store i32 %132, ptr %21, align 4, !tbaa !35
  br label %92, !llvm.loop !43

133:                                              ; preds = %125, %121
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #8
  br label %139

134:                                              ; preds = %100
  br label %135

135:                                              ; preds = %134, %79
  br label %136

136:                                              ; preds = %135
  %137 = load i32, ptr %18, align 4, !tbaa !35
  %138 = add nsw i32 %137, 1
  store i32 %138, ptr %18, align 4, !tbaa !35
  br label %67, !llvm.loop !45

139:                                              ; preds = %133, %105, %101
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #8
  br label %149

140:                                              ; preds = %72
  br label %141

141:                                              ; preds = %140
  %142 = load i32, ptr %17, align 4, !tbaa !35
  %143 = add nsw i32 %142, 1
  store i32 %143, ptr %17, align 4, !tbaa !35
  br label %58, !llvm.loop !46

144:                                              ; preds = %63
  br label %145

145:                                              ; preds = %144
  %146 = load i32, ptr %15, align 4, !tbaa !35
  %147 = add nsw i32 %146, 1
  store i32 %147, ptr %15, align 4, !tbaa !35
  br label %37, !llvm.loop !47

148:                                              ; preds = %42
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #8
  call void @_ZN9GridPointD2Ev(ptr noundef nonnull align 4 dereferenceable(16) %13) #8
  call void @llvm.lifetime.end.p0(i64 16, ptr %13) #8
  call void @_ZN5vmath4vec3D1Ev(ptr noundef nonnull align 4 dereferenceable(12) %12) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr %12) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr %8) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr %7) #8
  ret void

149:                                              ; preds = %139, %51
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #8
  call void @_ZN9GridPointD2Ev(ptr noundef nonnull align 4 dereferenceable(16) %13) #8
  br label %150

150:                                              ; preds = %149, %47
  call void @llvm.lifetime.end.p0(i64 16, ptr %13) #8
  call void @_ZN5vmath4vec3D1Ev(ptr noundef nonnull align 4 dereferenceable(12) %12) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr %12) #8
  br label %151

151:                                              ; preds = %150, %43
  call void @llvm.lifetime.end.p0(i64 12, ptr %8) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr %7) #8
  br label %152

152:                                              ; preds = %151
  %153 = load ptr, ptr %10, align 8
  %154 = load i32, ptr %11, align 4
  %155 = insertvalue { ptr, i32 } poison, ptr %153, 0
  %156 = insertvalue { ptr, i32 } %155, i32 %154, 1
  resume { ptr, i32 } %156
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN9GridIndexC2Ev(ptr noundef nonnull align 4 dereferenceable(12)) unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN6Grid3d18getGridIndexBoundsE4AABBdiiiP9GridIndexS2_(ptr noundef, double noundef, i32 noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef) #7

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

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_ZN7Array3dIN16SpatialPointGrid8CellNodeEEclEiii(ptr noundef nonnull align 8 dereferenceable(40), i32 noundef, i32 noundef, i32 noundef) #4 align 2

declare noundef zeroext i1 @_ZN4AABB13isPointInsideEN5vmath4vec3E(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef) #0

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 "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 = { 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 #3 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { 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 #5 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #6 = { inlinehint 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 #7 = { 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 #8 = { 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 = !{i64 0, i64 4, !10, i64 4, i64 4, !10, i64 8, i64 4, !10, i64 16, i64 8, !12, i64 24, i64 8, !12, i64 32, i64 8, !12}
!10 = !{!11, !11, i64 0}
!11 = !{!"float", !7, i64 0}
!12 = !{!13, !13, i64 0}
!13 = !{!"double", !7, i64 0}
!14 = !{!15, !13, i64 16}
!15 = !{!"_ZTS16SpatialPointGrid", !16, i64 0, !16, i64 4, !16, i64 8, !13, i64 16, !17, i64 24, !21, i64 48, !25, i64 72, !28, i64 112}
!16 = !{!"int", !7, i64 0}
!17 = !{!"_ZTSSt6vectorI9GridPointSaIS0_EE", !18, i64 0}
!18 = !{!"_ZTSSt12_Vector_baseI9GridPointSaIS0_EE", !19, i64 0}
!19 = !{!"_ZTSNSt12_Vector_baseI9GridPointSaIS0_EE12_Vector_implE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseI9GridPointSaIS0_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!21 = !{!"_ZTSSt6vectorIiSaIiEE", !22, i64 0}
!22 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !23, i64 0}
!23 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !24, i64 0}
!24 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!25 = !{!"_ZTS7Array3dIN16SpatialPointGrid8CellNodeEE", !16, i64 0, !16, i64 4, !16, i64 8, !6, i64 16, !26, i64 24, !27, i64 28, !16, i64 36}
!26 = !{!"bool", !7, i64 0}
!27 = !{!"_ZTSN16SpatialPointGrid8CellNodeE", !16, i64 0, !16, i64 4}
!28 = !{!"_ZTS4AABB", !29, i64 0, !13, i64 16, !13, i64 24, !13, i64 32}
!29 = !{!"_ZTSN5vmath4vec3E", !11, i64 0, !11, i64 4, !11, i64 8}
!30 = !{!15, !16, i64 0}
!31 = !{!15, !16, i64 4}
!32 = !{!15, !16, i64 8}
!33 = !{!34, !16, i64 8}
!34 = !{!"_ZTS9GridIndex", !16, i64 0, !16, i64 4, !16, i64 8}
!35 = !{!16, !16, i64 0}
!36 = !{!34, !16, i64 4}
!37 = !{!34, !16, i64 0}
!38 = !{!27, !16, i64 4}
!39 = !{i64 0, i64 4, !35, i64 4, i64 4, !35}
!40 = !{!27, !16, i64 0}
!41 = !{i64 0, i64 4, !10, i64 4, i64 4, !10, i64 8, i64 4, !10, i64 12, i64 4, !35}
!42 = !{i64 0, i64 4, !10, i64 4, i64 4, !10, i64 8, i64 4, !10}
!43 = distinct !{!43, !44}
!44 = !{!"llvm.loop.mustprogress"}
!45 = distinct !{!45, !44}
!46 = distinct !{!46, !44}
!47 = distinct !{!47, !44}


; 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.GridIndex = type { i32, i32, i32 }
%class.AABB = type { %"class.vmath::vec3", double, double, double }
%"class.vmath::vec3" = type { float, float, float }
%struct.GridPoint = type { %"class.vmath::vec3", %struct.GridPointReference }
%struct.GridPointReference = type { i32 }
%"struct.SpatialPointGrid::CellNode" = type { i32, i32 }

declare i32 @__gxx_personality_v0(...)

declare void @_ZN5vmath4vec3C1Ev(ptr noundef nonnull align 4 dereferenceable(12)) unnamed_addr #0

; Function Attrs: nounwind
declare void @_ZN5vmath4vec3D1Ev(ptr noundef nonnull align 4 dereferenceable(12)) unnamed_addr #1

; Function Attrs: nounwind
declare void @_ZN4AABBD1Ev(ptr noundef nonnull align 8 dereferenceable(40)) unnamed_addr #1

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIN5vmath4vec3ESaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 4 dereferenceable(12)) local_unnamed_addr #4 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(16) ptr @_ZNSt6vectorI9GridPointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN9GridPointD2Ev(ptr noundef nonnull align 4 dereferenceable(16)) unnamed_addr #6 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN16SpatialPointGrid21queryPointsInsideAABBE4AABBRSt6vectorIN5vmath4vec3ESaIS3_EE(ptr noundef nonnull align 8 dereferenceable(152) %0, ptr noundef %1, ptr noundef nonnull align 8 dereferenceable(24) %2) local_unnamed_addr #4 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca %struct.GridIndex, align 4
  %5 = alloca %struct.GridIndex, align 4
  %6 = alloca %class.AABB, align 8
  %7 = alloca %"class.vmath::vec3", align 4
  %8 = alloca %struct.GridPoint, align 4
  %9 = alloca %"struct.SpatialPointGrid::CellNode", align 8
  %10 = alloca %"class.vmath::vec3", align 4
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %4) #8
  call void @_ZN9GridIndexC2Ev(ptr noundef nonnull align 4 dereferenceable(12) %4)
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %5) #8
  call void @_ZN9GridIndexC2Ev(ptr noundef nonnull align 4 dereferenceable(12) %5)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(40) %6, ptr noundef nonnull align 8 dereferenceable(40) %1, i64 40, i1 false), !tbaa.struct !5
  %11 = getelementptr inbounds i8, ptr %0, i64 16
  %12 = load double, ptr %11, align 8, !tbaa !12
  %13 = load i32, ptr %0, align 8, !tbaa !29
  %14 = getelementptr inbounds i8, ptr %0, i64 4
  %15 = load i32, ptr %14, align 4, !tbaa !30
  %16 = getelementptr inbounds i8, ptr %0, i64 8
  %17 = load i32, ptr %16, align 8, !tbaa !31
  invoke void @_ZN6Grid3d18getGridIndexBoundsE4AABBdiiiP9GridIndexS2_(ptr noundef nonnull %6, double noundef %12, i32 noundef %13, i32 noundef %15, i32 noundef %17, ptr noundef nonnull %4, ptr noundef nonnull %5)
          to label %18 unwind label %32

18:                                               ; preds = %3
  call void @_ZN4AABBD1Ev(ptr noundef nonnull align 8 dereferenceable(40) %6) #8
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %7) #8
  call void @_ZN5vmath4vec3C1Ev(ptr noundef nonnull align 4 dereferenceable(12) %7)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %8) #8
  invoke void @_ZN9GridPointC2Ev(ptr noundef nonnull align 4 dereferenceable(16) %8)
          to label %19 unwind label %34

19:                                               ; preds = %18
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #8
  call void @_ZN16SpatialPointGrid8CellNodeC2Ev(ptr noundef nonnull align 4 dereferenceable(8) %9)
  %20 = getelementptr inbounds i8, ptr %4, i64 8
  %21 = load i32, ptr %20, align 4, !tbaa !32
  %22 = getelementptr inbounds i8, ptr %5, i64 8
  %23 = load i32, ptr %22, align 4, !tbaa !32
  %.not42 = icmp sgt i32 %21, %23
  br i1 %.not42, label %._crit_edge47, label %.lr.ph46

.lr.ph46:                                         ; preds = %19
  %24 = getelementptr inbounds i8, ptr %4, i64 4
  %25 = getelementptr inbounds i8, ptr %5, i64 4
  %26 = getelementptr inbounds i8, ptr %0, i64 72
  %27 = getelementptr inbounds i8, ptr %9, i64 4
  %28 = getelementptr inbounds i8, ptr %0, i64 24
  %29 = load i32, ptr %24, align 4, !tbaa !34
  %30 = load i32, ptr %25, align 4, !tbaa !34
  %31 = icmp sgt i32 %29, %30
  br i1 %31, label %._crit_edge47, label %.lr.ph46.split

._crit_edge47:                                    ; preds = %._crit_edge41, %.lr.ph46, %19
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #8
  call void @_ZN9GridPointD2Ev(ptr noundef nonnull align 4 dereferenceable(16) %8) #8
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %8) #8
  call void @_ZN5vmath4vec3D1Ev(ptr noundef nonnull align 4 dereferenceable(12) %7) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %7) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %5) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %4) #8
  ret void

32:                                               ; preds = %3
  %33 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN4AABBD1Ev(ptr noundef nonnull align 8 dereferenceable(40) %6) #8
  br label %85

34:                                               ; preds = %18
  %35 = landingpad { ptr, i32 }
          cleanup
  br label %84

.lr.ph46.split:                                   ; preds = %.lr.ph46, %._crit_edge41
  %36 = phi i32 [ %43, %._crit_edge41 ], [ %23, %.lr.ph46 ]
  %37 = phi i32 [ %44, %._crit_edge41 ], [ %30, %.lr.ph46 ]
  %38 = phi i32 [ %45, %._crit_edge41 ], [ %30, %.lr.ph46 ]
  %.02443 = phi i32 [ %46, %._crit_edge41 ], [ %21, %.lr.ph46 ]
  %39 = load i32, ptr %24, align 4, !tbaa !34
  %.not2737 = icmp sgt i32 %39, %38
  br i1 %.not2737, label %._crit_edge41, label %.lr.ph40

.lr.ph40:                                         ; preds = %.lr.ph46.split
  %40 = load i32, ptr %4, align 4, !tbaa !35
  %41 = load i32, ptr %5, align 4, !tbaa !35
  %42 = icmp sgt i32 %40, %41
  br i1 %42, label %._crit_edge41, label %.lr.ph40.split

._crit_edge41.loopexit48:                         ; preds = %._crit_edge
  %.pre51 = load i32, ptr %22, align 4, !tbaa !32
  br label %._crit_edge41

._crit_edge41:                                    ; preds = %.lr.ph40, %._crit_edge41.loopexit48, %.lr.ph46.split
  %43 = phi i32 [ %.pre51, %._crit_edge41.loopexit48 ], [ %36, %.lr.ph46.split ], [ %36, %.lr.ph40 ]
  %44 = phi i32 [ %50, %._crit_edge41.loopexit48 ], [ %37, %.lr.ph46.split ], [ %37, %.lr.ph40 ]
  %45 = phi i32 [ %50, %._crit_edge41.loopexit48 ], [ %38, %.lr.ph46.split ], [ %38, %.lr.ph40 ]
  %46 = add nsw i32 %.02443, 1
  %.not.not = icmp slt i32 %.02443, %43
  br i1 %.not.not, label %.lr.ph46.split, label %._crit_edge47, !llvm.loop !36

.lr.ph40.split:                                   ; preds = %.lr.ph40, %._crit_edge
  %47 = phi i32 [ %50, %._crit_edge ], [ %37, %.lr.ph40 ]
  %48 = phi i32 [ %51, %._crit_edge ], [ %41, %.lr.ph40 ]
  %.02638 = phi i32 [ %52, %._crit_edge ], [ %39, %.lr.ph40 ]
  %49 = load i32, ptr %4, align 4, !tbaa !35
  %.not2834 = icmp sgt i32 %49, %48
  br i1 %.not2834, label %._crit_edge, label %.lr.ph36

._crit_edge.loopexit:                             ; preds = %.loopexit
  %.pre = load i32, ptr %25, align 4, !tbaa !34
  br label %._crit_edge

._crit_edge:                                      ; preds = %._crit_edge.loopexit, %.lr.ph40.split
  %50 = phi i32 [ %.pre, %._crit_edge.loopexit ], [ %47, %.lr.ph40.split ]
  %51 = phi i32 [ %82, %._crit_edge.loopexit ], [ %48, %.lr.ph40.split ]
  %52 = add nsw i32 %.02638, 1
  %.not27.not = icmp slt i32 %.02638, %50
  br i1 %.not27.not, label %.lr.ph40.split, label %._crit_edge41.loopexit48, !llvm.loop !39

.lr.ph36:                                         ; preds = %.lr.ph40.split, %.loopexit
  %.02535 = phi i32 [ %81, %.loopexit ], [ %49, %.lr.ph40.split ]
  %53 = invoke i64 @_ZN7Array3dIN16SpatialPointGrid8CellNodeEEclEiii(ptr noundef nonnull align 8 dereferenceable(40) %26, i32 noundef %.02535, i32 noundef %.02638, i32 noundef %.02443)
          to label %54 unwind label %63

54:                                               ; preds = %.lr.ph36
  %.sroa.4.0.extract.shift = lshr i64 %53, 32
  %.sroa.4.0.extract.trunc = trunc nuw i64 %.sroa.4.0.extract.shift to i32
  %55 = icmp sgt i32 %.sroa.4.0.extract.trunc, 0
  br i1 %55, label %56, label %.loopexit

56:                                               ; preds = %54
  %57 = invoke i64 @_ZN7Array3dIN16SpatialPointGrid8CellNodeEEclEiii(ptr noundef nonnull align 8 dereferenceable(40) %26, i32 noundef %.02535, i32 noundef %.02638, i32 noundef %.02443)
          to label %58 unwind label %65

58:                                               ; preds = %56
  store i64 %57, ptr %9, align 8
  %59 = lshr i64 %57, 32
  %60 = trunc nuw i64 %59 to i32
  %61 = icmp sgt i32 %60, 0
  br i1 %61, label %.lr.ph.preheader, label %.loopexit

.lr.ph.preheader:                                 ; preds = %58
  %sext = shl i64 %57, 32
  %62 = ashr exact i64 %sext, 32
  br label %.lr.ph

63:                                               ; preds = %.lr.ph36
  %64 = landingpad { ptr, i32 }
          cleanup
  br label %83

65:                                               ; preds = %56
  %66 = landingpad { ptr, i32 }
          cleanup
  br label %83

.lr.ph:                                           ; preds = %.lr.ph.preheader, %75
  %indvars.iv = phi i64 [ %62, %.lr.ph.preheader ], [ %indvars.iv.next, %75 ]
  %67 = call noundef nonnull align 4 dereferenceable(16) ptr @_ZNSt6vectorI9GridPointSaIS0_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %28, i64 noundef %indvars.iv) #8
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(16) %8, ptr noundef nonnull align 4 dereferenceable(16) %67, i64 16, i1 false), !tbaa.struct !40
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(12) %10, ptr noundef nonnull align 4 dereferenceable(12) %67, i64 12, i1 false)
  %68 = invoke noundef zeroext i1 @_ZN4AABB13isPointInsideEN5vmath4vec3E(ptr noundef nonnull align 8 dereferenceable(40) %1, ptr noundef nonnull %10)
          to label %69 unwind label %71

69:                                               ; preds = %.lr.ph
  call void @_ZN5vmath4vec3D1Ev(ptr noundef nonnull align 4 dereferenceable(12) %10) #8
  br i1 %68, label %70, label %75

70:                                               ; preds = %69
  invoke void @_ZNSt6vectorIN5vmath4vec3ESaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %2, ptr noundef nonnull align 4 dereferenceable(12) %8)
          to label %75 unwind label %73

71:                                               ; preds = %.lr.ph
  %72 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN5vmath4vec3D1Ev(ptr noundef nonnull align 4 dereferenceable(12) %10) #8
  br label %83

73:                                               ; preds = %70
  %74 = landingpad { ptr, i32 }
          cleanup
  br label %83

75:                                               ; preds = %69, %70
  %indvars.iv.next = add nsw i64 %indvars.iv, 1
  %76 = load i32, ptr %9, align 8, !tbaa !42
  %77 = load i32, ptr %27, align 4, !tbaa !43
  %78 = add nsw i32 %77, %76
  %79 = sext i32 %78 to i64
  %80 = icmp slt i64 %indvars.iv.next, %79
  br i1 %80, label %.lr.ph, label %.loopexit, !llvm.loop !44

.loopexit:                                        ; preds = %75, %58, %54
  %81 = add nsw i32 %.02535, 1
  %82 = load i32, ptr %5, align 4, !tbaa !35
  %.not28.not = icmp slt i32 %.02535, %82
  br i1 %.not28.not, label %.lr.ph36, label %._crit_edge.loopexit, !llvm.loop !45

83:                                               ; preds = %71, %73, %65, %63
  %.pn.pn = phi { ptr, i32 } [ %66, %65 ], [ %64, %63 ], [ %74, %73 ], [ %72, %71 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #8
  call void @_ZN9GridPointD2Ev(ptr noundef nonnull align 4 dereferenceable(16) %8) #8
  br label %84

84:                                               ; preds = %83, %34
  %.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn, %83 ], [ %35, %34 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %8) #8
  call void @_ZN5vmath4vec3D1Ev(ptr noundef nonnull align 4 dereferenceable(12) %7) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %7) #8
  br label %85

85:                                               ; preds = %84, %32
  %.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn, %84 ], [ %33, %32 ]
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %5) #8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %4) #8
  resume { ptr, i32 } %.pn.pn.pn.pn
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN9GridIndexC2Ev(ptr noundef nonnull align 4 dereferenceable(12)) unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZN6Grid3d18getGridIndexBoundsE4AABBdiiiP9GridIndexS2_(ptr noundef, double noundef, i32 noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #7

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

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_ZN7Array3dIN16SpatialPointGrid8CellNodeEEclEiii(ptr noundef nonnull align 8 dereferenceable(40), i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #4 align 2

declare noundef zeroext i1 @_ZN4AABB13isPointInsideEN5vmath4vec3E(ptr noundef nonnull align 8 dereferenceable(40), ptr noundef) local_unnamed_addr #0

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 "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 = { 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 #3 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { 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 #5 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #6 = { inlinehint 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 #7 = { 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 #8 = { 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 = !{i64 0, i64 4, !6, i64 4, i64 4, !6, i64 8, i64 4, !6, i64 16, i64 8, !10, i64 24, i64 8, !10, i64 32, i64 8, !10}
!6 = !{!7, !7, i64 0}
!7 = !{!"float", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!11, !11, i64 0}
!11 = !{!"double", !8, i64 0}
!12 = !{!13, !11, i64 16}
!13 = !{!"_ZTS16SpatialPointGrid", !14, i64 0, !14, i64 4, !14, i64 8, !11, i64 16, !15, i64 24, !20, i64 48, !24, i64 72, !27, i64 112}
!14 = !{!"int", !8, i64 0}
!15 = !{!"_ZTSSt6vectorI9GridPointSaIS0_EE", !16, i64 0}
!16 = !{!"_ZTSSt12_Vector_baseI9GridPointSaIS0_EE", !17, i64 0}
!17 = !{!"_ZTSNSt12_Vector_baseI9GridPointSaIS0_EE12_Vector_implE", !18, i64 0}
!18 = !{!"_ZTSNSt12_Vector_baseI9GridPointSaIS0_EE17_Vector_impl_dataE", !19, i64 0, !19, i64 8, !19, i64 16}
!19 = !{!"any pointer", !8, i64 0}
!20 = !{!"_ZTSSt6vectorIiSaIiEE", !21, i64 0}
!21 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !22, i64 0}
!22 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !23, i64 0}
!23 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !19, i64 0, !19, i64 8, !19, i64 16}
!24 = !{!"_ZTS7Array3dIN16SpatialPointGrid8CellNodeEE", !14, i64 0, !14, i64 4, !14, i64 8, !19, i64 16, !25, i64 24, !26, i64 28, !14, i64 36}
!25 = !{!"bool", !8, i64 0}
!26 = !{!"_ZTSN16SpatialPointGrid8CellNodeE", !14, i64 0, !14, i64 4}
!27 = !{!"_ZTS4AABB", !28, i64 0, !11, i64 16, !11, i64 24, !11, i64 32}
!28 = !{!"_ZTSN5vmath4vec3E", !7, i64 0, !7, i64 4, !7, i64 8}
!29 = !{!13, !14, i64 0}
!30 = !{!13, !14, i64 4}
!31 = !{!13, !14, i64 8}
!32 = !{!33, !14, i64 8}
!33 = !{!"_ZTS9GridIndex", !14, i64 0, !14, i64 4, !14, i64 8}
!34 = !{!33, !14, i64 4}
!35 = !{!33, !14, i64 0}
!36 = distinct !{!36, !37, !38}
!37 = !{!"llvm.loop.mustprogress"}
!38 = !{!"llvm.loop.unswitch.partial.disable"}
!39 = distinct !{!39, !37, !38}
!40 = !{i64 0, i64 4, !6, i64 4, i64 4, !6, i64 8, i64 4, !6, i64 12, i64 4, !41}
!41 = !{!14, !14, i64 0}
!42 = !{!26, !14, i64 0}
!43 = !{!26, !14, i64 4}
!44 = distinct !{!44, !37}
!45 = distinct !{!45, !37}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopInstSimplifyPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,MemCpyOptPass,ReassociatePass,SCCPPass,SROAPass,SimpleLoopUnswitchPass,SimplifyCFGPass