; LLVM IR from robotics-upo/Heuristic_path_planners :: include/voro++-0.4.6/src (container_prd)

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

%"class.voro::voro_base" = type { i32, i32, i32, i32, i32, double, double, double, double, double, double, ptr }
%"class.voro::unitcell" = type { double, double, double, double, double, double, %"class.voro::voronoicell", double, double }
%"class.voro::voronoicell" = type { %"class.voro::voronoicell_base" }
%"class.voro::voronoicell_base" = type { ptr, i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, i32, ptr, double, double, double, double }
%"class.voro::container_periodic_base" = type { %"class.voro::unitcell", %"class.voro::voro_base", i32, i32, i32, i32, i32, i32, i32, ptr, ptr, ptr, ptr, ptr, i32, i32 }

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #0

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN4voro23container_periodic_base16put_locate_blockERiRdS2_S2_(ptr noundef nonnull align 8 dereferenceable(384) %0, ptr noundef nonnull align 4 dereferenceable(4) %1, ptr noundef nonnull align 8 dereferenceable(8) %2, ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef nonnull align 8 dereferenceable(8) %4) #2 align 2 {
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  store ptr %0, ptr %6, align 8, !tbaa !5
  store ptr %1, ptr %7, align 8, !tbaa !5
  store ptr %2, ptr %8, align 8, !tbaa !5
  store ptr %3, ptr %9, align 8, !tbaa !5
  store ptr %4, ptr %10, align 8, !tbaa !5
  %16 = load ptr, ptr %6, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #4
  %17 = getelementptr inbounds i8, ptr %16, i64 224
  %18 = load ptr, ptr %10, align 8, !tbaa !5
  %19 = load double, ptr %18, align 8, !tbaa !9
  %20 = getelementptr inbounds i8, ptr %16, i64 224
  %21 = getelementptr inbounds %"class.voro::voro_base", ptr %20, i32 0, i32 10
  %22 = load double, ptr %21, align 8, !tbaa !11
  %23 = fmul double %19, %22
  %24 = call noundef i32 @_ZN4voro9voro_base8step_intEd(ptr noundef nonnull align 8 dereferenceable(80) %17, double noundef %23)
  store i32 %24, ptr %11, align 4, !tbaa !14
  %25 = load i32, ptr %11, align 4, !tbaa !14
  %26 = icmp slt i32 %25, 0
  br i1 %26, label %33, label %27

27:                                               ; preds = %5
  %28 = load i32, ptr %11, align 4, !tbaa !14
  %29 = getelementptr inbounds i8, ptr %16, i64 224
  %30 = getelementptr inbounds %"class.voro::voro_base", ptr %29, i32 0, i32 2
  %31 = load i32, ptr %30, align 8, !tbaa !15
  %32 = icmp sge i32 %28, %31
  br i1 %32, label %33, label %71

33:                                               ; preds = %27, %5
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #4
  %34 = getelementptr inbounds i8, ptr %16, i64 224
  %35 = load i32, ptr %11, align 4, !tbaa !14
  %36 = getelementptr inbounds i8, ptr %16, i64 224
  %37 = getelementptr inbounds %"class.voro::voro_base", ptr %36, i32 0, i32 2
  %38 = load i32, ptr %37, align 8, !tbaa !15
  %39 = call noundef i32 @_ZN4voro9voro_base8step_divEii(ptr noundef nonnull align 8 dereferenceable(80) %34, i32 noundef %35, i32 noundef %38)
  store i32 %39, ptr %12, align 4, !tbaa !14
  %40 = load i32, ptr %12, align 4, !tbaa !14
  %41 = sitofp i32 %40 to double
  %42 = getelementptr inbounds %"class.voro::unitcell", ptr %16, i32 0, i32 5
  %43 = load double, ptr %42, align 8, !tbaa !16
  %44 = load ptr, ptr %10, align 8, !tbaa !5
  %45 = load double, ptr %44, align 8, !tbaa !9
  %46 = fneg double %41
  %47 = call double @llvm.fmuladd.f64(double %46, double %43, double %45)
  store double %47, ptr %44, align 8, !tbaa !9
  %48 = load i32, ptr %12, align 4, !tbaa !14
  %49 = sitofp i32 %48 to double
  %50 = getelementptr inbounds %"class.voro::unitcell", ptr %16, i32 0, i32 4
  %51 = load double, ptr %50, align 8, !tbaa !20
  %52 = load ptr, ptr %9, align 8, !tbaa !5
  %53 = load double, ptr %52, align 8, !tbaa !9
  %54 = fneg double %49
  %55 = call double @llvm.fmuladd.f64(double %54, double %51, double %53)
  store double %55, ptr %52, align 8, !tbaa !9
  %56 = load i32, ptr %12, align 4, !tbaa !14
  %57 = sitofp i32 %56 to double
  %58 = getelementptr inbounds %"class.voro::unitcell", ptr %16, i32 0, i32 3
  %59 = load double, ptr %58, align 8, !tbaa !21
  %60 = load ptr, ptr %8, align 8, !tbaa !5
  %61 = load double, ptr %60, align 8, !tbaa !9
  %62 = fneg double %57
  %63 = call double @llvm.fmuladd.f64(double %62, double %59, double %61)
  store double %63, ptr %60, align 8, !tbaa !9
  %64 = load i32, ptr %12, align 4, !tbaa !14
  %65 = getelementptr inbounds i8, ptr %16, i64 224
  %66 = getelementptr inbounds %"class.voro::voro_base", ptr %65, i32 0, i32 2
  %67 = load i32, ptr %66, align 8, !tbaa !15
  %68 = mul nsw i32 %64, %67
  %69 = load i32, ptr %11, align 4, !tbaa !14
  %70 = sub nsw i32 %69, %68
  store i32 %70, ptr %11, align 4, !tbaa !14
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #4
  br label %71

71:                                               ; preds = %33, %27
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #4
  %72 = getelementptr inbounds i8, ptr %16, i64 224
  %73 = load ptr, ptr %9, align 8, !tbaa !5
  %74 = load double, ptr %73, align 8, !tbaa !9
  %75 = getelementptr inbounds i8, ptr %16, i64 224
  %76 = getelementptr inbounds %"class.voro::voro_base", ptr %75, i32 0, i32 9
  %77 = load double, ptr %76, align 8, !tbaa !22
  %78 = fmul double %74, %77
  %79 = call noundef i32 @_ZN4voro9voro_base8step_intEd(ptr noundef nonnull align 8 dereferenceable(80) %72, double noundef %78)
  store i32 %79, ptr %13, align 4, !tbaa !14
  %80 = load i32, ptr %13, align 4, !tbaa !14
  %81 = icmp slt i32 %80, 0
  br i1 %81, label %88, label %82

82:                                               ; preds = %71
  %83 = load i32, ptr %13, align 4, !tbaa !14
  %84 = getelementptr inbounds i8, ptr %16, i64 224
  %85 = getelementptr inbounds %"class.voro::voro_base", ptr %84, i32 0, i32 1
  %86 = load i32, ptr %85, align 4, !tbaa !23
  %87 = icmp sge i32 %83, %86
  br i1 %87, label %88, label %118

88:                                               ; preds = %82, %71
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #4
  %89 = getelementptr inbounds i8, ptr %16, i64 224
  %90 = load i32, ptr %13, align 4, !tbaa !14
  %91 = getelementptr inbounds i8, ptr %16, i64 224
  %92 = getelementptr inbounds %"class.voro::voro_base", ptr %91, i32 0, i32 1
  %93 = load i32, ptr %92, align 4, !tbaa !23
  %94 = call noundef i32 @_ZN4voro9voro_base8step_divEii(ptr noundef nonnull align 8 dereferenceable(80) %89, i32 noundef %90, i32 noundef %93)
  store i32 %94, ptr %14, align 4, !tbaa !14
  %95 = load i32, ptr %14, align 4, !tbaa !14
  %96 = sitofp i32 %95 to double
  %97 = getelementptr inbounds %"class.voro::unitcell", ptr %16, i32 0, i32 2
  %98 = load double, ptr %97, align 8, !tbaa !24
  %99 = load ptr, ptr %9, align 8, !tbaa !5
  %100 = load double, ptr %99, align 8, !tbaa !9
  %101 = fneg double %96
  %102 = call double @llvm.fmuladd.f64(double %101, double %98, double %100)
  store double %102, ptr %99, align 8, !tbaa !9
  %103 = load i32, ptr %14, align 4, !tbaa !14
  %104 = sitofp i32 %103 to double
  %105 = getelementptr inbounds %"class.voro::unitcell", ptr %16, i32 0, i32 1
  %106 = load double, ptr %105, align 8, !tbaa !25
  %107 = load ptr, ptr %8, align 8, !tbaa !5
  %108 = load double, ptr %107, align 8, !tbaa !9
  %109 = fneg double %104
  %110 = call double @llvm.fmuladd.f64(double %109, double %106, double %108)
  store double %110, ptr %107, align 8, !tbaa !9
  %111 = load i32, ptr %14, align 4, !tbaa !14
  %112 = getelementptr inbounds i8, ptr %16, i64 224
  %113 = getelementptr inbounds %"class.voro::voro_base", ptr %112, i32 0, i32 1
  %114 = load i32, ptr %113, align 4, !tbaa !23
  %115 = mul nsw i32 %111, %114
  %116 = load i32, ptr %13, align 4, !tbaa !14
  %117 = sub nsw i32 %116, %115
  store i32 %117, ptr %13, align 4, !tbaa !14
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #4
  br label %118

118:                                              ; preds = %88, %82
  %119 = getelementptr inbounds i8, ptr %16, i64 224
  %120 = load ptr, ptr %8, align 8, !tbaa !5
  %121 = load double, ptr %120, align 8, !tbaa !9
  %122 = getelementptr inbounds i8, ptr %16, i64 224
  %123 = getelementptr inbounds %"class.voro::voro_base", ptr %122, i32 0, i32 8
  %124 = load double, ptr %123, align 8, !tbaa !26
  %125 = fmul double %121, %124
  %126 = call noundef i32 @_ZN4voro9voro_base8step_intEd(ptr noundef nonnull align 8 dereferenceable(80) %119, double noundef %125)
  %127 = load ptr, ptr %7, align 8, !tbaa !5
  store i32 %126, ptr %127, align 4, !tbaa !14
  %128 = load ptr, ptr %7, align 8, !tbaa !5
  %129 = load i32, ptr %128, align 4, !tbaa !14
  %130 = icmp slt i32 %129, 0
  br i1 %130, label %138, label %131

131:                                              ; preds = %118
  %132 = load ptr, ptr %7, align 8, !tbaa !5
  %133 = load i32, ptr %132, align 4, !tbaa !14
  %134 = getelementptr inbounds i8, ptr %16, i64 224
  %135 = getelementptr inbounds %"class.voro::voro_base", ptr %134, i32 0, i32 0
  %136 = load i32, ptr %135, align 8, !tbaa !27
  %137 = icmp sge i32 %133, %136
  br i1 %137, label %138, label %162

138:                                              ; preds = %131, %118
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #4
  %139 = getelementptr inbounds i8, ptr %16, i64 224
  %140 = load ptr, ptr %7, align 8, !tbaa !5
  %141 = load i32, ptr %140, align 4, !tbaa !14
  %142 = getelementptr inbounds i8, ptr %16, i64 224
  %143 = getelementptr inbounds %"class.voro::voro_base", ptr %142, i32 0, i32 0
  %144 = load i32, ptr %143, align 8, !tbaa !27
  %145 = call noundef i32 @_ZN4voro9voro_base8step_divEii(ptr noundef nonnull align 8 dereferenceable(80) %139, i32 noundef %141, i32 noundef %144)
  store i32 %145, ptr %15, align 4, !tbaa !14
  %146 = load i32, ptr %15, align 4, !tbaa !14
  %147 = sitofp i32 %146 to double
  %148 = getelementptr inbounds %"class.voro::unitcell", ptr %16, i32 0, i32 0
  %149 = load double, ptr %148, align 8, !tbaa !28
  %150 = load ptr, ptr %8, align 8, !tbaa !5
  %151 = load double, ptr %150, align 8, !tbaa !9
  %152 = fneg double %147
  %153 = call double @llvm.fmuladd.f64(double %152, double %149, double %151)
  store double %153, ptr %150, align 8, !tbaa !9
  %154 = load i32, ptr %15, align 4, !tbaa !14
  %155 = getelementptr inbounds i8, ptr %16, i64 224
  %156 = getelementptr inbounds %"class.voro::voro_base", ptr %155, i32 0, i32 0
  %157 = load i32, ptr %156, align 8, !tbaa !27
  %158 = mul nsw i32 %154, %157
  %159 = load ptr, ptr %7, align 8, !tbaa !5
  %160 = load i32, ptr %159, align 4, !tbaa !14
  %161 = sub nsw i32 %160, %158
  store i32 %161, ptr %159, align 4, !tbaa !14
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #4
  br label %162

162:                                              ; preds = %138, %131
  %163 = getelementptr inbounds %"class.voro::container_periodic_base", ptr %16, i32 0, i32 2
  %164 = load i32, ptr %163, align 8, !tbaa !29
  %165 = load i32, ptr %13, align 4, !tbaa !14
  %166 = add nsw i32 %165, %164
  store i32 %166, ptr %13, align 4, !tbaa !14
  %167 = getelementptr inbounds %"class.voro::container_periodic_base", ptr %16, i32 0, i32 3
  %168 = load i32, ptr %167, align 4, !tbaa !31
  %169 = load i32, ptr %11, align 4, !tbaa !14
  %170 = add nsw i32 %169, %168
  store i32 %170, ptr %11, align 4, !tbaa !14
  %171 = getelementptr inbounds i8, ptr %16, i64 224
  %172 = getelementptr inbounds %"class.voro::voro_base", ptr %171, i32 0, i32 0
  %173 = load i32, ptr %172, align 8, !tbaa !27
  %174 = load i32, ptr %13, align 4, !tbaa !14
  %175 = getelementptr inbounds %"class.voro::container_periodic_base", ptr %16, i32 0, i32 6
  %176 = load i32, ptr %175, align 8, !tbaa !32
  %177 = load i32, ptr %11, align 4, !tbaa !14
  %178 = mul nsw i32 %176, %177
  %179 = add nsw i32 %174, %178
  %180 = mul nsw i32 %173, %179
  %181 = load ptr, ptr %7, align 8, !tbaa !5
  %182 = load i32, ptr %181, align 4, !tbaa !14
  %183 = add nsw i32 %182, %180
  store i32 %183, ptr %181, align 4, !tbaa !14
  %184 = getelementptr inbounds %"class.voro::container_periodic_base", ptr %16, i32 0, i32 11
  %185 = load ptr, ptr %184, align 8, !tbaa !33
  %186 = load ptr, ptr %7, align 8, !tbaa !5
  %187 = load i32, ptr %186, align 4, !tbaa !14
  %188 = sext i32 %187 to i64
  %189 = getelementptr inbounds i32, ptr %185, i64 %188
  %190 = load i32, ptr %189, align 4, !tbaa !14
  %191 = getelementptr inbounds %"class.voro::container_periodic_base", ptr %16, i32 0, i32 12
  %192 = load ptr, ptr %191, align 8, !tbaa !34
  %193 = load ptr, ptr %7, align 8, !tbaa !5
  %194 = load i32, ptr %193, align 4, !tbaa !14
  %195 = sext i32 %194 to i64
  %196 = getelementptr inbounds i32, ptr %192, i64 %195
  %197 = load i32, ptr %196, align 4, !tbaa !14
  %198 = icmp eq i32 %190, %197
  br i1 %198, label %199, label %202

199:                                              ; preds = %162
  %200 = load ptr, ptr %7, align 8, !tbaa !5
  %201 = load i32, ptr %200, align 4, !tbaa !14
  call void @_ZN4voro23container_periodic_base19add_particle_memoryEi(ptr noundef nonnull align 8 dereferenceable(384) %16, i32 noundef %201)
  br label %202

202:                                              ; preds = %199, %162
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #4
  ret void
}

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN4voro9voro_base8step_intEd(ptr noundef nonnull align 8 dereferenceable(80), double noundef) #3 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN4voro9voro_base8step_divEii(ptr noundef nonnull align 8 dereferenceable(80), i32 noundef, i32 noundef) #3 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4voro23container_periodic_base19add_particle_memoryEi(ptr noundef nonnull align 8 dereferenceable(384), i32 noundef) #2 align 2

attributes #0 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 = { 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 #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 = !{!"double", !7, i64 0}
!11 = !{!12, !10, i64 64}
!12 = !{!"_ZTSN4voro9voro_baseE", !13, i64 0, !13, i64 4, !13, i64 8, !13, i64 12, !13, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !6, i64 72}
!13 = !{!"int", !7, i64 0}
!14 = !{!13, !13, i64 0}
!15 = !{!12, !13, i64 8}
!16 = !{!17, !10, i64 40}
!17 = !{!"_ZTSN4voro8unitcellE", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !18, i64 48, !10, i64 208, !10, i64 216}
!18 = !{!"_ZTSN4voro11voronoicellE", !19, i64 0}
!19 = !{!"_ZTSN4voro16voronoicell_baseE", !13, i64 8, !13, i64 12, !13, i64 16, !13, i64 20, !13, i64 24, !13, i64 28, !6, 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, !6, i64 104, !13, i64 112, !13, i64 116, !6, i64 120, !10, i64 128, !10, i64 136, !10, i64 144, !10, i64 152}
!20 = !{!17, !10, i64 32}
!21 = !{!17, !10, i64 24}
!22 = !{!12, !10, i64 56}
!23 = !{!12, !13, i64 4}
!24 = !{!17, !10, i64 16}
!25 = !{!17, !10, i64 8}
!26 = !{!12, !10, i64 48}
!27 = !{!12, !13, i64 0}
!28 = !{!17, !10, i64 0}
!29 = !{!30, !13, i64 304}
!30 = !{!"_ZTSN4voro23container_periodic_baseE", !17, i64 0, !12, i64 224, !13, i64 304, !13, i64 308, !13, i64 312, !13, i64 316, !13, i64 320, !13, i64 324, !13, i64 328, !6, i64 336, !6, i64 344, !6, i64 352, !6, i64 360, !6, i64 368, !13, i64 376, !13, i64 380}
!31 = !{!30, !13, i64 308}
!32 = !{!30, !13, i64 320}
!33 = !{!30, !6, i64 352}
!34 = !{!30, !6, i64 360}


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

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #0

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN4voro23container_periodic_base16put_locate_blockERiRdS2_S2_(ptr noundef nonnull align 8 dereferenceable(384) %0, ptr nocapture noundef nonnull align 4 dereferenceable(4) %1, ptr nocapture noundef nonnull align 8 dereferenceable(8) %2, ptr nocapture noundef nonnull align 8 dereferenceable(8) %3, ptr nocapture noundef nonnull align 8 dereferenceable(8) %4) local_unnamed_addr #1 align 2 {
  %6 = getelementptr inbounds i8, ptr %0, i64 224
  %7 = load double, ptr %4, align 8, !tbaa !5
  %8 = getelementptr inbounds i8, ptr %0, i64 288
  %9 = load double, ptr %8, align 8, !tbaa !9
  %10 = fmul double %7, %9
  %11 = tail call noundef i32 @_ZN4voro9voro_base8step_intEd(ptr noundef nonnull align 8 dereferenceable(80) %6, double noundef %10)
  %12 = icmp sgt i32 %11, -1
  %13 = getelementptr inbounds i8, ptr %0, i64 232
  %14 = load i32, ptr %13, align 8
  %.not = icmp slt i32 %11, %14
  %or.cond = select i1 %12, i1 %.not, i1 false
  br i1 %or.cond, label %34, label %15

15:                                               ; preds = %5
  %16 = tail call noundef i32 @_ZN4voro9voro_base8step_divEii(ptr noundef nonnull align 8 dereferenceable(80) %6, i32 noundef %11, i32 noundef %14)
  %17 = sitofp i32 %16 to double
  %18 = getelementptr inbounds i8, ptr %0, i64 40
  %19 = load double, ptr %18, align 8, !tbaa !13
  %20 = load double, ptr %4, align 8, !tbaa !5
  %21 = fneg double %17
  %22 = tail call double @llvm.fmuladd.f64(double %21, double %19, double %20)
  store double %22, ptr %4, align 8, !tbaa !5
  %23 = getelementptr inbounds i8, ptr %0, i64 32
  %24 = load double, ptr %23, align 8, !tbaa !17
  %25 = load double, ptr %3, align 8, !tbaa !5
  %26 = tail call double @llvm.fmuladd.f64(double %21, double %24, double %25)
  store double %26, ptr %3, align 8, !tbaa !5
  %27 = getelementptr inbounds i8, ptr %0, i64 24
  %28 = load double, ptr %27, align 8, !tbaa !18
  %29 = load double, ptr %2, align 8, !tbaa !5
  %30 = tail call double @llvm.fmuladd.f64(double %21, double %28, double %29)
  store double %30, ptr %2, align 8, !tbaa !5
  %31 = load i32, ptr %13, align 8, !tbaa !19
  %32 = mul nsw i32 %31, %16
  %33 = sub nsw i32 %11, %32
  br label %34

34:                                               ; preds = %5, %15
  %.0 = phi i32 [ %33, %15 ], [ %11, %5 ]
  %35 = load double, ptr %3, align 8, !tbaa !5
  %36 = getelementptr inbounds i8, ptr %0, i64 280
  %37 = load double, ptr %36, align 8, !tbaa !20
  %38 = fmul double %35, %37
  %39 = tail call noundef i32 @_ZN4voro9voro_base8step_intEd(ptr noundef nonnull align 8 dereferenceable(80) %6, double noundef %38)
  %40 = icmp sgt i32 %39, -1
  %41 = getelementptr inbounds i8, ptr %0, i64 228
  %42 = load i32, ptr %41, align 4
  %.not43 = icmp slt i32 %39, %42
  %or.cond47 = select i1 %40, i1 %.not43, i1 false
  br i1 %or.cond47, label %._crit_edge, label %43

._crit_edge:                                      ; preds = %34
  %.pre = load double, ptr %2, align 8, !tbaa !5
  br label %58

43:                                               ; preds = %34
  %44 = tail call noundef i32 @_ZN4voro9voro_base8step_divEii(ptr noundef nonnull align 8 dereferenceable(80) %6, i32 noundef %39, i32 noundef %42)
  %45 = sitofp i32 %44 to double
  %46 = getelementptr inbounds i8, ptr %0, i64 16
  %47 = load double, ptr %46, align 8, !tbaa !21
  %48 = load double, ptr %3, align 8, !tbaa !5
  %49 = fneg double %45
  %50 = tail call double @llvm.fmuladd.f64(double %49, double %47, double %48)
  store double %50, ptr %3, align 8, !tbaa !5
  %51 = getelementptr inbounds i8, ptr %0, i64 8
  %52 = load double, ptr %51, align 8, !tbaa !22
  %53 = load double, ptr %2, align 8, !tbaa !5
  %54 = tail call double @llvm.fmuladd.f64(double %49, double %52, double %53)
  store double %54, ptr %2, align 8, !tbaa !5
  %55 = load i32, ptr %41, align 4, !tbaa !23
  %56 = mul nsw i32 %55, %44
  %57 = sub nsw i32 %39, %56
  br label %58

58:                                               ; preds = %._crit_edge, %43
  %59 = phi double [ %54, %43 ], [ %.pre, %._crit_edge ]
  %.039 = phi i32 [ %57, %43 ], [ %39, %._crit_edge ]
  %60 = getelementptr inbounds i8, ptr %0, i64 272
  %61 = load double, ptr %60, align 8, !tbaa !24
  %62 = fmul double %59, %61
  %63 = tail call noundef i32 @_ZN4voro9voro_base8step_intEd(ptr noundef nonnull align 8 dereferenceable(80) %6, double noundef %62)
  store i32 %63, ptr %1, align 4, !tbaa !25
  %64 = icmp sgt i32 %63, -1
  %65 = load i32, ptr %6, align 8
  %.not44 = icmp slt i32 %63, %65
  %or.cond48 = select i1 %64, i1 %.not44, i1 false
  br i1 %or.cond48, label %77, label %66

66:                                               ; preds = %58
  %67 = tail call noundef i32 @_ZN4voro9voro_base8step_divEii(ptr noundef nonnull align 8 dereferenceable(80) %6, i32 noundef %63, i32 noundef %65)
  %68 = sitofp i32 %67 to double
  %69 = load double, ptr %0, align 8, !tbaa !26
  %70 = load double, ptr %2, align 8, !tbaa !5
  %71 = fneg double %68
  %72 = tail call double @llvm.fmuladd.f64(double %71, double %69, double %70)
  store double %72, ptr %2, align 8, !tbaa !5
  %73 = load i32, ptr %6, align 8, !tbaa !27
  %74 = mul nsw i32 %73, %67
  %75 = load i32, ptr %1, align 4, !tbaa !25
  %76 = sub nsw i32 %75, %74
  store i32 %76, ptr %1, align 4, !tbaa !25
  %.pre49 = load i32, ptr %6, align 8, !tbaa !27
  br label %77

