; LLVM IR from maliput/maliput :: src/maliput/geometry_base (kd_tree_strategy)

; 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::deque.45" = type { %"class.std::_Deque_base.46" }
%"class.std::_Deque_base.46" = type { %"struct.std::_Deque_base<const maliput::api::Lane *, std::allocator<const maliput::api::Lane *>>::_Deque_impl" }
%"struct.std::_Deque_base<const maliput::api::Lane *, std::allocator<const maliput::api::Lane *>>::_Deque_impl" = type { %"struct.std::_Deque_base<const maliput::api::Lane *, std::allocator<const maliput::api::Lane *>>::_Deque_impl_data" }
%"struct.std::_Deque_base<const maliput::api::Lane *, std::allocator<const maliput::api::Lane *>>::_Deque_impl_data" = type { ptr, i64, %"struct.std::_Deque_iterator.50", %"struct.std::_Deque_iterator.50" }
%"struct.std::_Deque_iterator.50" = type { ptr, ptr, ptr, ptr }
%"class.maliput::math::Vector3" = type { %"class.maliput::math::VectorBase" }
%"class.maliput::math::VectorBase" = type { %"struct.std::array" }
%"struct.std::array" = type { [3 x double] }
%"class.std::initializer_list.33" = type { ptr, i64 }
%"class.maliput::math::AxisAlignedBox" = type { %"class.maliput::math::BoundingRegion", %"class.maliput::math::Vector3", %"class.maliput::math::Vector3", %"class.maliput::math::Vector3", double }
%"class.maliput::math::BoundingRegion" = type { ptr }
%"class.std::deque.58" = type { %"class.std::_Deque_base.59" }
%"class.std::_Deque_base.59" = type { %"struct.std::_Deque_base<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *, std::allocator<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *>>::_Deque_impl" }
%"struct.std::_Deque_base<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *, std::allocator<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *>>::_Deque_impl" = type { %"struct.std::_Deque_base<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *, std::allocator<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *>>::_Deque_impl_data" }
%"struct.std::_Deque_base<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *, std::allocator<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *>>::_Deque_impl_data" = type { ptr, i64, %"struct.std::_Deque_iterator.63", %"struct.std::_Deque_iterator.63" }
%"struct.std::_Deque_iterator.63" = type { ptr, ptr, ptr, ptr }
%"class.std::allocator.47" = type { i8 }
%"struct.std::_Deque_iterator.64" = type { ptr, ptr, ptr, ptr }
%class.anon = type { i8 }
%"class.maliput::geometry_base::KDTreeStrategy" = type { %"class.maliput::geometry_base::StrategyBase", %"class.std::unique_ptr", double }
%"class.maliput::geometry_base::StrategyBase" = type { ptr, ptr }
%"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.21" }
%"struct.std::_Head_base.21" = type { ptr }

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

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) #0

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7maliput4math7Vector3C2ESt16initializer_listIdE(ptr noundef nonnull align 8 dereferenceable(24), ptr, i64) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK7maliput13geometry_base14KDTreeStrategy12ClosestLanesERKNS_3api16InertialPositionEd(ptr dead_on_unwind noalias writable sret(%"class.std::deque.45") align 8 %0, ptr noundef nonnull align 8 dereferenceable(32) %1, ptr noundef nonnull align 8 dereferenceable(24) %2, double noundef %3) #1 align 2 personality ptr @__gxx_personality_v0 {
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca double, align 8
  %9 = alloca %"class.maliput::math::Vector3", align 8
  %10 = alloca %"class.std::initializer_list.33", align 8
  %11 = alloca [3 x double], align 8
  %12 = alloca %"class.maliput::math::Vector3", align 8
  %13 = alloca %"class.std::initializer_list.33", align 8
  %14 = alloca [3 x double], align 8
  %15 = alloca %"class.maliput::math::AxisAlignedBox", align 8
  %16 = alloca %"class.std::deque.58", align 8
  %17 = alloca ptr, align 8
  %18 = alloca i32, align 4
  %19 = alloca i1, align 1
  %20 = alloca %"class.std::allocator.47", align 1
  %21 = alloca %"struct.std::_Deque_iterator.64", align 8
  %22 = alloca %"struct.std::_Deque_iterator.64", align 8
  %23 = alloca %"struct.std::_Deque_iterator.50", align 8
  %24 = alloca %class.anon, align 1
  %25 = alloca %"struct.std::_Deque_iterator.50", align 8
  store ptr %0, ptr %5, align 8
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  store double %3, ptr %8, align 8, !tbaa !9
  %26 = load ptr, ptr %6, align 8
  call void @llvm.lifetime.start.p0(i64 24, ptr %9) #4
  call void @llvm.lifetime.start.p0(i64 24, ptr %11) #4
  %27 = load ptr, ptr %7, align 8, !tbaa !5
  %28 = call noundef double @_ZNK7maliput3api16InertialPosition1xEv(ptr noundef nonnull align 8 dereferenceable(24) %27)
  %29 = load double, ptr %8, align 8, !tbaa !9
  %30 = fsub double %28, %29
  store double %30, ptr %11, align 8, !tbaa !9
  %31 = getelementptr inbounds double, ptr %11, i64 1
  %32 = load ptr, ptr %7, align 8, !tbaa !5
  %33 = call noundef double @_ZNK7maliput3api16InertialPosition1yEv(ptr noundef nonnull align 8 dereferenceable(24) %32)
  %34 = load double, ptr %8, align 8, !tbaa !9
  %35 = fsub double %33, %34
  store double %35, ptr %31, align 8, !tbaa !9
  %36 = getelementptr inbounds double, ptr %11, i64 2
  %37 = load ptr, ptr %7, align 8, !tbaa !5
  %38 = call noundef double @_ZNK7maliput3api16InertialPosition1zEv(ptr noundef nonnull align 8 dereferenceable(24) %37)
  %39 = load double, ptr %8, align 8, !tbaa !9
  %40 = fsub double %38, %39
  store double %40, ptr %36, align 8, !tbaa !9
  %41 = getelementptr inbounds %"class.std::initializer_list.33", ptr %10, i32 0, i32 0
  store ptr %11, ptr %41, align 8, !tbaa !11
  %42 = getelementptr inbounds %"class.std::initializer_list.33", ptr %10, i32 0, i32 1
  store i64 3, ptr %42, align 8, !tbaa !14
  %43 = getelementptr inbounds { ptr, i64 }, ptr %10, i32 0, i32 0
  %44 = load ptr, ptr %43, align 8
  %45 = getelementptr inbounds { ptr, i64 }, ptr %10, i32 0, i32 1
  %46 = load i64, ptr %45, align 8
  call void @_ZN7maliput4math7Vector3C2ESt16initializer_listIdE(ptr noundef nonnull align 8 dereferenceable(24) %9, ptr %44, i64 %46)
  call void @llvm.lifetime.end.p0(i64 24, ptr %11) #4
  call void @llvm.lifetime.start.p0(i64 24, ptr %12) #4
  call void @llvm.lifetime.start.p0(i64 24, ptr %14) #4
  %47 = load ptr, ptr %7, align 8, !tbaa !5
  %48 = call noundef double @_ZNK7maliput3api16InertialPosition1xEv(ptr noundef nonnull align 8 dereferenceable(24) %47)
  %49 = load double, ptr %8, align 8, !tbaa !9
  %50 = fadd double %48, %49
  store double %50, ptr %14, align 8, !tbaa !9
  %51 = getelementptr inbounds double, ptr %14, i64 1
  %52 = load ptr, ptr %7, align 8, !tbaa !5
  %53 = call noundef double @_ZNK7maliput3api16InertialPosition1yEv(ptr noundef nonnull align 8 dereferenceable(24) %52)
  %54 = load double, ptr %8, align 8, !tbaa !9
  %55 = fadd double %53, %54
  store double %55, ptr %51, align 8, !tbaa !9
  %56 = getelementptr inbounds double, ptr %14, i64 2
  %57 = load ptr, ptr %7, align 8, !tbaa !5
  %58 = call noundef double @_ZNK7maliput3api16InertialPosition1zEv(ptr noundef nonnull align 8 dereferenceable(24) %57)
  %59 = load double, ptr %8, align 8, !tbaa !9
  %60 = fadd double %58, %59
  store double %60, ptr %56, align 8, !tbaa !9
  %61 = getelementptr inbounds %"class.std::initializer_list.33", ptr %13, i32 0, i32 0
  store ptr %14, ptr %61, align 8, !tbaa !11
  %62 = getelementptr inbounds %"class.std::initializer_list.33", ptr %13, i32 0, i32 1
  store i64 3, ptr %62, align 8, !tbaa !14
  %63 = getelementptr inbounds { ptr, i64 }, ptr %13, i32 0, i32 0
  %64 = load ptr, ptr %63, align 8
  %65 = getelementptr inbounds { ptr, i64 }, ptr %13, i32 0, i32 1
  %66 = load i64, ptr %65, align 8
  call void @_ZN7maliput4math7Vector3C2ESt16initializer_listIdE(ptr noundef nonnull align 8 dereferenceable(24) %12, ptr %64, i64 %66)
  call void @llvm.lifetime.end.p0(i64 24, ptr %14) #4
  call void @llvm.lifetime.start.p0(i64 88, ptr %15) #4
  call void @_ZN7maliput4math14AxisAlignedBoxC1ERKNS0_7Vector3ES4_(ptr noundef nonnull align 8 dereferenceable(88) %15, ptr noundef nonnull align 8 dereferenceable(24) %9, ptr noundef nonnull align 8 dereferenceable(24) %12)
  call void @llvm.lifetime.start.p0(i64 80, ptr %16) #4
  %67 = getelementptr inbounds %"class.maliput::geometry_base::KDTreeStrategy", ptr %26, i32 0, i32 1
  %68 = call noundef ptr @_ZNKSt10unique_ptrIN7maliput4math8KDTree3DINS0_13geometry_base14KDTreeStrategy12MaliputPointENS1_7details15SquaredDistanceIS5_Lm3EEENS6_7NodeCmpILm3EEEEESt14default_deleteISB_EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %67) #4
  invoke void @_ZNK7maliput4math8KDTree3DINS_13geometry_base14KDTreeStrategy12MaliputPointENS0_7details15SquaredDistanceIS4_Lm3EEENS5_7NodeCmpILm3EEEE11RangeSearchERKNS0_14AxisAlignedBoxE(ptr dead_on_unwind writable sret(%"class.std::deque.58") align 8 %16, ptr noundef nonnull align 8 dereferenceable(88) %68, ptr noundef nonnull align 8 dereferenceable(88) %15)
          to label %69 unwind label %74

69:                                               ; preds = %4
  store i1 false, ptr %19, align 1
  %70 = call noundef i64 @_ZNKSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(80) %16) #4
  call void @llvm.lifetime.start.p0(i64 1, ptr %20) #4
  call void @_ZNSaIPKN7maliput3api4LaneEEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %20) #4
  invoke void @_ZNSt5dequeIPKN7maliput3api4LaneESaIS4_EEC2EmRKS5_(ptr noundef nonnull align 8 dereferenceable(80) %0, i64 noundef %70, ptr noundef nonnull align 1 dereferenceable(1) %20)
          to label %71 unwind label %78

71:                                               ; preds = %69
  call void @_ZNSt15__new_allocatorIPKN7maliput3api4LaneEED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %20) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr %20) #4
  call void @_ZNKSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EE5beginEv(ptr dead_on_unwind writable sret(%"struct.std::_Deque_iterator.64") align 8 %21, ptr noundef nonnull align 8 dereferenceable(80) %16) #4
  call void @_ZNKSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EE3endEv(ptr dead_on_unwind writable sret(%"struct.std::_Deque_iterator.64") align 8 %22, ptr noundef nonnull align 8 dereferenceable(80) %16) #4
  call void @_ZNSt5dequeIPKN7maliput3api4LaneESaIS4_EE5beginEv(ptr dead_on_unwind writable sret(%"struct.std::_Deque_iterator.50") align 8 %23, ptr noundef nonnull align 8 dereferenceable(80) %0) #4
  call void @llvm.lifetime.start.p0(i64 32, ptr %25) #4
  invoke void @"_ZSt9transformISt15_Deque_iteratorIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointERKS6_PS7_ES0_IPKNS1_3api4LaneERSE_PSE_EZNKS3_12ClosestLanesERKNSB_16InertialPositionEdE3$_0ET0_T_SN_SM_T1_"(ptr dead_on_unwind writable sret(%"struct.std::_Deque_iterator.50") align 8 %25, ptr noundef %21, ptr noundef %22, ptr noundef %23)
          to label %72 unwind label %82

72:                                               ; preds = %71
  call void @llvm.lifetime.end.p0(i64 32, ptr %25) #4
  store i1 true, ptr %19, align 1
  %73 = load i1, ptr %19, align 1
  br i1 %73, label %87, label %86

74:                                               ; preds = %4
  %75 = landingpad { ptr, i32 }
          cleanup
  %76 = extractvalue { ptr, i32 } %75, 0
  store ptr %76, ptr %17, align 8
  %77 = extractvalue { ptr, i32 } %75, 1
  store i32 %77, ptr %18, align 4
  br label %89

78:                                               ; preds = %69
  %79 = landingpad { ptr, i32 }
          cleanup
  %80 = extractvalue { ptr, i32 } %79, 0
  store ptr %80, ptr %17, align 8
  %81 = extractvalue { ptr, i32 } %79, 1
  store i32 %81, ptr %18, align 4
  call void @_ZNSt15__new_allocatorIPKN7maliput3api4LaneEED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %20) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr %20) #4
  br label %88

82:                                               ; preds = %71
  %83 = landingpad { ptr, i32 }
          cleanup
  %84 = extractvalue { ptr, i32 } %83, 0
  store ptr %84, ptr %17, align 8
  %85 = extractvalue { ptr, i32 } %83, 1
  store i32 %85, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 32, ptr %25) #4
  call void @_ZNSt5dequeIPKN7maliput3api4LaneESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %0) #4
  br label %88

86:                                               ; preds = %72
  call void @_ZNSt5dequeIPKN7maliput3api4LaneESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %0) #4
  br label %87

87:                                               ; preds = %86, %72
  call void @_ZNSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %16) #4
  call void @llvm.lifetime.end.p0(i64 80, ptr %16) #4
  call void @_ZN7maliput4math14BoundingRegionINS0_7Vector3EED2Ev(ptr noundef nonnull align 8 dereferenceable(88) %15) #4
  call void @llvm.lifetime.end.p0(i64 88, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr %9) #4
  ret void

88:                                               ; preds = %82, %78
  call void @_ZNSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %16) #4
  br label %89

89:                                               ; preds = %88, %74
  call void @llvm.lifetime.end.p0(i64 80, ptr %16) #4
  call void @_ZN7maliput4math14BoundingRegionINS0_7Vector3EED2Ev(ptr noundef nonnull align 8 dereferenceable(88) %15) #4
  call void @llvm.lifetime.end.p0(i64 88, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr %9) #4
  br label %90

90:                                               ; preds = %89
  %91 = load ptr, ptr %17, align 8
  %92 = load i32, ptr %18, align 4
  %93 = insertvalue { ptr, i32 } poison, ptr %91, 0
  %94 = insertvalue { ptr, i32 } %93, i32 %92, 1
  resume { ptr, i32 } %94
}

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

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

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

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

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

declare void @_ZN7maliput4math14AxisAlignedBoxC1ERKNS0_7Vector3ES4_(ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK7maliput4math8KDTree3DINS_13geometry_base14KDTreeStrategy12MaliputPointENS0_7details15SquaredDistanceIS4_Lm3EEENS5_7NodeCmpILm3EEEE11RangeSearchERKNS0_14AxisAlignedBoxE(ptr dead_on_unwind noalias writable sret(%"class.std::deque.58") align 8, ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(88)) #1 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt5dequeIPKN7maliput3api4LaneESaIS4_EEC2EmRKS5_(ptr noundef nonnull align 8 dereferenceable(80), i64 noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #1 align 2

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

; Function Attrs: mustprogress uwtable
declare hidden void @"_ZSt9transformISt15_Deque_iteratorIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointERKS6_PS7_ES0_IPKNS1_3api4LaneERSE_PSE_EZNKS3_12ClosestLanesERKNSB_16InertialPositionEdE3$_0ET0_T_SN_SM_T1_"(ptr dead_on_unwind noalias writable sret(%"struct.std::_Deque_iterator.50") align 8, ptr noundef, ptr noundef, ptr noundef) #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNKSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EE5beginEv(ptr dead_on_unwind noalias writable sret(%"struct.std::_Deque_iterator.64") align 8, ptr noundef nonnull align 8 dereferenceable(80)) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNKSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EE3endEv(ptr dead_on_unwind noalias writable sret(%"struct.std::_Deque_iterator.64") align 8, ptr noundef nonnull align 8 dereferenceable(80)) #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt5dequeIPKN7maliput3api4LaneESaIS4_EE5beginEv(ptr dead_on_unwind noalias writable sret(%"struct.std::_Deque_iterator.50") align 8, ptr noundef nonnull align 8 dereferenceable(80)) #2 align 2

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

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

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


; 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::deque.45" = type { %"class.std::_Deque_base.46" }
%"class.std::_Deque_base.46" = type { %"struct.std::_Deque_base<const maliput::api::Lane *, std::allocator<const maliput::api::Lane *>>::_Deque_impl" }
%"struct.std::_Deque_base<const maliput::api::Lane *, std::allocator<const maliput::api::Lane *>>::_Deque_impl" = type { %"struct.std::_Deque_base<const maliput::api::Lane *, std::allocator<const maliput::api::Lane *>>::_Deque_impl_data" }
%"struct.std::_Deque_base<const maliput::api::Lane *, std::allocator<const maliput::api::Lane *>>::_Deque_impl_data" = type { ptr, i64, %"struct.std::_Deque_iterator.50", %"struct.std::_Deque_iterator.50" }
%"struct.std::_Deque_iterator.50" = type { ptr, ptr, ptr, ptr }
%"class.maliput::math::Vector3" = type { %"class.maliput::math::VectorBase" }
%"class.maliput::math::VectorBase" = type { %"struct.std::array" }
%"struct.std::array" = type { [3 x double] }
%"class.maliput::math::AxisAlignedBox" = type { %"class.maliput::math::BoundingRegion", %"class.maliput::math::Vector3", %"class.maliput::math::Vector3", %"class.maliput::math::Vector3", double }
%"class.maliput::math::BoundingRegion" = type { ptr }
%"class.std::deque.58" = type { %"class.std::_Deque_base.59" }
%"class.std::_Deque_base.59" = type { %"struct.std::_Deque_base<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *, std::allocator<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *>>::_Deque_impl" }
%"struct.std::_Deque_base<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *, std::allocator<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *>>::_Deque_impl" = type { %"struct.std::_Deque_base<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *, std::allocator<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *>>::_Deque_impl_data" }
%"struct.std::_Deque_base<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *, std::allocator<const maliput::geometry_base::KDTreeStrategy::MaliputPoint *>>::_Deque_impl_data" = type { ptr, i64, %"struct.std::_Deque_iterator.63", %"struct.std::_Deque_iterator.63" }
%"struct.std::_Deque_iterator.63" = type { ptr, ptr, ptr, ptr }
%"class.std::allocator.47" = type { i8 }
%"struct.std::_Deque_iterator.64" = type { ptr, 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

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) #0

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7maliput4math7Vector3C2ESt16initializer_listIdE(ptr noundef nonnull align 8 dereferenceable(24), ptr, i64) unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK7maliput13geometry_base14KDTreeStrategy12ClosestLanesERKNS_3api16InertialPositionEd(ptr dead_on_unwind noalias writable sret(%"class.std::deque.45") align 8 %0, ptr noundef nonnull align 8 dereferenceable(32) %1, ptr noundef nonnull align 8 dereferenceable(24) %2, double noundef %3) local_unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %5 = alloca %"class.maliput::math::Vector3", align 8
  %6 = alloca [3 x double], align 16
  %7 = alloca %"class.maliput::math::Vector3", align 8
  %8 = alloca [3 x double], align 8
  %9 = alloca %"class.maliput::math::AxisAlignedBox", align 8
  %10 = alloca %"class.std::deque.58", align 8
  %11 = alloca %"class.std::allocator.47", align 1
  %12 = alloca %"struct.std::_Deque_iterator.64", align 8
  %13 = alloca %"struct.std::_Deque_iterator.64", align 8
  %14 = alloca %"struct.std::_Deque_iterator.50", align 8
  %15 = alloca %"struct.std::_Deque_iterator.50", align 8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %6) #4
  %16 = tail call noundef double @_ZNK7maliput3api16InertialPosition1xEv(ptr noundef nonnull align 8 dereferenceable(24) %2)
  %17 = tail call noundef double @_ZNK7maliput3api16InertialPosition1yEv(ptr noundef nonnull align 8 dereferenceable(24) %2)
  %18 = insertelement <2 x double> poison, double %16, i64 0
  %19 = insertelement <2 x double> %18, double %17, i64 1
  %20 = insertelement <2 x double> poison, double %3, i64 0
  %21 = shufflevector <2 x double> %20, <2 x double> poison, <2 x i32> zeroinitializer
  %22 = fsub <2 x double> %19, %21
  store <2 x double> %22, ptr %6, align 16, !tbaa !5
  %23 = getelementptr inbounds i8, ptr %6, i64 16
  %24 = tail call noundef double @_ZNK7maliput3api16InertialPosition1zEv(ptr noundef nonnull align 8 dereferenceable(24) %2)
  %25 = fsub double %24, %3
  store double %25, ptr %23, align 16, !tbaa !5
  call void @_ZN7maliput4math7Vector3C2ESt16initializer_listIdE(ptr noundef nonnull align 8 dereferenceable(24) %5, ptr nonnull %6, i64 3)
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %6) #4
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #4
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #4
  %26 = call noundef double @_ZNK7maliput3api16InertialPosition1xEv(ptr noundef nonnull align 8 dereferenceable(24) %2)
  %27 = fadd double %26, %3
  store double %27, ptr %8, align 8, !tbaa !5
  %28 = getelementptr inbounds i8, ptr %8, i64 8
  %29 = call noundef double @_ZNK7maliput3api16InertialPosition1yEv(ptr noundef nonnull align 8 dereferenceable(24) %2)
  %30 = fadd double %29, %3
  store double %30, ptr %28, align 8, !tbaa !5
  %31 = getelementptr inbounds i8, ptr %8, i64 16
  %32 = call noundef double @_ZNK7maliput3api16InertialPosition1zEv(ptr noundef nonnull align 8 dereferenceable(24) %2)
  %33 = fadd double %32, %3
  store double %33, ptr %31, align 8, !tbaa !5
  call void @_ZN7maliput4math7Vector3C2ESt16initializer_listIdE(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr nonnull %8, i64 3)
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #4
  call void @llvm.lifetime.start.p0(i64 88, ptr nonnull %9) #4
  call void @_ZN7maliput4math14AxisAlignedBoxC1ERKNS0_7Vector3ES4_(ptr noundef nonnull align 8 dereferenceable(88) %9, ptr noundef nonnull align 8 dereferenceable(24) %5, ptr noundef nonnull align 8 dereferenceable(24) %7)
  call void @llvm.lifetime.start.p0(i64 80, ptr nonnull %10) #4
  %34 = getelementptr inbounds i8, ptr %1, i64 16
  %35 = call noundef ptr @_ZNKSt10unique_ptrIN7maliput4math8KDTree3DINS0_13geometry_base14KDTreeStrategy12MaliputPointENS1_7details15SquaredDistanceIS5_Lm3EEENS6_7NodeCmpILm3EEEEESt14default_deleteISB_EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %34) #4
  invoke void @_ZNK7maliput4math8KDTree3DINS_13geometry_base14KDTreeStrategy12MaliputPointENS0_7details15SquaredDistanceIS4_Lm3EEENS5_7NodeCmpILm3EEEE11RangeSearchERKNS0_14AxisAlignedBoxE(ptr dead_on_unwind nonnull writable sret(%"class.std::deque.58") align 8 %10, ptr noundef nonnull align 8 dereferenceable(88) %35, ptr noundef nonnull align 8 dereferenceable(88) %9)
          to label %36 unwind label %40

36:                                               ; preds = %4
  %37 = call noundef i64 @_ZNKSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(80) %10) #4
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %11) #4
  call void @_ZNSaIPKN7maliput3api4LaneEEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #4
  invoke void @_ZNSt5dequeIPKN7maliput3api4LaneESaIS4_EEC2EmRKS5_(ptr noundef nonnull align 8 dereferenceable(80) %0, i64 noundef %37, ptr noundef nonnull align 1 dereferenceable(1) %11)
          to label %38 unwind label %42

38:                                               ; preds = %36
  call void @_ZNSt15__new_allocatorIPKN7maliput3api4LaneEED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %11) #4
  call void @_ZNKSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EE5beginEv(ptr dead_on_unwind nonnull writable sret(%"struct.std::_Deque_iterator.64") align 8 %12, ptr noundef nonnull align 8 dereferenceable(80) %10) #4
  call void @_ZNKSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EE3endEv(ptr dead_on_unwind nonnull writable sret(%"struct.std::_Deque_iterator.64") align 8 %13, ptr noundef nonnull align 8 dereferenceable(80) %10) #4
  call void @_ZNSt5dequeIPKN7maliput3api4LaneESaIS4_EE5beginEv(ptr dead_on_unwind nonnull writable sret(%"struct.std::_Deque_iterator.50") align 8 %14, ptr noundef nonnull align 8 dereferenceable(80) %0) #4
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %15) #4
  invoke void @"_ZSt9transformISt15_Deque_iteratorIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointERKS6_PS7_ES0_IPKNS1_3api4LaneERSE_PSE_EZNKS3_12ClosestLanesERKNSB_16InertialPositionEdE3$_0ET0_T_SN_SM_T1_"(ptr dead_on_unwind nonnull writable sret(%"struct.std::_Deque_iterator.50") align 8 %15, ptr noundef nonnull %12, ptr noundef nonnull %13, ptr noundef nonnull %14)
          to label %39 unwind label %44

39:                                               ; preds = %38
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %15) #4
  call void @_ZNSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %10) #4
  call void @llvm.lifetime.end.p0(i64 80, ptr nonnull %10) #4
  call void @_ZN7maliput4math14BoundingRegionINS0_7Vector3EED2Ev(ptr noundef nonnull align 8 dereferenceable(88) %9) #4
  call void @llvm.lifetime.end.p0(i64 88, ptr nonnull %9) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #4
  ret void

40:                                               ; preds = %4
  %41 = landingpad { ptr, i32 }
          cleanup
  br label %47

42:                                               ; preds = %36
  %43 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIPKN7maliput3api4LaneEED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %11) #4
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %11) #4
  br label %46

44:                                               ; preds = %38
  %45 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %15) #4
  call void @_ZNSt5dequeIPKN7maliput3api4LaneESaIS4_EED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %0) #4
  br label %46

46:                                               ; preds = %44, %42
  %.pn = phi { ptr, i32 } [ %45, %44 ], [ %43, %42 ]
  call void @_ZNSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EED2Ev(ptr noundef nonnull align 8 dereferenceable(80) %10) #4
  br label %47

47:                                               ; preds = %46, %40
  %.pn.pn = phi { ptr, i32 } [ %.pn, %46 ], [ %41, %40 ]
  call void @llvm.lifetime.end.p0(i64 80, ptr nonnull %10) #4
  call void @_ZN7maliput4math14BoundingRegionINS0_7Vector3EED2Ev(ptr noundef nonnull align 8 dereferenceable(88) %9) #4
  call void @llvm.lifetime.end.p0(i64 88, ptr nonnull %9) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #4
  resume { ptr, i32 } %.pn.pn
}

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

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

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

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

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

declare void @_ZN7maliput4math14AxisAlignedBoxC1ERKNS0_7Vector3ES4_(ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK7maliput4math8KDTree3DINS_13geometry_base14KDTreeStrategy12MaliputPointENS0_7details15SquaredDistanceIS4_Lm3EEENS5_7NodeCmpILm3EEEE11RangeSearchERKNS0_14AxisAlignedBoxE(ptr dead_on_unwind noalias writable sret(%"class.std::deque.58") align 8, ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(88)) local_unnamed_addr #1 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt5dequeIPKN7maliput3api4LaneESaIS4_EEC2EmRKS5_(ptr noundef nonnull align 8 dereferenceable(80), i64 noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #1 align 2

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

; Function Attrs: mustprogress uwtable
declare hidden void @"_ZSt9transformISt15_Deque_iteratorIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointERKS6_PS7_ES0_IPKNS1_3api4LaneERSE_PSE_EZNKS3_12ClosestLanesERKNSB_16InertialPositionEdE3$_0ET0_T_SN_SM_T1_"(ptr dead_on_unwind noalias writable sret(%"struct.std::_Deque_iterator.50") align 8, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNKSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EE5beginEv(ptr dead_on_unwind noalias writable sret(%"struct.std::_Deque_iterator.64") align 8, ptr noundef nonnull align 8 dereferenceable(80)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNKSt5dequeIPKN7maliput13geometry_base14KDTreeStrategy12MaliputPointESaIS5_EE3endEv(ptr dead_on_unwind noalias writable sret(%"struct.std::_Deque_iterator.64") align 8, ptr noundef nonnull align 8 dereferenceable(80)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt5dequeIPKN7maliput3api4LaneESaIS4_EE5beginEv(ptr dead_on_unwind noalias writable sret(%"struct.std::_Deque_iterator.50") align 8, ptr noundef nonnull align 8 dereferenceable(80)) local_unnamed_addr #2 align 2

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

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

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


; Effective O3 passes: GlobalOptPass,IPSCCPPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,ReassociatePass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass