; 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.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.12" }
%"struct.std::_Head_base.12" = type { 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.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.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 }

@stderr = external global ptr, align 8
@.str.4 = external hidden unnamed_addr constant [30 x i8], align 1

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN16depth_clustering16ProjectionParams7SetSpanERKNS_10SpanParamsERKNS1_9DirectionE(ptr noundef nonnull align 8 dereferenceable(216), ptr noundef nonnull align 4 dereferenceable(36), ptr noundef nonnull align 4 dereferenceable(4)) #0 align 2

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

declare i32 @__gxx_personality_v0(...)

; 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
declare dso_local void @_ZN16depth_clustering16ProjectionParams10FillCosSinEv(ptr noundef nonnull align 8 dereferenceable(216)) #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN16depth_clustering16ProjectionParams5validEv(ptr noundef nonnull align 8 dereferenceable(216)) #0 align 2

; Function Attrs: nounwind
declare i32 @fprintf(ptr noundef, ptr noundef, ...) #2

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

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_Zli4_degy(i64 noundef) #0

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_ZN16depth_clustering7RadiansngEv(ptr noundef nonnull align 4 dereferenceable(5)) #0 align 2

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN16depth_clustering16ProjectionParams10FullSphereERKNS_7RadiansE(ptr dead_on_unwind noalias writable sret(%"class.std::unique_ptr") align 8 %0, ptr noundef nonnull align 4 dereferenceable(5) %1) #0 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca %"class.depth_clustering::ProjectionParams", align 8
  %6 = alloca %"class.depth_clustering::SpanParams", align 4
  %7 = alloca %"class.depth_clustering::Radians", align 4
  %8 = alloca %"class.depth_clustering::Radians", align 4
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca %"class.depth_clustering::Radians", align 4
  %12 = alloca i32, align 4
  %13 = alloca %"class.depth_clustering::SpanParams", align 4
  %14 = alloca %"class.depth_clustering::Radians", align 4
  %15 = alloca %"class.depth_clustering::Radians", align 4
  %16 = alloca %"class.depth_clustering::Radians", align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  store ptr %0, ptr %3, align 8
  store ptr %1, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 216, ptr %5) #4
  call void @_ZN16depth_clustering16ProjectionParamsC2Ev(ptr noundef nonnull align 8 dereferenceable(216) %5)
  call void @llvm.lifetime.start.p0(i64 36, ptr %6) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #4
  %19 = invoke i64 @_Zli4_degy(i64 noundef 180)
          to label %20 unwind label %49

20:                                               ; preds = %2
  %21 = trunc i64 %19 to i40
  store i40 %21, ptr %8, align 4
  %22 = invoke i64 @_ZN16depth_clustering7RadiansngEv(ptr noundef nonnull align 4 dereferenceable(5) %8)
          to label %23 unwind label %49

23:                                               ; preds = %20
  %24 = trunc i64 %22 to i40
  store i40 %24, ptr %7, align 4
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #4
  %25 = invoke i64 @_Zli4_degy(i64 noundef 180)
          to label %26 unwind label %53

26:                                               ; preds = %23
  %27 = trunc i64 %25 to i40
  store i40 %27, ptr %11, align 4
  %28 = load ptr, ptr %4, align 8, !tbaa !5
  invoke void @_ZN16depth_clustering10SpanParamsC2ERKNS_7RadiansES3_S3_(ptr noundef nonnull align 4 dereferenceable(36) %6, ptr noundef nonnull align 4 dereferenceable(5) %7, ptr noundef nonnull align 4 dereferenceable(5) %11, ptr noundef nonnull align 4 dereferenceable(5) %28)
          to label %29 unwind label %53

29:                                               ; preds = %26
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #4
  store i32 0, ptr %12, align 4, !tbaa !9
  invoke void @_ZN16depth_clustering16ProjectionParams7SetSpanERKNS_10SpanParamsERKNS1_9DirectionE(ptr noundef nonnull align 8 dereferenceable(216) %5, ptr noundef nonnull align 4 dereferenceable(36) %6, ptr noundef nonnull align 4 dereferenceable(4) %12)
          to label %30 unwind label %57

30:                                               ; preds = %29
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #4
  call void @llvm.lifetime.end.p0(i64 36, ptr %6) #4
  call void @llvm.lifetime.start.p0(i64 36, ptr %13) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #4
  %31 = invoke i64 @_Zli4_degy(i64 noundef 90)
          to label %32 unwind label %63

32:                                               ; preds = %30
  %33 = trunc i64 %31 to i40
  store i40 %33, ptr %15, align 4
  %34 = invoke i64 @_ZN16depth_clustering7RadiansngEv(ptr noundef nonnull align 4 dereferenceable(5) %15)
          to label %35 unwind label %63

35:                                               ; preds = %32
  %36 = trunc i64 %34 to i40
  store i40 %36, ptr %14, align 4
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #4
  %37 = invoke i64 @_Zli4_degy(i64 noundef 90)
          to label %38 unwind label %67

38:                                               ; preds = %35
  %39 = trunc i64 %37 to i40
  store i40 %39, ptr %16, align 4
  %40 = load ptr, ptr %4, align 8, !tbaa !5
  invoke void @_ZN16depth_clustering10SpanParamsC2ERKNS_7RadiansES3_S3_(ptr noundef nonnull align 4 dereferenceable(36) %13, ptr noundef nonnull align 4 dereferenceable(5) %14, ptr noundef nonnull align 4 dereferenceable(5) %16, ptr noundef nonnull align 4 dereferenceable(5) %40)
          to label %41 unwind label %67

41:                                               ; preds = %38
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #4
  store i32 1, ptr %17, align 4, !tbaa !9
  invoke void @_ZN16depth_clustering16ProjectionParams7SetSpanERKNS_10SpanParamsERKNS1_9DirectionE(ptr noundef nonnull align 8 dereferenceable(216) %5, ptr noundef nonnull align 4 dereferenceable(36) %13, ptr noundef nonnull align 4 dereferenceable(4) %17)
          to label %42 unwind label %71

42:                                               ; preds = %41
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 36, ptr %13) #4
  invoke void @_ZN16depth_clustering16ProjectionParams10FillCosSinEv(ptr noundef nonnull align 8 dereferenceable(216) %5)
          to label %43 unwind label %77

43:                                               ; preds = %42
  %44 = invoke noundef zeroext i1 @_ZN16depth_clustering16ProjectionParams5validEv(ptr noundef nonnull align 8 dereferenceable(216) %5)
          to label %45 unwind label %77

45:                                               ; preds = %43
  br i1 %44, label %81, label %46

46:                                               ; preds = %45
  %47 = load ptr, ptr @stderr, align 8, !tbaa !5
  %48 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %47, ptr noundef @.str.4) #4
  call void @_ZNSt10unique_ptrIN16depth_clustering16ProjectionParamsESt14default_deleteIS1_EEC2IS3_vEEDn(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr null) #4
  store i32 1, ptr %18, align 4
  br label %83

49:                                               ; preds = %20, %2
  %50 = landingpad { ptr, i32 }
          cleanup
  %51 = extractvalue { ptr, i32 } %50, 0
  store ptr %51, ptr %9, align 8
  %52 = extractvalue { ptr, i32 } %50, 1
  store i32 %52, ptr %10, align 4
  br label %62

53:                                               ; preds = %26, %23
  %54 = landingpad { ptr, i32 }
          cleanup
  %55 = extractvalue { ptr, i32 } %54, 0
  store ptr %55, ptr %9, align 8
  %56 = extractvalue { ptr, i32 } %54, 1
  store i32 %56, ptr %10, align 4
  br label %61

57:                                               ; preds = %29
  %58 = landingpad { ptr, i32 }
          cleanup
  %59 = extractvalue { ptr, i32 } %58, 0
  store ptr %59, ptr %9, align 8
  %60 = extractvalue { ptr, i32 } %58, 1
  store i32 %60, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #4
  br label %61

61:                                               ; preds = %57, %53
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #4
  br label %62

62:                                               ; preds = %61, %49
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #4
  call void @llvm.lifetime.end.p0(i64 36, ptr %6) #4
  br label %84

63:                                               ; preds = %32, %30
  %64 = landingpad { ptr, i32 }
          cleanup
  %65 = extractvalue { ptr, i32 } %64, 0
  store ptr %65, ptr %9, align 8
  %66 = extractvalue { ptr, i32 } %64, 1
  store i32 %66, ptr %10, align 4
  br label %76

67:                                               ; preds = %38, %35
  %68 = landingpad { ptr, i32 }
          cleanup
  %69 = extractvalue { ptr, i32 } %68, 0
  store ptr %69, ptr %9, align 8
  %70 = extractvalue { ptr, i32 } %68, 1
  store i32 %70, ptr %10, align 4
  br label %75

71:                                               ; preds = %41
  %72 = landingpad { ptr, i32 }
          cleanup
  %73 = extractvalue { ptr, i32 } %72, 0
  store ptr %73, ptr %9, align 8
  %74 = extractvalue { ptr, i32 } %72, 1
  store i32 %74, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #4
  br label %75

75:                                               ; preds = %71, %67
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #4
  br label %76

76:                                               ; preds = %75, %63
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 36, ptr %13) #4
  br label %84

77:                                               ; preds = %81, %43, %42
  %78 = landingpad { ptr, i32 }
          cleanup
  %79 = extractvalue { ptr, i32 } %78, 0
  store ptr %79, ptr %9, align 8
  %80 = extractvalue { ptr, i32 } %78, 1
  store i32 %80, ptr %10, align 4
  br label %84

81:                                               ; preds = %45
  invoke void @_ZN16depth_clustering9mem_utils11make_uniqueINS_16ProjectionParamsEJRS2_EEESt10unique_ptrIT_St14default_deleteIS5_EEDpOT0_(ptr dead_on_unwind writable sret(%"class.std::unique_ptr") align 8 %0, ptr noundef nonnull align 8 dereferenceable(216) %5)
          to label %82 unwind label %77

82:                                               ; preds = %81
  store i32 1, ptr %18, align 4
  br label %83

83:                                               ; preds = %82, %46
  call void @_ZN16depth_clustering16ProjectionParamsD2Ev(ptr noundef nonnull align 8 dereferenceable(216) %5) #4
  call void @llvm.lifetime.end.p0(i64 216, ptr %5) #4
  ret void

84:                                               ; preds = %77, %76, %62
  call void @_ZN16depth_clustering16ProjectionParamsD2Ev(ptr noundef nonnull align 8 dereferenceable(216) %5) #4
  call void @llvm.lifetime.end.p0(i64 216, ptr %5) #4
  br label %85

85:                                               ; preds = %84
  %86 = load ptr, ptr %9, align 8
  %87 = load i32, ptr %10, align 4
  %88 = insertvalue { ptr, i32 } poison, ptr %86, 0
  %89 = insertvalue { ptr, i32 } %88, i32 %87, 1
  resume { ptr, i32 } %89
}

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

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #3 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"_ZTSN16depth_clustering10SpanParams9DirectionE", !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.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.12" }
%"struct.std::_Head_base.12" = type { 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.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.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 }

@stderr = external local_unnamed_addr global ptr, align 8
@.str.4 = external hidden unnamed_addr constant [30 x i8], align 1

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN16depth_clustering16ProjectionParams7SetSpanERKNS_10SpanParamsERKNS1_9DirectionE(ptr noundef nonnull align 8 dereferenceable(216), ptr noundef nonnull align 4 dereferenceable(36), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #0 align 2

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

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN16depth_clustering16ProjectionParams5validEv(ptr noundef nonnull align 8 dereferenceable(216)) local_unnamed_addr #0 align 2

; Function Attrs: nofree nounwind
declare noundef i32 @fprintf(ptr nocapture noundef, ptr nocapture noundef readonly, ...) local_unnamed_addr #2

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

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_Zli4_degy(i64 noundef) local_unnamed_addr #0

; Function Attrs: mustprogress uwtable
declare dso_local i64 @_ZN16depth_clustering7RadiansngEv(ptr noundef nonnull align 4 dereferenceable(5)) local_unnamed_addr #0 align 2

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN16depth_clustering16ProjectionParams10FullSphereERKNS_7RadiansE(ptr dead_on_unwind noalias writable sret(%"class.std::unique_ptr") align 8 %0, ptr noundef nonnull align 4 dereferenceable(5) %1) local_unnamed_addr #0 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca %"class.depth_clustering::ProjectionParams", align 8
  %4 = alloca %"class.depth_clustering::SpanParams", align 4
  %5 = alloca %"class.depth_clustering::Radians", align 8
  %6 = alloca %"class.depth_clustering::Radians", align 8
  %7 = alloca %"class.depth_clustering::Radians", align 8
  %8 = alloca i32, align 4
  %9 = alloca %"class.depth_clustering::SpanParams", align 4
  %10 = alloca %"class.depth_clustering::Radians", align 8
  %11 = alloca %"class.depth_clustering::Radians", align 8
  %12 = alloca %"class.depth_clustering::Radians", align 8
  %13 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 216, ptr nonnull %3) #4
  call void @_ZN16depth_clustering16ProjectionParamsC2Ev(ptr noundef nonnull align 8 dereferenceable(216) %3)
  call void @llvm.lifetime.start.p0(i64 36, ptr nonnull %4) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #4
  %14 = invoke i64 @_Zli4_degy(i64 noundef 180)
          to label %15 unwind label %42

15:                                               ; preds = %2
  %16 = trunc i64 %14 to i40
  store i40 %16, ptr %6, align 8
  %17 = invoke i64 @_ZN16depth_clustering7RadiansngEv(ptr noundef nonnull align 4 dereferenceable(5) %6)
          to label %18 unwind label %42

18:                                               ; preds = %15
  %19 = trunc i64 %17 to i40
  store i40 %19, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #4
  %20 = invoke i64 @_Zli4_degy(i64 noundef 180)
          to label %21 unwind label %44

21:                                               ; preds = %18
  %22 = trunc i64 %20 to i40
  store i40 %22, ptr %7, align 8
  invoke void @_ZN16depth_clustering10SpanParamsC2ERKNS_7RadiansES3_S3_(ptr noundef nonnull align 4 dereferenceable(36) %4, ptr noundef nonnull align 4 dereferenceable(5) %5, ptr noundef nonnull align 4 dereferenceable(5) %7, ptr noundef nonnull align 4 dereferenceable(5) %1)
          to label %23 unwind label %44

23:                                               ; preds = %21
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %8) #4
  store i32 0, ptr %8, align 4, !tbaa !5
  invoke void @_ZN16depth_clustering16ProjectionParams7SetSpanERKNS_10SpanParamsERKNS1_9DirectionE(ptr noundef nonnull align 8 dereferenceable(216) %3, ptr noundef nonnull align 4 dereferenceable(36) %4, ptr noundef nonnull align 4 dereferenceable(4) %8)
          to label %24 unwind label %46

24:                                               ; preds = %23
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #4
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %4) #4
  call void @llvm.lifetime.start.p0(i64 36, ptr nonnull %9) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %11) #4
  %25 = invoke i64 @_Zli4_degy(i64 noundef 90)
          to label %26 unwind label %50

26:                                               ; preds = %24
  %27 = trunc i64 %25 to i40
  store i40 %27, ptr %11, align 8
  %28 = invoke i64 @_ZN16depth_clustering7RadiansngEv(ptr noundef nonnull align 4 dereferenceable(5) %11)
          to label %29 unwind label %50

29:                                               ; preds = %26
  %30 = trunc i64 %28 to i40
  store i40 %30, ptr %10, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #4
  %31 = invoke i64 @_Zli4_degy(i64 noundef 90)
          to label %32 unwind label %52

32:                                               ; preds = %29
  %33 = trunc i64 %31 to i40
  store i40 %33, ptr %12, align 8
  invoke void @_ZN16depth_clustering10SpanParamsC2ERKNS_7RadiansES3_S3_(ptr noundef nonnull align 4 dereferenceable(36) %9, ptr noundef nonnull align 4 dereferenceable(5) %10, ptr noundef nonnull align 4 dereferenceable(5) %12, ptr noundef nonnull align 4 dereferenceable(5) %1)
          to label %34 unwind label %52

34:                                               ; preds = %32
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %13) #4
  store i32 1, ptr %13, align 4, !tbaa !5
  invoke void @_ZN16depth_clustering16ProjectionParams7SetSpanERKNS_10SpanParamsERKNS1_9DirectionE(ptr noundef nonnull align 8 dereferenceable(216) %3, ptr noundef nonnull align 4 dereferenceable(36) %9, ptr noundef nonnull align 4 dereferenceable(4) %13)
          to label %35 unwind label %54

35:                                               ; preds = %34
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %13) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #4
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %9) #4
  invoke void @_ZN16depth_clustering16ProjectionParams10FillCosSinEv(ptr noundef nonnull align 8 dereferenceable(216) %3)
          to label %36 unwind label %58

36:                                               ; preds = %35
  %37 = invoke noundef zeroext i1 @_ZN16depth_clustering16ProjectionParams5validEv(ptr noundef nonnull align 8 dereferenceable(216) %3)
          to label %38 unwind label %58

38:                                               ; preds = %36
  br i1 %37, label %60, label %39

39:                                               ; preds = %38
  %40 = load ptr, ptr @stderr, align 8, !tbaa !9
  %41 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %40, ptr noundef nonnull @.str.4) #5
  call void @_ZNSt10unique_ptrIN16depth_clustering16ProjectionParamsESt14default_deleteIS1_EEC2IS3_vEEDn(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr null) #4
  br label %61

42:                                               ; preds = %15, %2
  %43 = landingpad { ptr, i32 }
          cleanup
  br label %49

44:                                               ; preds = %21, %18
  %45 = landingpad { ptr, i32 }
          cleanup
  br label %48

46:                                               ; preds = %23
  %47 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %8) #4
  br label %48

48:                                               ; preds = %46, %44
  %.pn = phi { ptr, i32 } [ %47, %46 ], [ %45, %44 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #4
  br label %49

49:                                               ; preds = %48, %42
  %.pn.pn = phi { ptr, i32 } [ %.pn, %48 ], [ %43, %42 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #4
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %4) #4
  br label %62

50:                                               ; preds = %26, %24
  %51 = landingpad { ptr, i32 }
          cleanup
  br label %57

52:                                               ; preds = %32, %29
  %53 = landingpad { ptr, i32 }
          cleanup
  br label %56

54:                                               ; preds = %34
  %55 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %13) #4
  br label %56

56:                                               ; preds = %54, %52
  %.pn10 = phi { ptr, i32 } [ %55, %54 ], [ %53, %52 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #4
  br label %57

57:                                               ; preds = %56, %50
  %.pn10.pn = phi { ptr, i32 } [ %.pn10, %56 ], [ %51, %50 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %11) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #4
  call void @llvm.lifetime.end.p0(i64 36, ptr nonnull %9) #4
  br label %62

58:                                               ; preds = %60, %36, %35
  %59 = landingpad { ptr, i32 }
          cleanup
  br label %62

60:                                               ; preds = %38
  invoke void @_ZN16depth_clustering9mem_utils11make_uniqueINS_16ProjectionParamsEJRS2_EEESt10unique_ptrIT_St14default_deleteIS5_EEDpOT0_(ptr dead_on_unwind writable sret(%"class.std::unique_ptr") align 8 %0, ptr noundef nonnull align 8 dereferenceable(216) %3)
          to label %61 unwind label %58

61:                                               ; preds = %60, %39
  call void @_ZN16depth_clustering16ProjectionParamsD2Ev(ptr noundef nonnull align 8 dereferenceable(216) %3) #4
  call void @llvm.lifetime.end.p0(i64 216, ptr nonnull %3) #4
  ret void

62:                                               ; preds = %58, %57, %49
  %.pn13 = phi { ptr, i32 } [ %59, %58 ], [ %.pn10.pn, %57 ], [ %.pn.pn, %49 ]
  call void @_ZN16depth_clustering16ProjectionParamsD2Ev(ptr noundef nonnull align 8 dereferenceable(216) %3) #4
  call void @llvm.lifetime.end.p0(i64 216, ptr nonnull %3) #4
  resume { ptr, i32 } %.pn13
}

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

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { nofree 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 #3 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { nounwind }
attributes #5 = { cold 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 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}


; Effective O3 passes: GlobalOptPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,SROAPass,SimplifyCFGPass