77:                                               ; preds = %58, %66
  %78 = phi i32 [ %63, %58 ], [ %76, %66 ]
  %79 = phi i32 [ %65, %58 ], [ %.pre49, %66 ]
  %80 = getelementptr inbounds i8, ptr %0, i64 304
  %81 = load i32, ptr %80, align 8, !tbaa !28
  %82 = add nsw i32 %81, %.039
  %83 = getelementptr inbounds i8, ptr %0, i64 308
  %84 = load i32, ptr %83, align 4, !tbaa !30
  %85 = add nsw i32 %84, %.0
  %86 = getelementptr inbounds i8, ptr %0, i64 320
  %87 = load i32, ptr %86, align 8, !tbaa !31
  %88 = mul nsw i32 %87, %85
  %89 = add nsw i32 %82, %88
  %90 = mul nsw i32 %89, %79
  %91 = add nsw i32 %90, %78
  store i32 %91, ptr %1, align 4, !tbaa !25
  %92 = getelementptr inbounds i8, ptr %0, i64 352
  %93 = load ptr, ptr %92, align 8, !tbaa !32
  %94 = sext i32 %91 to i64
  %95 = getelementptr inbounds i32, ptr %93, i64 %94
  %96 = load i32, ptr %95, align 4, !tbaa !25
  %97 = getelementptr inbounds i8, ptr %0, i64 360
  %98 = load ptr, ptr %97, align 8, !tbaa !33
  %99 = getelementptr inbounds i32, ptr %98, i64 %94
  %100 = load i32, ptr %99, align 4, !tbaa !25
  %101 = icmp eq i32 %96, %100
  br i1 %101, label %102, label %103

102:                                              ; preds = %77
  tail call void @_ZN4voro23container_periodic_base19add_particle_memoryEi(ptr noundef nonnull align 8 dereferenceable(384) %0, i32 noundef %91)
  br label %103

103:                                              ; preds = %102, %77
  ret void
}

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN4voro9voro_base8step_intEd(ptr noundef nonnull align 8 dereferenceable(80), double noundef) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN4voro9voro_base8step_divEii(ptr noundef nonnull align 8 dereferenceable(80), i32 noundef, i32 noundef) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN4voro23container_periodic_base19add_particle_memoryEi(ptr noundef nonnull align 8 dereferenceable(384), i32 noundef) local_unnamed_addr #1 align 2

attributes #0 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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 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" }

!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 = !{!"double", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !6, i64 64}
!10 = !{!"_ZTSN4voro9voro_baseE", !11, i64 0, !11, i64 4, !11, i64 8, !11, i64 12, !11, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !12, i64 72}
!11 = !{!"int", !7, i64 0}
!12 = !{!"any pointer", !7, i64 0}
!13 = !{!14, !6, i64 40}
!14 = !{!"_ZTSN4voro8unitcellE", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !15, i64 48, !6, i64 208, !6, i64 216}
!15 = !{!"_ZTSN4voro11voronoicellE", !16, i64 0}
!16 = !{!"_ZTSN4voro16voronoicell_baseE", !11, i64 8, !11, i64 12, !11, i64 16, !11, i64 20, !11, i64 24, !11, i64 28, !12, i64 32, !12, i64 40, !12, i64 48, !12, i64 56, !12, i64 64, !12, i64 72, !12, i64 80, !12, i64 88, !12, i64 96, !12, i64 104, !11, i64 112, !11, i64 116, !12, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152}
!17 = !{!14, !6, i64 32}
!18 = !{!14, !6, i64 24}
!19 = !{!10, !11, i64 8}
!20 = !{!10, !6, i64 56}
!21 = !{!14, !6, i64 16}
!22 = !{!14, !6, i64 8}
!23 = !{!10, !11, i64 4}
!24 = !{!10, !6, i64 48}
!25 = !{!11, !11, i64 0}
!26 = !{!14, !6, i64 0}
!27 = !{!10, !11, i64 0}
!28 = !{!29, !11, i64 304}
!29 = !{!"_ZTSN4voro23container_periodic_baseE", !14, i64 0, !10, i64 224, !11, i64 304, !11, i64 308, !11, i64 312, !11, i64 316, !11, i64 320, !11, i64 324, !11, i64 328, !12, i64 336, !12, i64 344, !12, i64 352, !12, i64 360, !12, i64 368, !11, i64 376, !11, i64 380}
!30 = !{!29, !11, i64 308}
!31 = !{!29, !11, i64 320}
!32 = !{!29, !12, i64 352}
!33 = !{!29, !12, i64 360}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass