; LLVM IR from PRBonn/depth_clustering :: src/projections (projection_params)

; 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.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.depth_clustering::SpanParams" = type { %"class.depth_clustering::Radians", %"class.depth_clustering::Radians", %"class.depth_clustering::Radians", %"class.depth_clustering::Radians", i32 }
%"class.depth_clustering::Radians" = type <{ float, i8, [3 x i8] }>
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<depth_clustering::Radians, std::allocator<depth_clustering::Radians>>::_Vector_impl" }
%"struct.std::_Vector_base<depth_clustering::Radians, std::allocator<depth_clustering::Radians>>::_Vector_impl" = type { %"struct.std::_Vector_base<depth_clustering::Radians, std::allocator<depth_clustering::Radians>>::_Vector_impl_data" }
%"struct.std::_Vector_base<depth_clustering::Radians, std::allocator<depth_clustering::Radians>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.depth_clustering::ProjectionParams" = type { %"class.depth_clustering::SpanParams", %"class.depth_clustering::SpanParams", %"class.std::vector.0", %"class.std::vector.0", %"class.std::vector.5", %"class.std::vector.5", %"class.std::vector.5", %"class.std::vector.5" }
%"class.std::vector.5" = type { %"struct.std::_Vector_base.6" }
%"struct.std::_Vector_base.6" = type { %"struct.std::_Vector_base<float, std::allocator<float>>::_Vector_impl" }
%"struct.std::_Vector_base<float, std::allocator<float>>::_Vector_impl" = type { %"struct.std::_Vector_base<float, std::allocator<float>>::_Vector_impl_data" }
%"struct.std::_Vector_base<float, std::allocator<float>>::_Vector_impl_data" = type { ptr, ptr, ptr }

; 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 nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #1

; 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 @_ZN16depth_clustering16ProjectionParams7SetSpanERKSt6vectorINS_10SpanParamsESaIS2_EERKNS2_9DirectionE(ptr noundef nonnull align 8 dereferenceable(216) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 4 dereferenceable(4) %2) #2 align 2 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %10 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %11 = alloca ptr, align 8
  %12 = alloca %"class.depth_clustering::SpanParams", align 4
  %13 = alloca %"class.std::vector.0", align 8
  %14 = alloca %"class.depth_clustering::SpanParams", align 4
  %15 = alloca %"class.std::vector.0", align 8
  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
  %16 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  store i32 0, ptr %7, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #5
  %17 = load ptr, ptr %5, align 8, !tbaa !5
  store ptr %17, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  %18 = load ptr, ptr %8, align 8, !tbaa !5
  %19 = call ptr @_ZNKSt6vectorIN16depth_clustering10SpanParamsESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %18) #5
  %20 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %9, i32 0, i32 0
  store ptr %19, ptr %20, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  %21 = load ptr, ptr %8, align 8, !tbaa !5
  %22 = call ptr @_ZNKSt6vectorIN16depth_clustering10SpanParamsESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %21) #5
  %23 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %10, i32 0, i32 0
  store ptr %22, ptr %23, align 8
  br label %24

24:                                               ; preds = %33, %3
  %25 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPKN16depth_clustering10SpanParamsESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESD_(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %10) #5
  br i1 %25, label %27, label %26

26:                                               ; preds = %24
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #5
  br label %35

27:                                               ; preds = %24
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  %28 = call noundef nonnull align 4 dereferenceable(36) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKN16depth_clustering10SpanParamsESt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  store ptr %28, ptr %11, align 8, !tbaa !5
  %29 = load ptr, ptr %11, align 8, !tbaa !5
  %30 = call noundef i32 @_ZNK16depth_clustering10SpanParams9num_beamsEv(ptr noundef nonnull align 4 dereferenceable(36) %29)
  %31 = load i32, ptr %7, align 4, !tbaa !9
  %32 = add nsw i32 %31, %30
  store i32 %32, ptr %7, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  br label %33

33:                                               ; preds = %27
  %34 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPKN16depth_clustering10SpanParamsESt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #5
  br label %24

35:                                               ; preds = %26
  %36 = load ptr, ptr %6, align 8, !tbaa !5
  %37 = load i32, ptr %36, align 4, !tbaa !11
  switch i32 %37, label %62 [
    i32 0, label %38
    i32 1, label %50
  ]

38:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 36, ptr %12) #5
  %39 = load ptr, ptr %5, align 8, !tbaa !5
  %40 = call noundef nonnull align 4 dereferenceable(36) ptr @_ZNKSt6vectorIN16depth_clustering10SpanParamsESaIS1_EE5frontEv(ptr noundef nonnull align 8 dereferenceable(24) %39) #5
  %41 = call noundef nonnull align 4 dereferenceable(5) ptr @_ZNK16depth_clustering10SpanParams11start_angleEv(ptr noundef nonnull align 4 dereferenceable(36) %40)
  %42 = load ptr, ptr %5, align 8, !tbaa !5
  %43 = call noundef nonnull align 4 dereferenceable(36) ptr @_ZNKSt6vectorIN16depth_clustering10SpanParamsESaIS1_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %42) #5
  %44 = call noundef nonnull align 4 dereferenceable(5) ptr @_ZNK16depth_clustering10SpanParams9end_angleEv(ptr noundef nonnull align 4 dereferenceable(36) %43)
  %45 = load i32, ptr %7, align 4, !tbaa !9
  call void @_ZN16depth_clustering10SpanParamsC2ERKNS_7RadiansES3_i(ptr noundef nonnull align 4 dereferenceable(36) %12, ptr noundef nonnull align 4 dereferenceable(5) %41, ptr noundef nonnull align 4 dereferenceable(5) %44, i32 noundef %45)
  %46 = getelementptr inbounds %"class.depth_clustering::ProjectionParams", ptr %16, i32 0, i32 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %46, ptr align 4 %12, i64 36, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 36, ptr %12) #5
  call void @llvm.lifetime.start.p0(i64 24, ptr %13) #5
  %47 = load ptr, ptr %5, align 8, !tbaa !5
  call void @_ZN16depth_clustering16ProjectionParams10FillVectorERKSt6vectorINS_10SpanParamsESaIS2_EE(ptr dead_on_unwind writable sret(%"class.std::vector.0") align 8 %13, ptr noundef nonnull align 8 dereferenceable(216) %16, ptr noundef nonnull align 8 dereferenceable(24) %47)
  %48 = getelementptr inbounds %"class.depth_clustering::ProjectionParams", ptr %16, i32 0, i32 2
  %49 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIN16depth_clustering7RadiansESaIS1_EEaSEOS3_(ptr noundef nonnull align 8 dereferenceable(24) %48, ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  call void @_ZNSt6vectorIN16depth_clustering7RadiansESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #5
  br label %62

50:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 36, ptr %14) #5
  %51 = load ptr, ptr %5, align 8, !tbaa !5
  %52 = call noundef nonnull align 4 dereferenceable(36) ptr @_ZNKSt6vectorIN16depth_clustering10SpanParamsESaIS1_EE5frontEv(ptr noundef nonnull align 8 dereferenceable(24) %51) #5
  %53 = call noundef nonnull align 4 dereferenceable(5) ptr @_ZNK16depth_clustering10SpanParams11start_angleEv(ptr noundef nonnull align 4 dereferenceable(36) %52)
  %54 = load ptr, ptr %5, align 8, !tbaa !5
  %55 = call noundef nonnull align 4 dereferenceable(36) ptr @_ZNKSt6vectorIN16depth_clustering10SpanParamsESaIS1_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %54) #5
  %56 = call noundef nonnull align 4 dereferenceable(5) ptr @_ZNK16depth_clustering10SpanParams9end_angleEv(ptr noundef nonnull align 4 dereferenceable(36) %55)
  %57 = load i32, ptr %7, align 4, !tbaa !9
  call void @_ZN16depth_clustering10SpanParamsC2ERKNS_7RadiansES3_i(ptr noundef nonnull align 4 dereferenceable(36) %14, ptr noundef nonnull align 4 dereferenceable(5) %53, ptr noundef nonnull align 4 dereferenceable(5) %56, i32 noundef %57)
  %58 = getelementptr inbounds %"class.depth_clustering::ProjectionParams", ptr %16, i32 0, i32 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %58, ptr align 4 %14, i64 36, i1 false), !tbaa.struct !13
  call void @llvm.lifetime.end.p0(i64 36, ptr %14) #5
  call void @llvm.lifetime.start.p0(i64 24, ptr %15) #5
  %59 = load ptr, ptr %5, align 8, !tbaa !5
  call void @_ZN16depth_clustering16ProjectionParams10FillVectorERKSt6vectorINS_10SpanParamsESaIS2_EE(ptr dead_on_unwind writable sret(%"class.std::vector.0") align 8 %15, ptr noundef nonnull align 8 dereferenceable(216) %16, ptr noundef nonnull align 8 dereferenceable(24) %59)
  %60 = getelementptr inbounds %"class.depth_clustering::ProjectionParams", ptr %16, i32 0, i32 3
  %61 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIN16depth_clustering7RadiansESaIS1_EEaSEOS3_(ptr noundef nonnull align 8 dereferenceable(24) %60, ptr noundef nonnull align 8 dereferenceable(24) %15) #5
  call void @_ZNSt6vectorIN16depth_clustering7RadiansESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr %15) #5
  br label %62

62:                                               ; preds = %50, %38, %35
  call void @_ZN16depth_clustering16ProjectionParams10FillCosSinEv(ptr noundef nonnull align 8 dereferenceable(216) %16)
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  ret void
}

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

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

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

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN16depth_clustering10SpanParamsC2ERKNS_7RadiansES3_i(ptr noundef nonnull align 4 dereferenceable(36), ptr noundef nonnull align 4 dereferenceable(5), ptr noundef nonnull align 4 dereferenceable(5), i32 noundef) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN16depth_clustering16ProjectionParams10FillVectorERKSt6vectorINS_10SpanParamsESaIS2_EE(ptr dead_on_unwind noalias writable sret(%"class.std::vector.0") align 8, ptr noundef nonnull align 8 dereferenceable(216), ptr noundef nonnull align 8 dereferenceable(24)) #2 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN16depth_clustering16ProjectionParams10FillCosSinEv(ptr noundef nonnull align 8 dereferenceable(216)) #2 align 2

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree 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 = { 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 = { 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 #5 = { 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, !12, i64 0}
!12 = !{!"_ZTSN16depth_clustering10SpanParams9DirectionE", !7, i64 0}
!13 = !{i64 0, i64 4, !14, i64 4, i64 1, !16, i64 8, i64 4, !14, i64 12, i64 1, !16, i64 16, i64 4, !14, i64 20, i64 1, !16, i64 24, i64 4, !14, i64 28, i64 1, !16, i64 32, i64 4, !9}
!14 = !{!15, !15, i64 0}
!15 = !{!"float", !7, i64 0}
!16 = !{!17, !17, i64 0}
!17 = !{!"bool", !7, i64 0}


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

%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.depth_clustering::SpanParams" = type { %"class.depth_clustering::Radians", %"class.depth_clustering::Radians", %"class.depth_clustering::Radians", %"class.depth_clustering::Radians", i32 }
%"class.depth_clustering::Radians" = type <{ float, i8, [3 x i8] }>
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<depth_clustering::Radians, std::allocator<depth_clustering::Radians>>::_Vector_impl" }
%"struct.std::_Vector_base<depth_clustering::Radians, std::allocator<depth_clustering::Radians>>::_Vector_impl" = type { %"struct.std::_Vector_base<depth_clustering::Radians, std::allocator<depth_clustering::Radians>>::_Vector_impl_data" }
%"struct.std::_Vector_base<depth_clustering::Radians, std::allocator<depth_clustering::Radians>>::_Vector_impl_data" = type { ptr, ptr, ptr }

; 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 nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #1

; 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 @_ZN16depth_clustering16ProjectionParams7SetSpanERKSt6vectorINS_10SpanParamsESaIS2_EERKNS2_9DirectionE(ptr noundef nonnull align 8 dereferenceable(216) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, ptr nocapture noundef nonnull readonly align 4 dereferenceable(4) %2) local_unnamed_addr #2 align 2 {
  %4 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %5 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %6 = alloca %"class.depth_clustering::SpanParams", align 4
  %7 = alloca %"class.std::vector.0", align 8
  %8 = alloca %"class.depth_clustering::SpanParams", align 4
  %9 = alloca %"class.std::vector.0", align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #5
  %10 = tail call ptr @_ZNKSt6vectorIN16depth_clustering10SpanParamsESaIS1_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #5
  store ptr %10, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #5
  %11 = tail call ptr @_ZNKSt6vectorIN16depth_clustering10SpanParamsESaIS1_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #5
  store ptr %11, ptr %5, align 8
  %12 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPKN16depth_clustering10SpanParamsESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESD_(ptr noundef nonnull align 8 dereferenceable(8) %4, ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  br i1 %12, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %.lr.ph, %3
  %.0.lcssa = phi i32 [ 0, %3 ], [ %16, %.lr.ph ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #5
  %13 = load i32, ptr %2, align 4, !tbaa !5
  switch i32 %13, label %34 [
    i32 0, label %19
    i32 1, label %27
  ]

.lr.ph:                                           ; preds = %3, %.lr.ph
  %.014 = phi i32 [ %16, %.lr.ph ], [ 0, %3 ]
  %14 = call noundef nonnull align 4 dereferenceable(36) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPKN16depth_clustering10SpanParamsESt6vectorIS2_SaIS2_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %4) #5
  %15 = call noundef i32 @_ZNK16depth_clustering10SpanParams9num_beamsEv(ptr noundef nonnull align 4 dereferenceable(36) %14)
  %16 = add nsw i32 %15, %.014
  %17 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPKN16depth_clustering10SpanParamsESt6vectorIS2_SaIS2_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %4) #5
  %18 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPKN16depth_clustering10SpanParamsESt6vectorIS2_SaIS2_EEEEbRKNS_17__normal_iteratorIT_T0_EESD_(ptr noundef nonnull align 8 dereferenceable(8) %4, ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  br i1 %18, label %.lr.ph, label %._crit_edge

19:                                               ; preds = %._crit_edge
  call void @llvm.lifetime.start.p0(i64 36, ptr nonnull %6) #5
  %20 = call noundef nonnull align 4 dereferenceable(36) ptr @_ZNKSt6vectorIN16depth_clustering10SpanParamsESaIS1_EE5frontEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #5
  %21 = call noundef nonnull align 4 dereferenceable(5) ptr @_ZNK16depth_clustering10SpanParams11start_angleEv(ptr noundef nonnull align 4 dereferenceable(36) %20)
  %22 = call noundef nonnull align 4 dereferenceable(36) ptr @_ZNKSt6vectorIN16depth_clustering10SpanParamsESaIS1_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #5
  %23 = call noundef nonnull align 4 dereferenceable(5) ptr @_ZNK16depth_clustering10SpanParams9end_angleEv(ptr noundef nonnull align 4 dereferenceable(36) %22)
  call void @_ZN16depth_clustering10SpanParamsC2ERKNS_7RadiansES3_i(ptr noundef nonnull align 4 dereferenceable(36) %6, ptr noundef nonnull align 4 dereferenceable(5) %21, ptr noundef nonnull align 4 dereferenceable(5) %23, i32 noundef %.0.lcssa)
  %24 = getelementptr inbounds i8, ptr %0, i64 36
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(36) %24, ptr noundef nonnull align 4 dereferenceable(36) %6, i64 36, i1 false), !tbaa.struct !9
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %6) #5
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #5
  call void @_ZN16depth_clustering16ProjectionParams10FillVectorERKSt6vectorINS_10SpanParamsESaIS2_EE(ptr dead_on_unwind nonnull writable sret(%"class.std::vector.0") align 8 %7, ptr noundef nonnull align 8 dereferenceable(216) %0, ptr noundef nonnull align 8 dereferenceable(24) %1)
  %25 = getelementptr inbounds i8, ptr %0, i64 72
  %26 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIN16depth_clustering7RadiansESaIS1_EEaSEOS3_(ptr noundef nonnull align 8 dereferenceable(24) %25, ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  call void @_ZNSt6vectorIN16depth_clustering7RadiansESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #5
  br label %34

27:                                               ; preds = %._crit_edge
  call void @llvm.lifetime.start.p0(i64 36, ptr nonnull %8) #5
  %28 = call noundef nonnull align 4 dereferenceable(36) ptr @_ZNKSt6vectorIN16depth_clustering10SpanParamsESaIS1_EE5frontEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #5
  %29 = call noundef nonnull align 4 dereferenceable(5) ptr @_ZNK16depth_clustering10SpanParams11start_angleEv(ptr noundef nonnull align 4 dereferenceable(36) %28)
  %30 = call noundef nonnull align 4 dereferenceable(36) ptr @_ZNKSt6vectorIN16depth_clustering10SpanParamsESaIS1_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #5
  %31 = call noundef nonnull align 4 dereferenceable(5) ptr @_ZNK16depth_clustering10SpanParams9end_angleEv(ptr noundef nonnull align 4 dereferenceable(36) %30)
  call void @_ZN16depth_clustering10SpanParamsC2ERKNS_7RadiansES3_i(ptr noundef nonnull align 4 dereferenceable(36) %8, ptr noundef nonnull align 4 dereferenceable(5) %29, ptr noundef nonnull align 4 dereferenceable(5) %31, i32 noundef %.0.lcssa)
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(36) %0, ptr noundef nonnull align 4 dereferenceable(36) %8, i64 36, i1 false), !tbaa.struct !9
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %8) #5
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %9) #5
  call void @_ZN16depth_clustering16ProjectionParams10FillVectorERKSt6vectorINS_10SpanParamsESaIS2_EE(ptr dead_on_unwind nonnull writable sret(%"class.std::vector.0") align 8 %9, ptr noundef nonnull align 8 dereferenceable(216) %0, ptr noundef nonnull align 8 dereferenceable(24) %1)
  %32 = getelementptr inbounds i8, ptr %0, i64 96
  %33 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIN16depth_clustering7RadiansESaIS1_EEaSEOS3_(ptr noundef nonnull align 8 dereferenceable(24) %32, ptr noundef nonnull align 8 dereferenceable(24) %9) #5
  call void @_ZNSt6vectorIN16depth_clustering7RadiansESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %9) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #5
  br label %34

34:                                               ; preds = %27, %19, %._crit_edge
  call void @_ZN16depth_clustering16ProjectionParams10FillCosSinEv(ptr noundef nonnull align 8 dereferenceable(216) %0)
  ret void
}

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

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

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

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN16depth_clustering10SpanParamsC2ERKNS_7RadiansES3_i(ptr noundef nonnull align 4 dereferenceable(36), ptr noundef nonnull align 4 dereferenceable(5), ptr noundef nonnull align 4 dereferenceable(5), i32 noundef) unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN16depth_clustering16ProjectionParams10FillVectorERKSt6vectorINS_10SpanParamsESaIS2_EE(ptr dead_on_unwind noalias writable sret(%"class.std::vector.0") align 8, ptr noundef nonnull align 8 dereferenceable(216), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #2 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN16depth_clustering16ProjectionParams10FillCosSinEv(ptr noundef nonnull align 8 dereferenceable(216)) local_unnamed_addr #2 align 2

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nocallback nofree 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 = { 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 = { 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 #5 = { 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 = !{!"_ZTSN16depth_clustering10SpanParams9DirectionE", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{i64 0, i64 4, !10, i64 4, i64 1, !12, i64 8, i64 4, !10, i64 12, i64 1, !12, i64 16, i64 4, !10, i64 20, i64 1, !12, i64 24, i64 4, !10, i64 28, i64 1, !12, i64 32, i64 4, !14}
!10 = !{!11, !11, i64 0}
!11 = !{!"float", !7, i64 0}
!12 = !{!13, !13, i64 0}
!13 = !{!"bool", !7, i64 0}
!14 = !{!15, !15, i64 0}
!15 = !{!"int", !7, i64 0}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass