; LLVM IR from maliput/maliput :: src/maliput/routing (route)

; 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::optional" = type { %"struct.std::_Optional_base" }
%"struct.std::_Optional_base" = type { %"struct.std::_Optional_payload" }
%"struct.std::_Optional_payload" = type { %"struct.std::_Optional_payload_base.base", [7 x i8] }
%"struct.std::_Optional_payload_base.base" = type <{ %"union.std::_Optional_payload_base<maliput::routing::Route::LaneSRangeIndex>::_Storage", i8 }>
%"union.std::_Optional_payload_base<maliput::routing::Route::LaneSRangeIndex>::_Storage" = type { %"struct.maliput::routing::Route::LaneSRangeIndex" }
%"struct.maliput::routing::Route::LaneSRangeIndex" = type { i64, i64 }
%"class.maliput::api::LaneSRoute" = type { %"class.std::vector.10" }
%"class.std::vector.10" = type { %"struct.std::_Vector_base.11" }
%"struct.std::_Vector_base.11" = type { %"struct.std::_Vector_base<maliput::api::LaneSRange, std::allocator<maliput::api::LaneSRange>>::_Vector_impl" }
%"struct.std::_Vector_base<maliput::api::LaneSRange, std::allocator<maliput::api::LaneSRange>>::_Vector_impl" = type { %"struct.std::_Vector_base<maliput::api::LaneSRange, std::allocator<maliput::api::LaneSRange>>::_Vector_impl_data" }
%"struct.std::_Vector_base<maliput::api::LaneSRange, std::allocator<maliput::api::LaneSRange>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.maliput::api::LaneSRange" = type { %"class.maliput::api::TypeSpecificIdentifier", %"class.maliput::api::SRange" }
%"class.maliput::api::TypeSpecificIdentifier" = type { %"class.std::__cxx11::basic_string" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.maliput::api::SRange" = type { double, double }
%class.anon.111 = type { ptr }
%class.anon.112 = type { i8 }
%"class.std::allocator.15" = type { i8 }
%"struct.maliput::api::RoadPosition" = type { ptr, %"class.maliput::api::LanePosition" }
%"class.maliput::api::LanePosition" = type { %"class.maliput::math::Vector3" }
%"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::routing::Route" = type { %"class.std::vector", %"class.std::unordered_map", ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<maliput::routing::Phase, std::allocator<maliput::routing::Phase>>::_Vector_impl" }
%"struct.std::_Vector_base<maliput::routing::Phase, std::allocator<maliput::routing::Phase>>::_Vector_impl" = type { %"struct.std::_Vector_base<maliput::routing::Phase, std::allocator<maliput::routing::Phase>>::_Vector_impl_data" }
%"struct.std::_Vector_base<maliput::routing::Phase, std::allocator<maliput::routing::Phase>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::unordered_map" = type { %"class.std::_Hashtable" }
%"class.std::_Hashtable" = type { ptr, i64, %"struct.std::__detail::_Hash_node_base", i64, %"struct.std::__detail::_Prime_rehash_policy", ptr }
%"struct.std::__detail::_Hash_node_base" = type { ptr }
%"struct.std::__detail::_Prime_rehash_policy" = type { float, i64 }

@.str.1 = external hidden unnamed_addr constant [78 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [31 x i8], align 1
@__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE = external hidden unnamed_addr constant [18 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [95 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [130 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [29 x i8], align 1

; Function Attrs: noreturn
declare void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef, ptr noundef, ptr noundef, i32 noundef) #0

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIN7maliput7routing5PhaseESaIS2_EE4sizeEv(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 @_ZNK7maliput7routing5Phase13lane_s_rangesEv(ptr noundef nonnull align 8 dereferenceable(96)) #2 align 2

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

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

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

; 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) #3

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZNK7maliput7routing5Route25ComputeLaneSRangeRelationERKNS_3api10LaneSRangeES5_(ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK7maliput7routing5Route19FindLaneSRangeIndexERKNS_3api10LaneSRangeE(ptr dead_on_unwind noalias writable sret(%"class.std::optional") align 8, ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(48)) #4 align 2

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE(ptr dead_on_unwind noalias writable sret(%"class.maliput::api::LaneSRoute") align 8 %0, ptr noundef nonnull align 8 dereferenceable(88) %1, ptr noundef nonnull align 8 dereferenceable(32) %2) #4 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca %"class.maliput::api::LaneSRange", align 8
  %9 = alloca %"class.maliput::api::TypeSpecificIdentifier", align 8
  %10 = alloca %"class.maliput::api::SRange", align 8
  %11 = alloca ptr, align 8
  %12 = alloca i32, align 4
  %13 = alloca %"class.maliput::api::LaneSRange", align 8
  %14 = alloca %"class.maliput::api::TypeSpecificIdentifier", align 8
  %15 = alloca %"class.maliput::api::SRange", align 8
  %16 = alloca %"class.std::optional", align 8
  %17 = alloca %"class.std::optional", align 8
  %18 = alloca %class.anon.111, align 8
  %19 = alloca %class.anon.112, align 1
  %20 = alloca %"struct.maliput::routing::Route::LaneSRangeIndex", align 8
  %21 = alloca %"class.std::vector.10", align 8
  %22 = alloca i32, align 4
  %23 = alloca %"class.std::optional", align 8
  %24 = alloca i32, align 4
  %25 = alloca %"class.std::optional", align 8
  %26 = alloca %"class.std::__cxx11::basic_string", align 8
  %27 = alloca %"class.std::allocator.15", align 1
  %28 = alloca %"class.std::__cxx11::basic_string", align 8
  %29 = alloca %"class.std::allocator.15", align 1
  %30 = alloca i32, align 4
  %31 = alloca %"class.maliput::api::LaneSRange", align 8
  %32 = alloca %"class.maliput::api::LaneSRange", align 8
  %33 = alloca %"class.std::__cxx11::basic_string", align 8
  %34 = alloca %"class.std::allocator.15", align 1
  store ptr %0, ptr %4, align 8
  store ptr %1, ptr %5, align 8, !tbaa !5
  store ptr %2, ptr %6, align 8, !tbaa !5
  %35 = load ptr, ptr %5, align 8
  br label %36

36:                                               ; preds = %3
  %37 = load ptr, ptr %6, align 8, !tbaa !5
  %38 = getelementptr inbounds %"struct.maliput::api::RoadPosition", ptr %37, i32 0, i32 0
  %39 = load ptr, ptr %38, align 8, !tbaa !9
  %40 = icmp ne ptr %39, null
  br i1 %40, label %42, label %41

41:                                               ; preds = %36
  call void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef @.str.4, ptr noundef @__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE, ptr noundef @.str.1, i32 noundef 209) #8
  unreachable

42:                                               ; preds = %36
  br label %43

43:                                               ; preds = %42
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #9
  %44 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNK7maliput7routing5Route18end_route_positionEv(ptr noundef nonnull align 8 dereferenceable(88) %35)
  store ptr %44, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 48, ptr %8) #9
  call void @llvm.lifetime.start.p0(i64 32, ptr %9) #9
  %45 = load ptr, ptr %7, align 8, !tbaa !5
  %46 = getelementptr inbounds %"struct.maliput::api::RoadPosition", ptr %45, i32 0, i32 0
  %47 = load ptr, ptr %46, align 8, !tbaa !9
  call void @_ZNK7maliput3api4Lane2idEv(ptr dead_on_unwind writable sret(%"class.maliput::api::TypeSpecificIdentifier") align 8 %9, ptr noundef nonnull align 8 dereferenceable(8) %47)
  call void @llvm.lifetime.start.p0(i64 16, ptr %10) #9
  %48 = load ptr, ptr %7, align 8, !tbaa !5
  %49 = getelementptr inbounds %"struct.maliput::api::RoadPosition", ptr %48, i32 0, i32 1
  %50 = invoke noundef double @_ZNK7maliput3api12LanePosition1sEv(ptr noundef nonnull align 8 dereferenceable(24) %49)
          to label %51 unwind label %77

51:                                               ; preds = %43
  %52 = load ptr, ptr %7, align 8, !tbaa !5
  %53 = getelementptr inbounds %"struct.maliput::api::RoadPosition", ptr %52, i32 0, i32 1
  %54 = invoke noundef double @_ZNK7maliput3api12LanePosition1sEv(ptr noundef nonnull align 8 dereferenceable(24) %53)
          to label %55 unwind label %77

55:                                               ; preds = %51
  invoke void @_ZN7maliput3api6SRangeC1Edd(ptr noundef nonnull align 8 dereferenceable(16) %10, double noundef %50, double noundef %54)
          to label %56 unwind label %77

56:                                               ; preds = %55
  invoke void @_ZN7maliput3api10LaneSRangeC2ERKNS0_22TypeSpecificIdentifierINS0_4LaneEEERKNS0_6SRangeE(ptr noundef nonnull align 8 dereferenceable(48) %8, ptr noundef nonnull align 8 dereferenceable(32) %9, ptr noundef nonnull align 8 dereferenceable(16) %10)
          to label %57 unwind label %77

57:                                               ; preds = %56
  call void @llvm.lifetime.end.p0(i64 16, ptr %10) #9
  call void @_ZN7maliput3api22TypeSpecificIdentifierINS0_4LaneEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %9) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr %9) #9
  call void @llvm.lifetime.start.p0(i64 48, ptr %13) #9
  call void @llvm.lifetime.start.p0(i64 32, ptr %14) #9
  %58 = load ptr, ptr %6, align 8, !tbaa !5
  %59 = getelementptr inbounds %"struct.maliput::api::RoadPosition", ptr %58, i32 0, i32 0
  %60 = load ptr, ptr %59, align 8, !tbaa !9
  invoke void @_ZNK7maliput3api4Lane2idEv(ptr dead_on_unwind writable sret(%"class.maliput::api::TypeSpecificIdentifier") align 8 %14, ptr noundef nonnull align 8 dereferenceable(8) %60)
          to label %61 unwind label %81

61:                                               ; preds = %57
  call void @llvm.lifetime.start.p0(i64 16, ptr %15) #9
  %62 = load ptr, ptr %6, align 8, !tbaa !5
  %63 = getelementptr inbounds %"struct.maliput::api::RoadPosition", ptr %62, i32 0, i32 1
  %64 = invoke noundef double @_ZNK7maliput3api12LanePosition1sEv(ptr noundef nonnull align 8 dereferenceable(24) %63)
          to label %65 unwind label %85

65:                                               ; preds = %61
  %66 = load ptr, ptr %6, align 8, !tbaa !5
  %67 = getelementptr inbounds %"struct.maliput::api::RoadPosition", ptr %66, i32 0, i32 1
  %68 = invoke noundef double @_ZNK7maliput3api12LanePosition1sEv(ptr noundef nonnull align 8 dereferenceable(24) %67)
          to label %69 unwind label %85

69:                                               ; preds = %65
  invoke void @_ZN7maliput3api6SRangeC1Edd(ptr noundef nonnull align 8 dereferenceable(16) %15, double noundef %64, double noundef %68)
          to label %70 unwind label %85

70:                                               ; preds = %69
  invoke void @_ZN7maliput3api10LaneSRangeC2ERKNS0_22TypeSpecificIdentifierINS0_4LaneEEERKNS0_6SRangeE(ptr noundef nonnull align 8 dereferenceable(48) %13, ptr noundef nonnull align 8 dereferenceable(32) %14, ptr noundef nonnull align 8 dereferenceable(16) %15)
          to label %71 unwind label %85

71:                                               ; preds = %70
  call void @llvm.lifetime.end.p0(i64 16, ptr %15) #9
  call void @_ZN7maliput3api22TypeSpecificIdentifierINS0_4LaneEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %14) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr %14) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr %16) #9
  invoke void @_ZNK7maliput7routing5Route19FindLaneSRangeIndexERKNS_3api10LaneSRangeE(ptr dead_on_unwind writable sret(%"class.std::optional") align 8 %16, ptr noundef nonnull align 8 dereferenceable(88) %35, ptr noundef nonnull align 8 dereferenceable(48) %13)
          to label %72 unwind label %90

72:                                               ; preds = %71
  br label %73

73:                                               ; preds = %72
  %74 = call noundef zeroext i1 @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE9has_valueEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  br i1 %74, label %94, label %75

75:                                               ; preds = %73
  invoke void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef @.str.5, ptr noundef @__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE, ptr noundef @.str.1, i32 noundef 219) #8
          to label %76 unwind label %90

76:                                               ; preds = %75
  unreachable

77:                                               ; preds = %56, %55, %51, %43
  %78 = landingpad { ptr, i32 }
          cleanup
  %79 = extractvalue { ptr, i32 } %78, 0
  store ptr %79, ptr %11, align 8
  %80 = extractvalue { ptr, i32 } %78, 1
  store i32 %80, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %10) #9
  call void @_ZN7maliput3api22TypeSpecificIdentifierINS0_4LaneEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %9) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr %9) #9
  br label %302

81:                                               ; preds = %57
  %82 = landingpad { ptr, i32 }
          cleanup
  %83 = extractvalue { ptr, i32 } %82, 0
  store ptr %83, ptr %11, align 8
  %84 = extractvalue { ptr, i32 } %82, 1
  store i32 %84, ptr %12, align 4
  br label %89

85:                                               ; preds = %70, %69, %65, %61
  %86 = landingpad { ptr, i32 }
          cleanup
  %87 = extractvalue { ptr, i32 } %86, 0
  store ptr %87, ptr %11, align 8
  %88 = extractvalue { ptr, i32 } %86, 1
  store i32 %88, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 16, ptr %15) #9
  call void @_ZN7maliput3api22TypeSpecificIdentifierINS0_4LaneEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %14) #9
  br label %89

89:                                               ; preds = %85, %81
  call void @llvm.lifetime.end.p0(i64 32, ptr %14) #9
  br label %301

90:                                               ; preds = %75, %71
  %91 = landingpad { ptr, i32 }
          cleanup
  %92 = extractvalue { ptr, i32 } %91, 0
  store ptr %92, ptr %11, align 8
  %93 = extractvalue { ptr, i32 } %91, 1
  store i32 %93, ptr %12, align 4
  br label %300

94:                                               ; preds = %73
  br label %95

95:                                               ; preds = %94
  br label %96

96:                                               ; preds = %95
  call void @llvm.lifetime.start.p0(i64 24, ptr %17) #9
  invoke void @_ZNK7maliput7routing5Route19FindLaneSRangeIndexERKNS_3api10LaneSRangeE(ptr dead_on_unwind writable sret(%"class.std::optional") align 8 %17, ptr noundef nonnull align 8 dereferenceable(88) %35, ptr noundef nonnull align 8 dereferenceable(48) %8)
          to label %97 unwind label %102

97:                                               ; preds = %96
  br label %98

98:                                               ; preds = %97
  %99 = call noundef zeroext i1 @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE9has_valueEv(ptr noundef nonnull align 8 dereferenceable(24) %17) #9
  br i1 %99, label %106, label %100

100:                                              ; preds = %98
  invoke void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef @.str.6, ptr noundef @__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE, ptr noundef @.str.1, i32 noundef 222) #8
          to label %101 unwind label %102

101:                                              ; preds = %100
  unreachable

102:                                              ; preds = %100, %96
  %103 = landingpad { ptr, i32 }
          cleanup
  %104 = extractvalue { ptr, i32 } %103, 0
  store ptr %104, ptr %11, align 8
  %105 = extractvalue { ptr, i32 } %103, 1
  store i32 %105, ptr %12, align 4
  br label %299

106:                                              ; preds = %98
  br label %107

107:                                              ; preds = %106
  br label %108

108:                                              ; preds = %107
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #9
  %109 = getelementptr inbounds %class.anon.111, ptr %18, i32 0, i32 0
  store ptr %35, ptr %109, align 8, !tbaa !15
  call void @llvm.lifetime.start.p0(i64 1, ptr %19) #9
  call void @llvm.lifetime.start.p0(i64 16, ptr %20) #9
  %110 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNKRSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE5valueEv(ptr noundef nonnull align 8 dereferenceable(24) %17)
          to label %111 unwind label %159

111:                                              ; preds = %108
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %20, ptr align 8 %110, i64 16, i1 false), !tbaa.struct !17
  call void @llvm.lifetime.start.p0(i64 24, ptr %21) #9
  call void @_ZNSt6vectorIN7maliput3api10LaneSRangeESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #9
  %112 = getelementptr inbounds %"class.maliput::routing::Route", ptr %35, i32 0, i32 0
  %113 = call noundef i64 @_ZNKSt6vectorIN7maliput7routing5PhaseESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %112) #9
  %114 = call noundef ptr @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEEptEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  %115 = getelementptr inbounds %"struct.maliput::routing::Route::LaneSRangeIndex", ptr %114, i32 0, i32 0
  %116 = load i64, ptr %115, align 8, !tbaa !20
  %117 = sub i64 %113, %116
  %118 = trunc i64 %117 to i32
  store i32 %118, ptr %22, align 4, !tbaa !22
  br label %119

119:                                              ; preds = %199, %111
  %120 = load i32, ptr %22, align 4, !tbaa !22
  %121 = icmp sge i32 %120, 0
  br i1 %121, label %122, label %127

122:                                              ; preds = %119
  %123 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNKRSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEEdeEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  %124 = invoke noundef zeroext i1 @"_ZZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEENK3$_1clERKNS1_15LaneSRangeIndexES9_"(ptr noundef nonnull align 1 dereferenceable(1) %19, ptr noundef nonnull align 8 dereferenceable(16) %20, ptr noundef nonnull align 8 dereferenceable(16) %123)
          to label %125 unwind label %163

125:                                              ; preds = %122
  %126 = xor i1 %124, true
  br label %127

127:                                              ; preds = %125, %119
  %128 = phi i1 [ false, %119 ], [ %126, %125 ]
  br i1 %128, label %129, label %202

129:                                              ; preds = %127
  %130 = load i32, ptr %22, align 4, !tbaa !22
  %131 = add nsw i32 %130, -1
  store i32 %131, ptr %22, align 4, !tbaa !22
  invoke void @"_ZZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEENK3$_0clERKNS1_15LaneSRangeIndexEPSt6vectorINS2_10LaneSRangeESaISB_EE"(ptr noundef nonnull align 8 dereferenceable(8) %18, ptr noundef nonnull align 8 dereferenceable(16) %20, ptr noundef %21)
          to label %132 unwind label %163

132:                                              ; preds = %129
  call void @llvm.lifetime.start.p0(i64 24, ptr %23) #9
  call void @_ZNSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #9
  call void @llvm.lifetime.start.p0(i64 4, ptr %24) #9
  %133 = getelementptr inbounds %"class.maliput::routing::Route", ptr %35, i32 0, i32 0
  %134 = getelementptr inbounds %"struct.maliput::routing::Route::LaneSRangeIndex", ptr %20, i32 0, i32 0
  %135 = load i64, ptr %134, align 8, !tbaa !20
  %136 = call noundef nonnull align 8 dereferenceable(96) ptr @_ZNKSt6vectorIN7maliput7routing5PhaseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %133, i64 noundef %135) #9
  %137 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7maliput7routing5Phase13lane_s_rangesEv(ptr noundef nonnull align 8 dereferenceable(96) %136)
          to label %138 unwind label %167

138:                                              ; preds = %132
  %139 = call noundef i64 @_ZNKSt6vectorIN7maliput3api10LaneSRangeESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %137) #9
  %140 = trunc i64 %139 to i32
  store i32 %140, ptr %24, align 4, !tbaa !22
  br label %141

141:                                              ; preds = %175, %138
  %142 = call noundef zeroext i1 @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE9has_valueEv(ptr noundef nonnull align 8 dereferenceable(24) %23) #9
  br i1 %142, label %146, label %143

143:                                              ; preds = %141
  %144 = load i32, ptr %24, align 4, !tbaa !22
  %145 = icmp sge i32 %144, 0
  br label %146

146:                                              ; preds = %143, %141
  %147 = phi i1 [ false, %141 ], [ %145, %143 ]
  br i1 %147, label %148, label %178

148:                                              ; preds = %146
  call void @llvm.lifetime.start.p0(i64 24, ptr %25) #9
  invoke void @_ZNK7maliput7routing5Route23FindStraightPredecessorERKNS1_15LaneSRangeIndexE(ptr dead_on_unwind writable sret(%"class.std::optional") align 8 %25, ptr noundef nonnull align 8 dereferenceable(88) %35, ptr noundef nonnull align 8 dereferenceable(16) %20)
          to label %149 unwind label %171

149:                                              ; preds = %148
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %23, ptr align 8 %25, i64 24, i1 false)
  call void @llvm.lifetime.end.p0(i64 24, ptr %25) #9
  %150 = call noundef zeroext i1 @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE9has_valueEv(ptr noundef nonnull align 8 dereferenceable(24) %23) #9
  br i1 %150, label %175, label %151

151:                                              ; preds = %149
  %152 = invoke noundef i32 @_ZNK7maliput7routing5Route53FindDirectionTowardsLaneSRangeWithStraightPredecessorERKNS1_15LaneSRangeIndexE(ptr noundef nonnull align 8 dereferenceable(88) %35, ptr noundef nonnull align 8 dereferenceable(16) %20)
          to label %153 unwind label %167

153:                                              ; preds = %151
  %154 = sext i32 %152 to i64
  %155 = getelementptr inbounds %"struct.maliput::routing::Route::LaneSRangeIndex", ptr %20, i32 0, i32 1
  %156 = load i64, ptr %155, align 8, !tbaa !24
  %157 = add i64 %156, %154
  store i64 %157, ptr %155, align 8, !tbaa !24
  invoke void @"_ZZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEENK3$_0clERKNS1_15LaneSRangeIndexEPSt6vectorINS2_10LaneSRangeESaISB_EE"(ptr noundef nonnull align 8 dereferenceable(8) %18, ptr noundef nonnull align 8 dereferenceable(16) %20, ptr noundef %21)
          to label %158 unwind label %167

158:                                              ; preds = %153
  br label %175

159:                                              ; preds = %108
  %160 = landingpad { ptr, i32 }
          cleanup
  %161 = extractvalue { ptr, i32 } %160, 0
  store ptr %161, ptr %11, align 8
  %162 = extractvalue { ptr, i32 } %160, 1
  store i32 %162, ptr %12, align 4
  br label %298

163:                                              ; preds = %129, %122
  %164 = landingpad { ptr, i32 }
          cleanup
  %165 = extractvalue { ptr, i32 } %164, 0
  store ptr %165, ptr %11, align 8
  %166 = extractvalue { ptr, i32 } %164, 1
  store i32 %166, ptr %12, align 4
  br label %297

167:                                              ; preds = %153, %151, %132
  %168 = landingpad { ptr, i32 }
          cleanup
  %169 = extractvalue { ptr, i32 } %168, 0
  store ptr %169, ptr %11, align 8
  %170 = extractvalue { ptr, i32 } %168, 1
  store i32 %170, ptr %12, align 4
  br label %201

171:                                              ; preds = %148
  %172 = landingpad { ptr, i32 }
          cleanup
  %173 = extractvalue { ptr, i32 } %172, 0
  store ptr %173, ptr %11, align 8
  %174 = extractvalue { ptr, i32 } %172, 1
  store i32 %174, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 24, ptr %25) #9
  br label %201

175:                                              ; preds = %158, %149
  %176 = load i32, ptr %24, align 4, !tbaa !22
  %177 = add nsw i32 %176, -1
  store i32 %177, ptr %24, align 4, !tbaa !22
  br label %141, !llvm.loop !25

178:                                              ; preds = %146
  br label %179

179:                                              ; preds = %178
  %180 = load i32, ptr %24, align 4, !tbaa !22
  %181 = icmp sge i32 %180, 0
  br i1 %181, label %182, label %184

182:                                              ; preds = %179
  %183 = call noundef zeroext i1 @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE9has_valueEv(ptr noundef nonnull align 8 dereferenceable(24) %23) #9
  br i1 %183, label %197, label %184

184:                                              ; preds = %182, %179
  call void @llvm.lifetime.start.p0(i64 32, ptr %26) #9
  call void @llvm.lifetime.start.p0(i64 1, ptr %27) #9
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %27) #9
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %26, ptr noundef @.str.7, ptr noundef nonnull align 1 dereferenceable(1) %27)
          to label %185 unwind label %188

185:                                              ; preds = %184
  %186 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %26) #9
  invoke void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef %186, ptr noundef @__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE, ptr noundef @.str.1, i32 noundef 264) #8
          to label %187 unwind label %192

187:                                              ; preds = %185
  unreachable

188:                                              ; preds = %184
  %189 = landingpad { ptr, i32 }
          cleanup
  %190 = extractvalue { ptr, i32 } %189, 0
  store ptr %190, ptr %11, align 8
  %191 = extractvalue { ptr, i32 } %189, 1
  store i32 %191, ptr %12, align 4
  br label %196

192:                                              ; preds = %185
  %193 = landingpad { ptr, i32 }
          cleanup
  %194 = extractvalue { ptr, i32 } %193, 0
  store ptr %194, ptr %11, align 8
  %195 = extractvalue { ptr, i32 } %193, 1
  store i32 %195, ptr %12, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %26) #9
  br label %196

196:                                              ; preds = %192, %188
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %27) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %27) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr %26) #9
  br label %201

197:                                              ; preds = %182
  br label %198

198:                                              ; preds = %197
  br label %199

199:                                              ; preds = %198
  %200 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNRSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEEdeEv(ptr noundef nonnull align 8 dereferenceable(24) %23) #9
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %20, ptr align 8 %200, i64 16, i1 false), !tbaa.struct !17
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #9
  br label %119, !llvm.loop !27

201:                                              ; preds = %196, %171, %167
  call void @llvm.lifetime.end.p0(i64 4, ptr %24) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #9
  br label %297

202:                                              ; preds = %127
  br label %203

203:                                              ; preds = %202
  %204 = load i32, ptr %22, align 4, !tbaa !22
  %205 = icmp sge i32 %204, 0
  br i1 %205, label %219, label %206

206:                                              ; preds = %203
  call void @llvm.lifetime.start.p0(i64 32, ptr %28) #9
  call void @llvm.lifetime.start.p0(i64 1, ptr %29) #9
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %29) #9
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %28, ptr noundef @.str.8, ptr noundef nonnull align 1 dereferenceable(1) %29)
          to label %207 unwind label %210

207:                                              ; preds = %206
  %208 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %28) #9
  invoke void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef %208, ptr noundef @__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE, ptr noundef @.str.1, i32 noundef 271) #8
          to label %209 unwind label %214

209:                                              ; preds = %207
  unreachable

210:                                              ; preds = %206
  %211 = landingpad { ptr, i32 }
          cleanup
  %212 = extractvalue { ptr, i32 } %211, 0
  store ptr %212, ptr %11, align 8
  %213 = extractvalue { ptr, i32 } %211, 1
  store i32 %213, ptr %12, align 4
  br label %218

214:                                              ; preds = %207
  %215 = landingpad { ptr, i32 }
          cleanup
  %216 = extractvalue { ptr, i32 } %215, 0
  store ptr %216, ptr %11, align 8
  %217 = extractvalue { ptr, i32 } %215, 1
  store i32 %217, ptr %12, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %28) #9
  br label %218

218:                                              ; preds = %214, %210
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %29) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %29) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr %28) #9
  br label %297

219:                                              ; preds = %203
  br label %220

220:                                              ; preds = %219
  br label %221

221:                                              ; preds = %220
  call void @llvm.lifetime.start.p0(i64 4, ptr %30) #9
  store i32 12, ptr %30, align 4, !tbaa !28
  br label %222

222:                                              ; preds = %290, %221
  %223 = load i32, ptr %30, align 4, !tbaa !28
  %224 = icmp ne i32 %223, 10
  br i1 %224, label %225, label %294

225:                                              ; preds = %222
  invoke void @"_ZZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEENK3$_0clERKNS1_15LaneSRangeIndexEPSt6vectorINS2_10LaneSRangeESaISB_EE"(ptr noundef nonnull align 8 dereferenceable(8) %18, ptr noundef nonnull align 8 dereferenceable(16) %20, ptr noundef %21)
          to label %226 unwind label %250

226:                                              ; preds = %225
  call void @llvm.lifetime.start.p0(i64 48, ptr %31) #9
  %227 = call noundef ptr @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEEptEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  %228 = getelementptr inbounds %"struct.maliput::routing::Route::LaneSRangeIndex", ptr %227, i32 0, i32 0
  %229 = load i64, ptr %228, align 8, !tbaa !20
  %230 = trunc i64 %229 to i32
  %231 = call noundef ptr @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEEptEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  %232 = getelementptr inbounds %"struct.maliput::routing::Route::LaneSRangeIndex", ptr %231, i32 0, i32 1
  %233 = load i64, ptr %232, align 8, !tbaa !24
  %234 = trunc i64 %233 to i32
  %235 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZNK7maliput7routing5Route13GetLaneSRangeEii(ptr noundef nonnull align 8 dereferenceable(88) %35, i32 noundef %230, i32 noundef %234)
          to label %236 unwind label %254

236:                                              ; preds = %226
  invoke void @_ZN7maliput3api10LaneSRangeC2ERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %31, ptr noundef nonnull align 8 dereferenceable(48) %235)
          to label %237 unwind label %254

237:                                              ; preds = %236
  call void @llvm.lifetime.start.p0(i64 48, ptr %32) #9
  %238 = getelementptr inbounds %"struct.maliput::routing::Route::LaneSRangeIndex", ptr %20, i32 0, i32 0
  %239 = load i64, ptr %238, align 8, !tbaa !20
  %240 = trunc i64 %239 to i32
  %241 = getelementptr inbounds %"struct.maliput::routing::Route::LaneSRangeIndex", ptr %20, i32 0, i32 1
  %242 = load i64, ptr %241, align 8, !tbaa !24
  %243 = trunc i64 %242 to i32
  %244 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZNK7maliput7routing5Route13GetLaneSRangeEii(ptr noundef nonnull align 8 dereferenceable(88) %35, i32 noundef %240, i32 noundef %243)
          to label %245 unwind label %258

245:                                              ; preds = %237
  invoke void @_ZN7maliput3api10LaneSRangeC2ERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %32, ptr noundef nonnull align 8 dereferenceable(48) %244)
          to label %246 unwind label %258

246:                                              ; preds = %245
  %247 = invoke noundef i32 @_ZNK7maliput7routing5Route25ComputeLaneSRangeRelationERKNS_3api10LaneSRangeES5_(ptr noundef nonnull align 8 dereferenceable(88) %35, ptr noundef nonnull align 8 dereferenceable(48) %31, ptr noundef nonnull align 8 dereferenceable(48) %32)
          to label %248 unwind label %262

248:                                              ; preds = %246
  store i32 %247, ptr %30, align 4, !tbaa !28
  %249 = load i32, ptr %30, align 4, !tbaa !28
  switch i32 %249, label %274 [
    i32 2, label %266
    i32 0, label %266
    i32 3, label %270
    i32 1, label %270
    i32 10, label %290
  ]

250:                                              ; preds = %294, %225
  %251 = landingpad { ptr, i32 }
          cleanup
  %252 = extractvalue { ptr, i32 } %251, 0
  store ptr %252, ptr %11, align 8
  %253 = extractvalue { ptr, i32 } %251, 1
  store i32 %253, ptr %12, align 4
  br label %296

254:                                              ; preds = %236, %226
  %255 = landingpad { ptr, i32 }
          cleanup
  %256 = extractvalue { ptr, i32 } %255, 0
  store ptr %256, ptr %11, align 8
  %257 = extractvalue { ptr, i32 } %255, 1
  store i32 %257, ptr %12, align 4
  br label %293

258:                                              ; preds = %245, %237
  %259 = landingpad { ptr, i32 }
          cleanup
  %260 = extractvalue { ptr, i32 } %259, 0
  store ptr %260, ptr %11, align 8
  %261 = extractvalue { ptr, i32 } %259, 1
  store i32 %261, ptr %12, align 4
  br label %292

262:                                              ; preds = %246
  %263 = landingpad { ptr, i32 }
          cleanup
  %264 = extractvalue { ptr, i32 } %263, 0
  store ptr %264, ptr %11, align 8
  %265 = extractvalue { ptr, i32 } %263, 1
  store i32 %265, ptr %12, align 4
  br label %291

266:                                              ; preds = %248, %248
  %267 = getelementptr inbounds %"struct.maliput::routing::Route::LaneSRangeIndex", ptr %20, i32 0, i32 1
  %268 = load i64, ptr %267, align 8, !tbaa !24
  %269 = add i64 %268, -1
  store i64 %269, ptr %267, align 8, !tbaa !24
  br label %290

270:                                              ; preds = %248, %248
  %271 = getelementptr inbounds %"struct.maliput::routing::Route::LaneSRangeIndex", ptr %20, i32 0, i32 1
  %272 = load i64, ptr %271, align 8, !tbaa !24
  %273 = add i64 %272, 1
  store i64 %273, ptr %271, align 8, !tbaa !24
  br label %290

274:                                              ; preds = %248
  br label %275

275:                                              ; preds = %274
  call void @llvm.lifetime.start.p0(i64 32, ptr %33) #9
  call void @llvm.lifetime.start.p0(i64 1, ptr %34) #9
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %34) #9
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %33, ptr noundef @.str.9, ptr noundef nonnull align 1 dereferenceable(1) %34)
          to label %276 unwind label %279

276:                                              ; preds = %275
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %34) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %34) #9
  %277 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %33) #9
  invoke void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef %277, ptr noundef @__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE, ptr noundef @.str.1, i32 noundef 298) #8
          to label %278 unwind label %283

278:                                              ; preds = %276
  unreachable

279:                                              ; preds = %275
  %280 = landingpad { ptr, i32 }
          cleanup
  %281 = extractvalue { ptr, i32 } %280, 0
  store ptr %281, ptr %11, align 8
  %282 = extractvalue { ptr, i32 } %280, 1
  store i32 %282, ptr %12, align 4
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %34) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %34) #9
  br label %287

283:                                              ; preds = %276
  %284 = landingpad { ptr, i32 }
          cleanup
  %285 = extractvalue { ptr, i32 } %284, 0
  store ptr %285, ptr %11, align 8
  %286 = extractvalue { ptr, i32 } %284, 1
  store i32 %286, ptr %12, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %33) #9
  br label %287

287:                                              ; preds = %283, %279
  call void @llvm.lifetime.end.p0(i64 32, ptr %33) #9
  br label %291

288:                                              ; No predecessors!
  br label %289

289:                                              ; preds = %288
  br label %290

290:                                              ; preds = %289, %270, %266, %248
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %32) #9
  call void @llvm.lifetime.end.p0(i64 48, ptr %32) #9
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %31) #9
  call void @llvm.lifetime.end.p0(i64 48, ptr %31) #9
  br label %222, !llvm.loop !30

291:                                              ; preds = %287, %262
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %32) #9
  br label %292

292:                                              ; preds = %291, %258
  call void @llvm.lifetime.end.p0(i64 48, ptr %32) #9
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %31) #9
  br label %293

293:                                              ; preds = %292, %254
  call void @llvm.lifetime.end.p0(i64 48, ptr %31) #9
  br label %296

294:                                              ; preds = %222
  invoke void @_ZN7maliput3api10LaneSRouteC2ERKSt6vectorINS0_10LaneSRangeESaIS3_EE(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 8 dereferenceable(24) %21)
          to label %295 unwind label %250

295:                                              ; preds = %294
  call void @llvm.lifetime.end.p0(i64 4, ptr %30) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #9
  call void @_ZNSt6vectorIN7maliput3api10LaneSRangeESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %21) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %19) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %17) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %16) #9
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %13) #9
  call void @llvm.lifetime.end.p0(i64 48, ptr %13) #9
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %8) #9
  call void @llvm.lifetime.end.p0(i64 48, ptr %8) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #9
  ret void

296:                                              ; preds = %293, %250
  call void @llvm.lifetime.end.p0(i64 4, ptr %30) #9
  br label %297

297:                                              ; preds = %296, %218, %201, %163
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #9
  call void @_ZNSt6vectorIN7maliput3api10LaneSRangeESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr %21) #9
  br label %298

298:                                              ; preds = %297, %159
  call void @llvm.lifetime.end.p0(i64 16, ptr %20) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr %19) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #9
  br label %299

299:                                              ; preds = %298, %102
  call void @llvm.lifetime.end.p0(i64 24, ptr %17) #9
  br label %300

300:                                              ; preds = %299, %90
  call void @llvm.lifetime.end.p0(i64 24, ptr %16) #9
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %13) #9
  br label %301

301:                                              ; preds = %300, %89
  call void @llvm.lifetime.end.p0(i64 48, ptr %13) #9
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %8) #9
  br label %302

302:                                              ; preds = %301, %77
  call void @llvm.lifetime.end.p0(i64 48, ptr %8) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #9
  br label %303

303:                                              ; preds = %302
  %304 = load ptr, ptr %11, align 8
  %305 = load i32, ptr %12, align 4
  %306 = insertvalue { ptr, i32 } poison, ptr %304, 0
  %307 = insertvalue { ptr, i32 } %306, i32 %305, 1
  resume { ptr, i32 } %307
}

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(32) ptr @_ZNK7maliput7routing5Route18end_route_positionEv(ptr noundef nonnull align 8 dereferenceable(88)) #4 align 2

declare void @_ZNK7maliput3api4Lane2idEv(ptr dead_on_unwind writable sret(%"class.maliput::api::TypeSpecificIdentifier") align 8, ptr noundef nonnull align 8 dereferenceable(8)) #5

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

declare void @_ZN7maliput3api6SRangeC1Edd(ptr noundef nonnull align 8 dereferenceable(16), double noundef, double noundef) unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7maliput3api10LaneSRangeC2ERKNS0_22TypeSpecificIdentifierINS0_4LaneEEERKNS0_6SRangeE(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #4 align 2

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef zeroext i1 @"_ZZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEENK3$_1clERKNS1_15LaneSRangeIndexES9_"(ptr noundef nonnull align 1 dereferenceable(1), ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16)) #6 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEENK3$_0clERKNS1_15LaneSRangeIndexEPSt6vectorINS2_10LaneSRangeESaISB_EE"(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) #7 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNK7maliput7routing5Route23FindStraightPredecessorERKNS1_15LaneSRangeIndexE(ptr dead_on_unwind noalias writable sret(%"class.std::optional") align 8, ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(16)) #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZNK7maliput7routing5Route53FindDirectionTowardsLaneSRangeWithStraightPredecessorERKNS1_15LaneSRangeIndexE(ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(16)) #4 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #4 align 2

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZNK7maliput7routing5Route13GetLaneSRangeEii(ptr noundef nonnull align 8 dereferenceable(88), i32 noundef, i32 noundef) #4 align 2

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

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

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

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

attributes #0 = { noreturn "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 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { "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 #6 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #8 = { noreturn }
attributes #9 = { 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, !6, i64 0}
!10 = !{!"_ZTSN7maliput3api12RoadPositionE", !6, i64 0, !11, i64 8}
!11 = !{!"_ZTSN7maliput3api12LanePositionE", !12, i64 0}
!12 = !{!"_ZTSN7maliput4math7Vector3E", !13, i64 0}
!13 = !{!"_ZTSN7maliput4math10VectorBaseILm3ENS0_7Vector3EEE", !14, i64 0}
!14 = !{!"_ZTSSt5arrayIdLm3EE", !7, i64 0}
!15 = !{!16, !6, i64 0}
!16 = !{!"_ZTSZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEE3$_0", !6, i64 0}
!17 = !{i64 0, i64 8, !18, i64 8, i64 8, !18}
!18 = !{!19, !19, i64 0}
!19 = !{!"long", !7, i64 0}
!20 = !{!21, !19, i64 0}
!21 = !{!"_ZTSN7maliput7routing5Route15LaneSRangeIndexE", !19, i64 0, !19, i64 8}
!22 = !{!23, !23, i64 0}
!23 = !{!"int", !7, i64 0}
!24 = !{!21, !19, i64 8}
!25 = distinct !{!25, !26}
!26 = !{!"llvm.loop.mustprogress"}
!27 = distinct !{!27, !26}
!28 = !{!29, !29, i64 0}
!29 = !{!"_ZTSN7maliput7routing18LaneSRangeRelationE", !7, i64 0}
!30 = distinct !{!30, !26}


; 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::optional" = type { %"struct.std::_Optional_base" }
%"struct.std::_Optional_base" = type { %"struct.std::_Optional_payload" }
%"struct.std::_Optional_payload" = type { %"struct.std::_Optional_payload_base.base", [7 x i8] }
%"struct.std::_Optional_payload_base.base" = type <{ %"union.std::_Optional_payload_base<maliput::routing::Route::LaneSRangeIndex>::_Storage", i8 }>
%"union.std::_Optional_payload_base<maliput::routing::Route::LaneSRangeIndex>::_Storage" = type { %"struct.maliput::routing::Route::LaneSRangeIndex" }
%"struct.maliput::routing::Route::LaneSRangeIndex" = type { i64, i64 }
%"class.maliput::api::LaneSRoute" = type { %"class.std::vector.10" }
%"class.std::vector.10" = type { %"struct.std::_Vector_base.11" }
%"struct.std::_Vector_base.11" = type { %"struct.std::_Vector_base<maliput::api::LaneSRange, std::allocator<maliput::api::LaneSRange>>::_Vector_impl" }
%"struct.std::_Vector_base<maliput::api::LaneSRange, std::allocator<maliput::api::LaneSRange>>::_Vector_impl" = type { %"struct.std::_Vector_base<maliput::api::LaneSRange, std::allocator<maliput::api::LaneSRange>>::_Vector_impl_data" }
%"struct.std::_Vector_base<maliput::api::LaneSRange, std::allocator<maliput::api::LaneSRange>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.maliput::api::LaneSRange" = type { %"class.maliput::api::TypeSpecificIdentifier", %"class.maliput::api::SRange" }
%"class.maliput::api::TypeSpecificIdentifier" = type { %"class.std::__cxx11::basic_string" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.maliput::api::SRange" = type { double, double }
%class.anon.111 = type { ptr }
%class.anon.112 = type { i8 }
%"class.std::allocator.15" = type { i8 }

@.str.1 = external hidden unnamed_addr constant [78 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [31 x i8], align 1
@__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE = external hidden unnamed_addr constant [18 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [95 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [130 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [29 x i8], align 1

; Function Attrs: noreturn
declare void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef, ptr noundef, ptr noundef, i32 noundef) local_unnamed_addr #0

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIN7maliput7routing5PhaseESaIS2_EE4sizeEv(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 @_ZNK7maliput7routing5Phase13lane_s_rangesEv(ptr noundef nonnull align 8 dereferenceable(96)) local_unnamed_addr #2 align 2

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

; 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 nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(96) ptr @_ZNKSt6vectorIN7maliput7routing5PhaseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #2 align 2

; 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) #3

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZNK7maliput7routing5Route25ComputeLaneSRangeRelationERKNS_3api10LaneSRangeES5_(ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #4 align 2

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE(ptr dead_on_unwind noalias writable sret(%"class.maliput::api::LaneSRoute") align 8 %0, ptr noundef nonnull align 8 dereferenceable(88) %1, ptr noundef nonnull align 8 dereferenceable(32) %2) local_unnamed_addr #4 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca %"class.maliput::api::LaneSRange", align 8
  %5 = alloca %"class.maliput::api::TypeSpecificIdentifier", align 8
  %6 = alloca %"class.maliput::api::SRange", align 8
  %7 = alloca %"class.maliput::api::LaneSRange", align 8
  %8 = alloca %"class.maliput::api::TypeSpecificIdentifier", align 8
  %9 = alloca %"class.maliput::api::SRange", align 8
  %10 = alloca %"class.std::optional", align 8
  %11 = alloca %"class.std::optional", align 8
  %12 = alloca %class.anon.111, align 8
  %13 = alloca %class.anon.112, align 1
  %14 = alloca %"struct.maliput::routing::Route::LaneSRangeIndex", align 8
  %15 = alloca %"class.std::vector.10", align 8
  %16 = alloca %"class.std::optional", align 8
  %17 = alloca %"class.std::optional", align 8
  %18 = alloca %"class.std::__cxx11::basic_string", align 8
  %19 = alloca %"class.std::allocator.15", align 1
  %20 = alloca %"class.std::__cxx11::basic_string", align 8
  %21 = alloca %"class.std::allocator.15", align 1
  %22 = alloca %"class.maliput::api::LaneSRange", align 8
  %23 = alloca %"class.maliput::api::LaneSRange", align 8
  %24 = alloca %"class.std::__cxx11::basic_string", align 8
  %25 = alloca %"class.std::allocator.15", align 1
  %26 = load ptr, ptr %2, align 8, !tbaa !5
  %.not = icmp eq ptr %26, null
  br i1 %.not, label %27, label %28

27:                                               ; preds = %3
  tail call void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef nonnull @.str.4, ptr noundef nonnull @__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE, ptr noundef nonnull @.str.1, i32 noundef 209) #8
  unreachable

28:                                               ; preds = %3
  %29 = tail call noundef nonnull align 8 dereferenceable(32) ptr @_ZNK7maliput7routing5Route18end_route_positionEv(ptr noundef nonnull align 8 dereferenceable(88) %1)
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %4) #9
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %5) #9
  %30 = load ptr, ptr %29, align 8, !tbaa !5
  call void @_ZNK7maliput3api4Lane2idEv(ptr dead_on_unwind nonnull writable sret(%"class.maliput::api::TypeSpecificIdentifier") align 8 %5, ptr noundef nonnull align 8 dereferenceable(8) %30)
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) #9
  %31 = getelementptr inbounds i8, ptr %29, i64 8
  %32 = invoke noundef double @_ZNK7maliput3api12LanePosition1sEv(ptr noundef nonnull align 8 dereferenceable(24) %31)
          to label %33 unwind label %51

33:                                               ; preds = %28
  %34 = invoke noundef double @_ZNK7maliput3api12LanePosition1sEv(ptr noundef nonnull align 8 dereferenceable(24) %31)
          to label %35 unwind label %51

35:                                               ; preds = %33
  invoke void @_ZN7maliput3api6SRangeC1Edd(ptr noundef nonnull align 8 dereferenceable(16) %6, double noundef %32, double noundef %34)
          to label %36 unwind label %51

36:                                               ; preds = %35
  invoke void @_ZN7maliput3api10LaneSRangeC2ERKNS0_22TypeSpecificIdentifierINS0_4LaneEEERKNS0_6SRangeE(ptr noundef nonnull align 8 dereferenceable(48) %4, ptr noundef nonnull align 8 dereferenceable(32) %5, ptr noundef nonnull align 8 dereferenceable(16) %6)
          to label %37 unwind label %51

37:                                               ; preds = %36
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #9
  call void @_ZN7maliput3api22TypeSpecificIdentifierINS0_4LaneEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #9
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %7) #9
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %8) #9
  %38 = load ptr, ptr %2, align 8, !tbaa !5
  invoke void @_ZNK7maliput3api4Lane2idEv(ptr dead_on_unwind nonnull writable sret(%"class.maliput::api::TypeSpecificIdentifier") align 8 %8, ptr noundef nonnull align 8 dereferenceable(8) %38)
          to label %39 unwind label %53

39:                                               ; preds = %37
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %9) #9
  %40 = getelementptr inbounds i8, ptr %2, i64 8
  %41 = invoke noundef double @_ZNK7maliput3api12LanePosition1sEv(ptr noundef nonnull align 8 dereferenceable(24) %40)
          to label %42 unwind label %55

42:                                               ; preds = %39
  %43 = invoke noundef double @_ZNK7maliput3api12LanePosition1sEv(ptr noundef nonnull align 8 dereferenceable(24) %40)
          to label %44 unwind label %55

44:                                               ; preds = %42
  invoke void @_ZN7maliput3api6SRangeC1Edd(ptr noundef nonnull align 8 dereferenceable(16) %9, double noundef %41, double noundef %43)
          to label %45 unwind label %55

45:                                               ; preds = %44
  invoke void @_ZN7maliput3api10LaneSRangeC2ERKNS0_22TypeSpecificIdentifierINS0_4LaneEEERKNS0_6SRangeE(ptr noundef nonnull align 8 dereferenceable(48) %7, ptr noundef nonnull align 8 dereferenceable(32) %8, ptr noundef nonnull align 8 dereferenceable(16) %9)
          to label %46 unwind label %55

46:                                               ; preds = %45
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #9
  call void @_ZN7maliput3api22TypeSpecificIdentifierINS0_4LaneEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %8) #9
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %10) #9
  invoke void @_ZNK7maliput7routing5Route19FindLaneSRangeIndexERKNS_3api10LaneSRangeE(ptr dead_on_unwind nonnull writable sret(%"class.std::optional") align 8 %10, ptr noundef nonnull align 8 dereferenceable(88) %1, ptr noundef nonnull align 8 dereferenceable(48) %7)
          to label %47 unwind label %58

47:                                               ; preds = %46
  %48 = call noundef zeroext i1 @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE9has_valueEv(ptr noundef nonnull align 8 dereferenceable(24) %10) #9
  br i1 %48, label %60, label %49

49:                                               ; preds = %47
  invoke void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef nonnull @.str.5, ptr noundef nonnull @__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE, ptr noundef nonnull @.str.1, i32 noundef 219) #8
          to label %50 unwind label %58

50:                                               ; preds = %49
  unreachable

51:                                               ; preds = %36, %35, %33, %28
  %52 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #9
  call void @_ZN7maliput3api22TypeSpecificIdentifierINS0_4LaneEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #9
  br label %181

53:                                               ; preds = %37
  %54 = landingpad { ptr, i32 }
          cleanup
  br label %57

55:                                               ; preds = %45, %44, %42, %39
  %56 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) #9
  call void @_ZN7maliput3api22TypeSpecificIdentifierINS0_4LaneEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #9
  br label %57

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

58:                                               ; preds = %49, %46
  %59 = landingpad { ptr, i32 }
          cleanup
  br label %179

60:                                               ; preds = %47
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %11) #9
  invoke void @_ZNK7maliput7routing5Route19FindLaneSRangeIndexERKNS_3api10LaneSRangeE(ptr dead_on_unwind nonnull writable sret(%"class.std::optional") align 8 %11, ptr noundef nonnull align 8 dereferenceable(88) %1, ptr noundef nonnull align 8 dereferenceable(48) %4)
          to label %61 unwind label %65

61:                                               ; preds = %60
  %62 = call noundef zeroext i1 @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE9has_valueEv(ptr noundef nonnull align 8 dereferenceable(24) %11) #9
  br i1 %62, label %67, label %63

63:                                               ; preds = %61
  invoke void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef nonnull @.str.6, ptr noundef nonnull @__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE, ptr noundef nonnull @.str.1, i32 noundef 222) #8
          to label %64 unwind label %65

64:                                               ; preds = %63
  unreachable

65:                                               ; preds = %63, %60
  %66 = landingpad { ptr, i32 }
          cleanup
  br label %178

67:                                               ; preds = %61
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %12) #9
  store ptr %1, ptr %12, align 8, !tbaa !14
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %13) #9
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %14) #9
  %68 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNKRSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE5valueEv(ptr noundef nonnull align 8 dereferenceable(24) %11)
          to label %69 unwind label %98

69:                                               ; preds = %67
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef nonnull align 8 dereferenceable(16) %68, i64 16, i1 false), !tbaa.struct !16
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %15) #9
  call void @_ZNSt6vectorIN7maliput3api10LaneSRangeESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #9
  %70 = call noundef i64 @_ZNKSt6vectorIN7maliput7routing5PhaseESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #9
  %71 = call noundef ptr @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEEptEv(ptr noundef nonnull align 8 dereferenceable(24) %10) #9
  %72 = load i64, ptr %71, align 8, !tbaa !19
  %73 = sub i64 %70, %72
  %74 = trunc i64 %73 to i32
  %75 = icmp sgt i32 %74, -1
  br i1 %75, label %.lr.ph64, label %.critedge57

.lr.ph64:                                         ; preds = %69
  %76 = getelementptr inbounds i8, ptr %14, i64 8
  br label %77

77:                                               ; preds = %.lr.ph64, %121
  %.01862 = phi i32 [ %74, %.lr.ph64 ], [ %81, %121 ]
  %78 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNKRSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEEdeEv(ptr noundef nonnull align 8 dereferenceable(24) %10) #9
  %79 = call noundef zeroext i1 @"_ZZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEENK3$_1clERKNS1_15LaneSRangeIndexES9_"(ptr noundef nonnull align 1 dereferenceable(1) %13, ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef nonnull align 8 dereferenceable(16) %78)
  br i1 %79, label %.critedge.preheader, label %80

80:                                               ; preds = %77
  %81 = add nsw i32 %.01862, -1
  invoke void @"_ZZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEENK3$_0clERKNS1_15LaneSRangeIndexEPSt6vectorINS2_10LaneSRangeESaISB_EE"(ptr noundef nonnull align 8 dereferenceable(8) %12, ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef nonnull %15)
          to label %82 unwind label %100

82:                                               ; preds = %80
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %16) #9
  call void @_ZNSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  %83 = load i64, ptr %14, align 8, !tbaa !19
  %84 = call noundef nonnull align 8 dereferenceable(96) ptr @_ZNKSt6vectorIN7maliput7routing5PhaseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %83) #9
  %85 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7maliput7routing5Phase13lane_s_rangesEv(ptr noundef nonnull align 8 dereferenceable(96) %84)
  %86 = call noundef i64 @_ZNKSt6vectorIN7maliput3api10LaneSRangeESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %85) #9
  %87 = trunc i64 %86 to i32
  %88 = call noundef zeroext i1 @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE9has_valueEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  %89 = icmp slt i32 %87, 0
  %.not4660 = or i1 %88, %89
  br i1 %.not4660, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %82, %106
  %.01761 = phi i32 [ %107, %106 ], [ %87, %82 ]
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %17) #9
  invoke void @_ZNK7maliput7routing5Route23FindStraightPredecessorERKNS1_15LaneSRangeIndexE(ptr dead_on_unwind nonnull writable sret(%"class.std::optional") align 8 %17, ptr noundef nonnull align 8 dereferenceable(88) %1, ptr noundef nonnull align 8 dereferenceable(16) %14)
          to label %90 unwind label %104

90:                                               ; preds = %.lr.ph
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %16, ptr noundef nonnull align 8 dereferenceable(24) %17, i64 24, i1 false)
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %17) #9
  %91 = call noundef zeroext i1 @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE9has_valueEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  br i1 %91, label %106, label %92

92:                                               ; preds = %90
  %93 = invoke noundef i32 @_ZNK7maliput7routing5Route53FindDirectionTowardsLaneSRangeWithStraightPredecessorERKNS1_15LaneSRangeIndexE(ptr noundef nonnull align 8 dereferenceable(88) %1, ptr noundef nonnull align 8 dereferenceable(16) %14)
          to label %94 unwind label %102

94:                                               ; preds = %92
  %95 = sext i32 %93 to i64
  %96 = load i64, ptr %76, align 8, !tbaa !21
  %97 = add i64 %96, %95
  store i64 %97, ptr %76, align 8, !tbaa !21
  invoke void @"_ZZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEENK3$_0clERKNS1_15LaneSRangeIndexEPSt6vectorINS2_10LaneSRangeESaISB_EE"(ptr noundef nonnull align 8 dereferenceable(8) %12, ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef nonnull %15)
          to label %106 unwind label %102

98:                                               ; preds = %67
  %99 = landingpad { ptr, i32 }
          cleanup
  br label %177

100:                                              ; preds = %80
  %101 = landingpad { ptr, i32 }
          cleanup
  br label %176

102:                                              ; preds = %94, %92
  %103 = landingpad { ptr, i32 }
          cleanup
  br label %124

104:                                              ; preds = %.lr.ph
  %105 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %17) #9
  br label %124

106:                                              ; preds = %94, %90
  %107 = add nsw i32 %.01761, -1
  %108 = call noundef zeroext i1 @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE9has_valueEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  %109 = icmp slt i32 %.01761, 1
  %.not46 = select i1 %108, i1 true, i1 %109
  br i1 %.not46, label %._crit_edge, label %.lr.ph, !llvm.loop !22

._crit_edge:                                      ; preds = %106, %82
  %.lcssa = phi i1 [ %89, %82 ], [ %109, %106 ]
  br i1 %.lcssa, label %112, label %110

110:                                              ; preds = %._crit_edge
  %111 = call noundef zeroext i1 @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEE9has_valueEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  br i1 %111, label %121, label %112

112:                                              ; preds = %110, %._crit_edge
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %18) #9
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %19) #9
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %19) #9
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %18, ptr noundef nonnull @.str.7, ptr noundef nonnull align 1 dereferenceable(1) %19)
          to label %113 unwind label %116

113:                                              ; preds = %112
  %114 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %18) #9
  invoke void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef %114, ptr noundef nonnull @__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE, ptr noundef nonnull @.str.1, i32 noundef 264) #8
          to label %115 unwind label %118

115:                                              ; preds = %113
  unreachable

116:                                              ; preds = %112
  %117 = landingpad { ptr, i32 }
          cleanup
  br label %120

118:                                              ; preds = %113
  %119 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %18) #9
  br label %120

120:                                              ; preds = %118, %116
  %.pn47 = phi { ptr, i32 } [ %119, %118 ], [ %117, %116 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %19) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %19) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %18) #9
  br label %124

121:                                              ; preds = %110
  %122 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNRSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEEdeEv(ptr noundef nonnull align 8 dereferenceable(24) %16) #9
  call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef nonnull align 8 dereferenceable(16) %122, i64 16, i1 false), !tbaa.struct !16
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %16) #9
  %123 = icmp sgt i32 %.01862, 0
  br i1 %123, label %77, label %.critedge57, !llvm.loop !24

124:                                              ; preds = %120, %104, %102
  %.pn49 = phi { ptr, i32 } [ %103, %102 ], [ %105, %104 ], [ %.pn47, %120 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %16) #9
  br label %176

.critedge57:                                      ; preds = %121, %69
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %20) #9
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %21) #9
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %21) #9
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %20, ptr noundef nonnull @.str.8, ptr noundef nonnull align 1 dereferenceable(1) %21)
          to label %125 unwind label %128

125:                                              ; preds = %.critedge57
  %126 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %20) #9
  invoke void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef %126, ptr noundef nonnull @__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE, ptr noundef nonnull @.str.1, i32 noundef 271) #8
          to label %127 unwind label %130

127:                                              ; preds = %125
  unreachable

128:                                              ; preds = %.critedge57
  %129 = landingpad { ptr, i32 }
          cleanup
  br label %132

130:                                              ; preds = %125
  %131 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %20) #9
  br label %132

132:                                              ; preds = %130, %128
  %.pn36 = phi { ptr, i32 } [ %131, %130 ], [ %129, %128 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %21) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %21) #9
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %20) #9
  br label %176

.critedge.preheader:                              ; preds = %77, %.critedge
  invoke void @"_ZZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEENK3$_0clERKNS1_15LaneSRangeIndexEPSt6vectorINS2_10LaneSRangeESaISB_EE"(ptr noundef nonnull align 8 dereferenceable(8) %12, ptr noundef nonnull align 8 dereferenceable(16) %14, ptr noundef nonnull %15)
          to label %133 unwind label %.loopexit

133:                                              ; preds = %.critedge.preheader
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %22) #9
  %134 = call noundef ptr @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEEptEv(ptr noundef nonnull align 8 dereferenceable(24) %10) #9
  %135 = load i64, ptr %134, align 8, !tbaa !19
  %136 = trunc i64 %135 to i32
  %137 = call noundef ptr @_ZNKSt8optionalIN7maliput7routing5Route15LaneSRangeIndexEEptEv(ptr noundef nonnull align 8 dereferenceable(24) %10) #9
  %138 = getelementptr inbounds i8, ptr %137, i64 8
  %139 = load i64, ptr %138, align 8, !tbaa !21
  %140 = trunc i64 %139 to i32
  %141 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZNK7maliput7routing5Route13GetLaneSRangeEii(ptr noundef nonnull align 8 dereferenceable(88) %1, i32 noundef %136, i32 noundef %140)
          to label %142 unwind label %153

142:                                              ; preds = %133
  invoke void @_ZN7maliput3api10LaneSRangeC2ERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %22, ptr noundef nonnull align 8 dereferenceable(48) %141)
          to label %143 unwind label %153

143:                                              ; preds = %142
  call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %23) #9
  %144 = load i64, ptr %14, align 8, !tbaa !19
  %145 = trunc i64 %144 to i32
  %146 = load i64, ptr %76, align 8, !tbaa !21
  %147 = trunc i64 %146 to i32
  %148 = invoke noundef nonnull align 8 dereferenceable(48) ptr @_ZNK7maliput7routing5Route13GetLaneSRangeEii(ptr noundef nonnull align 8 dereferenceable(88) %1, i32 noundef %145, i32 noundef %147)
          to label %149 unwind label %155

149:                                              ; preds = %143
  invoke void @_ZN7maliput3api10LaneSRangeC2ERKS1_(ptr noundef nonnull align 8 dereferenceable(48) %23, ptr noundef nonnull align 8 dereferenceable(48) %148)
          to label %150 unwind label %155

150:                                              ; preds = %149
  %151 = invoke noundef i32 @_ZNK7maliput7routing5Route25ComputeLaneSRangeRelationERKNS_3api10LaneSRangeES5_(ptr noundef nonnull align 8 dereferenceable(88) %1, ptr noundef nonnull align 8 dereferenceable(48) %22, ptr noundef nonnull align 8 dereferenceable(48) %23)
          to label %152 unwind label %157

152:                                              ; preds = %150
  switch i32 %151, label %160 [
    i32 2, label %.critedge.sink.split
    i32 0, label %.critedge.sink.split
    i32 3, label %159
    i32 1, label %159
    i32 10, label %.critedge
  ]

.loopexit:                                        ; preds = %.critedge.preheader
  %lpad.loopexit = landingpad { ptr, i32 }
          cleanup
  br label %176

.loopexit.split-lp:                               ; preds = %174
  %lpad.loopexit.split-lp = landingpad { ptr, i32 }
          cleanup
  br label %176

153:                                              ; preds = %142, %133
  %154 = landingpad { ptr, i32 }
          cleanup
  br label %173

155:                                              ; preds = %149, %143
  %156 = landingpad { ptr, i32 }
          cleanup
  br label %172

157:                                              ; preds = %150
  %158 = landingpad { ptr, i32 }
          cleanup
  br label %171

159:                                              ; preds = %152, %152
  br label %.critedge.sink.split

160:                                              ; preds = %152
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %24) #9
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %25) #9
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %25) #9
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %24, ptr noundef nonnull @.str.9, ptr noundef nonnull align 1 dereferenceable(1) %25)
          to label %161 unwind label %164

161:                                              ; preds = %160
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %25) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %25) #9
  %162 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %24) #9
  invoke void @_ZN7maliput6common8internal5ThrowEPKcS3_S3_i(ptr noundef %162, ptr noundef nonnull @__func__._ZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionE, ptr noundef nonnull @.str.1, i32 noundef 298) #8
          to label %163 unwind label %166

163:                                              ; preds = %161
  unreachable

164:                                              ; preds = %160
  %165 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %25) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %25) #9
  br label %168

166:                                              ; preds = %161
  %167 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %24) #9
  br label %168

168:                                              ; preds = %166, %164
  %.pn39 = phi { ptr, i32 } [ %167, %166 ], [ %165, %164 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %24) #9
  br label %171

.critedge.sink.split:                             ; preds = %152, %152, %159
  %.sink68 = phi i64 [ 1, %159 ], [ -1, %152 ], [ -1, %152 ]
  %169 = load i64, ptr %76, align 8, !tbaa !21
  %170 = add i64 %169, %.sink68
  store i64 %170, ptr %76, align 8, !tbaa !21
  br label %.critedge

.critedge:                                        ; preds = %.critedge.sink.split, %152
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %23) #9
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %23) #9
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %22) #9
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %22) #9
  %.not38 = icmp eq i32 %151, 10
  br i1 %.not38, label %174, label %.critedge.preheader, !llvm.loop !25

171:                                              ; preds = %168, %157
  %.pn39.pn = phi { ptr, i32 } [ %.pn39, %168 ], [ %158, %157 ]
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %23) #9
  br label %172

172:                                              ; preds = %171, %155
  %.pn39.pn.pn = phi { ptr, i32 } [ %.pn39.pn, %171 ], [ %156, %155 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %23) #9
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %22) #9
  br label %173

173:                                              ; preds = %172, %153
  %.pn39.pn.pn.pn = phi { ptr, i32 } [ %.pn39.pn.pn, %172 ], [ %154, %153 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %22) #9
  br label %176

174:                                              ; preds = %.critedge
  invoke void @_ZN7maliput3api10LaneSRouteC2ERKSt6vectorINS0_10LaneSRangeESaIS3_EE(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 8 dereferenceable(24) %15)
          to label %175 unwind label %.loopexit.split-lp

175:                                              ; preds = %174
  call void @_ZNSt6vectorIN7maliput3api10LaneSRangeESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %15) #9
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %14) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %13) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %11) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %10) #9
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %7) #9
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %7) #9
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #9
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %4) #9
  ret void

176:                                              ; preds = %.loopexit, %.loopexit.split-lp, %173, %132, %124, %100
  %.pn49.pn = phi { ptr, i32 } [ %.pn49, %124 ], [ %101, %100 ], [ %.pn36, %132 ], [ %.pn39.pn.pn.pn, %173 ], [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ]
  call void @_ZNSt6vectorIN7maliput3api10LaneSRangeESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #9
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %15) #9
  br label %177

177:                                              ; preds = %176, %98
  %.pn49.pn.pn = phi { ptr, i32 } [ %.pn49.pn, %176 ], [ %99, %98 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %14) #9
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %13) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %12) #9
  br label %178

178:                                              ; preds = %177, %65
  %.pn49.pn.pn.pn = phi { ptr, i32 } [ %.pn49.pn.pn, %177 ], [ %66, %65 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %11) #9
  br label %179

179:                                              ; preds = %178, %58
  %.pn49.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn49.pn.pn.pn, %178 ], [ %59, %58 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %10) #9
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %7) #9
  br label %180

180:                                              ; preds = %179, %57
  %.pn49.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn49.pn.pn.pn.pn, %179 ], [ %.pn, %57 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %7) #9
  call void @_ZN7maliput3api10LaneSRangeD2Ev(ptr noundef nonnull align 8 dereferenceable(48) %4) #9
  br label %181

181:                                              ; preds = %180, %51
  %.pn49.pn.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn49.pn.pn.pn.pn.pn, %180 ], [ %52, %51 ]
  call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %4) #9
  resume { ptr, i32 } %.pn49.pn.pn.pn.pn.pn.pn
}

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(32) ptr @_ZNK7maliput7routing5Route18end_route_positionEv(ptr noundef nonnull align 8 dereferenceable(88)) local_unnamed_addr #4 align 2

declare void @_ZNK7maliput3api4Lane2idEv(ptr dead_on_unwind writable sret(%"class.maliput::api::TypeSpecificIdentifier") align 8, ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #5

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

declare void @_ZN7maliput3api6SRangeC1Edd(ptr noundef nonnull align 8 dereferenceable(16), double noundef, double noundef) unnamed_addr #5

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7maliput3api10LaneSRangeC2ERKNS0_22TypeSpecificIdentifierINS0_4LaneEEERKNS0_6SRangeE(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #4 align 2

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef zeroext i1 @"_ZZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEENK3$_1clERKNS1_15LaneSRangeIndexES9_"(ptr noundef nonnull align 1 dereferenceable(1), ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #6 align 2

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

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEENK3$_0clERKNS1_15LaneSRangeIndexEPSt6vectorINS2_10LaneSRangeESaISB_EE"(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) local_unnamed_addr #7 align 2

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZNK7maliput7routing5Route53FindDirectionTowardsLaneSRangeWithStraightPredecessorERKNS1_15LaneSRangeIndexE(ptr noundef nonnull align 8 dereferenceable(88), ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #4 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #4 align 2

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef nonnull align 8 dereferenceable(48) ptr @_ZNK7maliput7routing5Route13GetLaneSRangeEii(ptr noundef nonnull align 8 dereferenceable(88), i32 noundef, i32 noundef) local_unnamed_addr #4 align 2

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

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

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

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

attributes #0 = { noreturn "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 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { "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 #6 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #8 = { noreturn }
attributes #9 = { 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, !7, i64 0}
!6 = !{!"_ZTSN7maliput3api12RoadPositionE", !7, i64 0, !10, i64 8}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"_ZTSN7maliput3api12LanePositionE", !11, i64 0}
!11 = !{!"_ZTSN7maliput4math7Vector3E", !12, i64 0}
!12 = !{!"_ZTSN7maliput4math10VectorBaseILm3ENS0_7Vector3EEE", !13, i64 0}
!13 = !{!"_ZTSSt5arrayIdLm3EE", !8, i64 0}
!14 = !{!15, !7, i64 0}
!15 = !{!"_ZTSZNK7maliput7routing5Route17ComputeLaneSRouteERKNS_3api12RoadPositionEE3$_0", !7, i64 0}
!16 = !{i64 0, i64 8, !17, i64 8, i64 8, !17}
!17 = !{!18, !18, i64 0}
!18 = !{!"long", !8, i64 0}
!19 = !{!20, !18, i64 0}
!20 = !{!"_ZTSN7maliput7routing5Route15LaneSRangeIndexE", !18, i64 0, !18, i64 8}
!21 = !{!20, !18, i64 8}
!22 = distinct !{!22, !23}
!23 = !{!"llvm.loop.mustprogress"}
!24 = distinct !{!24, !23}
!25 = distinct !{!25, !23}


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