; LLVM IR from thepowersgang/mrustc :: src/hir_typeck/impl_ref.ll (ZNK7ImplRef13overlaps_withERKN3HIR5CrateERKS_)

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

%struct.ImplRef = type { %"class.ImplRef::Data" }
%"class.ImplRef::Data" = type { i32, %"union.ImplRef::Data::DataUnion" }
%"union.ImplRef::Data::DataUnion" = type { %"struct.ImplRef::Data::Data_Bounded" }
%"struct.ImplRef::Data::Data_Bounded" = type { %"class.HIR::GenericParams", %"class.HIR::TypeRef", %"struct.HIR::PathParams", %"class.std::map" }
%"class.HIR::GenericParams" = type { %"class.std::vector", %"class.std::vector.2", %"class.std::vector.7", %"class.std::vector.12" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<HIR::TypeParamDef, std::allocator<HIR::TypeParamDef>>::_Vector_impl" }
%"struct.std::_Vector_base<HIR::TypeParamDef, std::allocator<HIR::TypeParamDef>>::_Vector_impl" = type { %"struct.std::_Vector_base<HIR::TypeParamDef, std::allocator<HIR::TypeParamDef>>::_Vector_impl_data" }
%"struct.std::_Vector_base<HIR::TypeParamDef, std::allocator<HIR::TypeParamDef>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.2" = type { %"struct.std::_Vector_base.3" }
%"struct.std::_Vector_base.3" = type { %"struct.std::_Vector_base<HIR::LifetimeDef, std::allocator<HIR::LifetimeDef>>::_Vector_impl" }
%"struct.std::_Vector_base<HIR::LifetimeDef, std::allocator<HIR::LifetimeDef>>::_Vector_impl" = type { %"struct.std::_Vector_base<HIR::LifetimeDef, std::allocator<HIR::LifetimeDef>>::_Vector_impl_data" }
%"struct.std::_Vector_base<HIR::LifetimeDef, std::allocator<HIR::LifetimeDef>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.7" = type { %"struct.std::_Vector_base.8" }
%"struct.std::_Vector_base.8" = type { %"struct.std::_Vector_base<HIR::ValueParamDef, std::allocator<HIR::ValueParamDef>>::_Vector_impl" }
%"struct.std::_Vector_base<HIR::ValueParamDef, std::allocator<HIR::ValueParamDef>>::_Vector_impl" = type { %"struct.std::_Vector_base<HIR::ValueParamDef, std::allocator<HIR::ValueParamDef>>::_Vector_impl_data" }
%"struct.std::_Vector_base<HIR::ValueParamDef, std::allocator<HIR::ValueParamDef>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.12" = type { %"struct.std::_Vector_base.13" }
%"struct.std::_Vector_base.13" = type { %"struct.std::_Vector_base<HIR::GenericBound, std::allocator<HIR::GenericBound>>::_Vector_impl" }
%"struct.std::_Vector_base<HIR::GenericBound, std::allocator<HIR::GenericBound>>::_Vector_impl" = type { %"struct.std::_Vector_base<HIR::GenericBound, std::allocator<HIR::GenericBound>>::_Vector_impl_data" }
%"struct.std::_Vector_base<HIR::GenericBound, std::allocator<HIR::GenericBound>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.HIR::TypeRef" = type { ptr }
%"struct.HIR::PathParams" = type { %class.ThinVector, %class.ThinVector.0, %class.ThinVector.1 }
%class.ThinVector = type { ptr }
%class.ThinVector.0 = type { ptr }
%class.ThinVector.1 = type { ptr }
%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<RcString, std::pair<const RcString, HIR::TraitPath::AtyEqual>, std::_Select1st<std::pair<const RcString, HIR::TraitPath::AtyEqual>>, std::less<RcString>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<RcString, std::pair<const RcString, HIR::TraitPath::AtyEqual>, std::_Select1st<std::pair<const RcString, HIR::TraitPath::AtyEqual>>, std::less<RcString>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"struct.ImplRef::Data::Data_TraitImpl" = type { %"struct.HIR::PathParams", ptr, ptr, ptr, %"class.HIR::TypeRef" }
%"struct.ImplRef::Data::Data_BoundedPtr" = type { ptr, ptr, ptr, ptr }

@.str = external hidden unnamed_addr constant [39 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [82 x i8], align 1
@__PRETTY_FUNCTION__._ZNK7ImplRef13overlaps_withERKN3HIR5CrateERKS_ = external hidden unnamed_addr constant [73 x i8], align 1

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

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #1

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

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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_ZNK7ImplRef13overlaps_withERKN3HIR5CrateERKS_(ptr noundef nonnull align 8 dereferenceable(184) %0, ptr noundef nonnull align 8 dereferenceable(944) %1, ptr noundef nonnull align 8 dereferenceable(184) %2) #3 align 2 {
  %4 = alloca i1, align 1
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  %15 = load ptr, ptr %5, align 8
  %16 = getelementptr inbounds %struct.ImplRef, ptr %15, i32 0, i32 0
  %17 = call noundef i32 @_ZNK7ImplRef4Data3tagEv(ptr noundef nonnull align 8 dereferenceable(184) %16)
  %18 = load ptr, ptr %7, align 8, !tbaa !5
  %19 = getelementptr inbounds %struct.ImplRef, ptr %18, i32 0, i32 0
  %20 = call noundef i32 @_ZNK7ImplRef4Data3tagEv(ptr noundef nonnull align 8 dereferenceable(184) %19)
  %21 = icmp ne i32 %17, %20
  br i1 %21, label %22, label %23

22:                                               ; preds = %3
  store i1 false, ptr %4, align 1
  br label %108

23:                                               ; preds = %3
  %24 = getelementptr inbounds %struct.ImplRef, ptr %15, i32 0, i32 0
  %25 = call noundef i32 @_ZNK7ImplRef4Data3tagEv(ptr noundef nonnull align 8 dereferenceable(184) %24)
  switch i32 %25, label %107 [
    i32 0, label %26
    i32 1, label %27
    i32 2, label %57
    i32 3, label %84
  ]

26:                                               ; preds = %23
  call void @__assert_fail(ptr noundef @.str, ptr noundef @.str.1, i32 noundef 83, ptr noundef @__PRETTY_FUNCTION__._ZNK7ImplRef13overlaps_withERKN3HIR5CrateERKS_) #5
  unreachable

27:                                               ; preds = %23
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #6
  %28 = getelementptr inbounds %struct.ImplRef, ptr %15, i32 0, i32 0
  %29 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZNK7ImplRef4Data12as_TraitImplEv(ptr noundef nonnull align 8 dereferenceable(184) %28)
  store ptr %29, ptr %8, align 8, !tbaa !5
  %30 = load ptr, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #6
  %31 = load ptr, ptr %7, align 8, !tbaa !5
  %32 = getelementptr inbounds %struct.ImplRef, ptr %31, i32 0, i32 0
  %33 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZNK7ImplRef4Data12as_TraitImplEv(ptr noundef nonnull align 8 dereferenceable(184) %32)
  store ptr %33, ptr %9, align 8, !tbaa !5
  %34 = load ptr, ptr %9, align 8, !tbaa !5
  %35 = load ptr, ptr %8, align 8, !tbaa !5
  %36 = getelementptr inbounds %"struct.ImplRef::Data::Data_TraitImpl", ptr %35, i32 0, i32 3
  %37 = load ptr, ptr %36, align 8, !tbaa !9
  %38 = icmp ne ptr %37, null
  br i1 %38, label %39, label %53

39:                                               ; preds = %27
  %40 = load ptr, ptr %9, align 8, !tbaa !5
  %41 = getelementptr inbounds %"struct.ImplRef::Data::Data_TraitImpl", ptr %40, i32 0, i32 3
  %42 = load ptr, ptr %41, align 8, !tbaa !9
  %43 = icmp ne ptr %42, null
  br i1 %43, label %44, label %53

44:                                               ; preds = %39
  %45 = load ptr, ptr %8, align 8, !tbaa !5
  %46 = getelementptr inbounds %"struct.ImplRef::Data::Data_TraitImpl", ptr %45, i32 0, i32 3
  %47 = load ptr, ptr %46, align 8, !tbaa !9
  %48 = load ptr, ptr %6, align 8, !tbaa !5
  %49 = load ptr, ptr %9, align 8, !tbaa !5
  %50 = getelementptr inbounds %"struct.ImplRef::Data::Data_TraitImpl", ptr %49, i32 0, i32 3
  %51 = load ptr, ptr %50, align 8, !tbaa !9
  %52 = call noundef zeroext i1 @_ZNK3HIR9TraitImpl13overlaps_withERKNS_5CrateERKS0_(ptr noundef nonnull align 8 dereferenceable(328) %47, ptr noundef nonnull align 8 dereferenceable(944) %48, ptr noundef nonnull align 8 dereferenceable(328) %51)
  store i1 %52, ptr %4, align 1
  store i32 1, ptr %10, align 4
  br label %54

53:                                               ; preds = %39, %27
  store i32 0, ptr %10, align 4
  br label %54

54:                                               ; preds = %53, %44
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  %55 = load i32, ptr %10, align 4
  switch i32 %55, label %110 [
    i32 0, label %56
    i32 1, label %108
  ]

56:                                               ; preds = %54
  br label %107

57:                                               ; preds = %23
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  %58 = getelementptr inbounds %struct.ImplRef, ptr %15, i32 0, i32 0
  %59 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNK7ImplRef4Data13as_BoundedPtrEv(ptr noundef nonnull align 8 dereferenceable(184) %58)
  store ptr %59, ptr %11, align 8, !tbaa !5
  %60 = load ptr, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #6
  %61 = load ptr, ptr %7, align 8, !tbaa !5
  %62 = getelementptr inbounds %struct.ImplRef, ptr %61, i32 0, i32 0
  %63 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNK7ImplRef4Data13as_BoundedPtrEv(ptr noundef nonnull align 8 dereferenceable(184) %62)
  store ptr %63, ptr %12, align 8, !tbaa !5
  %64 = load ptr, ptr %12, align 8, !tbaa !5
  %65 = load ptr, ptr %11, align 8, !tbaa !5
  %66 = getelementptr inbounds %"struct.ImplRef::Data::Data_BoundedPtr", ptr %65, i32 0, i32 1
  %67 = load ptr, ptr %66, align 8, !tbaa !16
  %68 = load ptr, ptr %12, align 8, !tbaa !5
  %69 = getelementptr inbounds %"struct.ImplRef::Data::Data_BoundedPtr", ptr %68, i32 0, i32 1
  %70 = load ptr, ptr %69, align 8, !tbaa !16
  %71 = call noundef zeroext i1 @_ZNK3HIR7TypeRefneERKS0_(ptr noundef nonnull align 8 dereferenceable(8) %67, ptr noundef nonnull align 8 dereferenceable(8) %70)
  br i1 %71, label %72, label %73

72:                                               ; preds = %57
  store i1 false, ptr %4, align 1
  store i32 1, ptr %10, align 4
  br label %83

73:                                               ; preds = %57
  %74 = load ptr, ptr %11, align 8, !tbaa !5
  %75 = getelementptr inbounds %"struct.ImplRef::Data::Data_BoundedPtr", ptr %74, i32 0, i32 2
  %76 = load ptr, ptr %75, align 8, !tbaa !18
  %77 = load ptr, ptr %12, align 8, !tbaa !5
  %78 = getelementptr inbounds %"struct.ImplRef::Data::Data_BoundedPtr", ptr %77, i32 0, i32 2
  %79 = load ptr, ptr %78, align 8, !tbaa !18
  %80 = call noundef zeroext i1 @_ZNK3HIR10PathParamsneERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %76, ptr noundef nonnull align 8 dereferenceable(24) %79)
  br i1 %80, label %81, label %82

81:                                               ; preds = %73
  store i1 false, ptr %4, align 1
  store i32 1, ptr %10, align 4
  br label %83

82:                                               ; preds = %73
  store i1 true, ptr %4, align 1
  store i32 1, ptr %10, align 4
  br label %83

83:                                               ; preds = %82, %81, %72
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  br label %108

84:                                               ; preds = %23
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #6
  %85 = getelementptr inbounds %struct.ImplRef, ptr %15, i32 0, i32 0
  %86 = call noundef nonnull align 8 dereferenceable(176) ptr @_ZNK7ImplRef4Data10as_BoundedEv(ptr noundef nonnull align 8 dereferenceable(184) %85)
  store ptr %86, ptr %13, align 8, !tbaa !5
  %87 = load ptr, ptr %13, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #6
  %88 = load ptr, ptr %7, align 8, !tbaa !5
  %89 = getelementptr inbounds %struct.ImplRef, ptr %88, i32 0, i32 0
  %90 = call noundef nonnull align 8 dereferenceable(176) ptr @_ZNK7ImplRef4Data10as_BoundedEv(ptr noundef nonnull align 8 dereferenceable(184) %89)
  store ptr %90, ptr %14, align 8, !tbaa !5
  %91 = load ptr, ptr %14, align 8, !tbaa !5
  %92 = load ptr, ptr %13, align 8, !tbaa !5
  %93 = getelementptr inbounds %"struct.ImplRef::Data::Data_Bounded", ptr %92, i32 0, i32 1
  %94 = load ptr, ptr %14, align 8, !tbaa !5
  %95 = getelementptr inbounds %"struct.ImplRef::Data::Data_Bounded", ptr %94, i32 0, i32 1
  %96 = call noundef zeroext i1 @_ZNK3HIR7TypeRefneERKS0_(ptr noundef nonnull align 8 dereferenceable(8) %93, ptr noundef nonnull align 8 dereferenceable(8) %95)
  br i1 %96, label %97, label %98

97:                                               ; preds = %84
  store i1 false, ptr %4, align 1
  store i32 1, ptr %10, align 4
  br label %106

98:                                               ; preds = %84
  %99 = load ptr, ptr %13, align 8, !tbaa !5
  %100 = getelementptr inbounds %"struct.ImplRef::Data::Data_Bounded", ptr %99, i32 0, i32 2
  %101 = load ptr, ptr %14, align 8, !tbaa !5
  %102 = getelementptr inbounds %"struct.ImplRef::Data::Data_Bounded", ptr %101, i32 0, i32 2
  %103 = call noundef zeroext i1 @_ZNK3HIR10PathParamsneERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %100, ptr noundef nonnull align 8 dereferenceable(24) %102)
  br i1 %103, label %104, label %105

104:                                              ; preds = %98
  store i1 false, ptr %4, align 1
  store i32 1, ptr %10, align 4
  br label %106

105:                                              ; preds = %98
  store i1 true, ptr %4, align 1
  store i32 1, ptr %10, align 4
  br label %106

106:                                              ; preds = %105, %104, %97
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  br label %108

107:                                              ; preds = %56, %23
  store i1 false, ptr %4, align 1
  br label %108

108:                                              ; preds = %107, %106, %83, %54, %22
  %109 = load i1, ptr %4, align 1
  ret i1 %109

110:                                              ; preds = %54
  unreachable
}

declare noundef zeroext i1 @_ZNK3HIR9TraitImpl13overlaps_withERKNS_5CrateERKS0_(ptr noundef nonnull align 8 dereferenceable(328), ptr noundef nonnull align 8 dereferenceable(944), ptr noundef nonnull align 8 dereferenceable(328)) #4

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZNK3HIR7TypeRefneERKS0_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #3 align 2

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

attributes #0 = { 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 #1 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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 #4 = { "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 = { noreturn nounwind }
attributes #6 = { 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 40}
!10 = !{!"_ZTSN7ImplRef4Data14Data_TraitImplE", !11, i64 0, !6, i64 24, !6, i64 32, !6, i64 40, !15, i64 48}
!11 = !{!"_ZTSN3HIR10PathParamsE", !12, i64 0, !13, i64 8, !14, i64 16}
!12 = !{!"_ZTS10ThinVectorIN3HIR11LifetimeRefEE", !6, i64 0}
!13 = !{!"_ZTS10ThinVectorIN3HIR7TypeRefEE", !6, i64 0}
!14 = !{!"_ZTS10ThinVectorIN3HIR12ConstGenericEE", !6, i64 0}
!15 = !{!"_ZTSN3HIR7TypeRefE", !6, i64 0}
!16 = !{!17, !6, i64 8}
!17 = !{!"_ZTSN7ImplRef4Data15Data_BoundedPtrE", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!18 = !{!17, !6, i64 16}


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

@.str = external hidden unnamed_addr constant [39 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [82 x i8], align 1
@__PRETTY_FUNCTION__._ZNK7ImplRef13overlaps_withERKN3HIR5CrateERKS_ = external hidden unnamed_addr constant [73 x i8], align 1

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

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_ZNK7ImplRef13overlaps_withERKN3HIR5CrateERKS_(ptr noundef nonnull align 8 dereferenceable(184) %0, ptr noundef nonnull align 8 dereferenceable(944) %1, ptr noundef nonnull align 8 dereferenceable(184) %2) local_unnamed_addr #2 align 2 {
  %4 = tail call noundef i32 @_ZNK7ImplRef4Data3tagEv(ptr noundef nonnull align 8 dereferenceable(184) %0)
  %5 = tail call noundef i32 @_ZNK7ImplRef4Data3tagEv(ptr noundef nonnull align 8 dereferenceable(184) %2)
  %.not = icmp eq i32 %4, %5
  br i1 %.not, label %6, label %.thread

6:                                                ; preds = %3
  %7 = tail call noundef i32 @_ZNK7ImplRef4Data3tagEv(ptr noundef nonnull align 8 dereferenceable(184) %0)
  switch i32 %7, label %.thread [
    i32 0, label %8
    i32 1, label %9
    i32 2, label %19
    i32 3, label %33
  ]

8:                                                ; preds = %6
  tail call void @__assert_fail(ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, i32 noundef 83, ptr noundef nonnull @__PRETTY_FUNCTION__._ZNK7ImplRef13overlaps_withERKN3HIR5CrateERKS_) #4
  unreachable

9:                                                ; preds = %6
  %10 = tail call noundef nonnull align 8 dereferenceable(56) ptr @_ZNK7ImplRef4Data12as_TraitImplEv(ptr noundef nonnull align 8 dereferenceable(184) %0)
  %11 = tail call noundef nonnull align 8 dereferenceable(56) ptr @_ZNK7ImplRef4Data12as_TraitImplEv(ptr noundef nonnull align 8 dereferenceable(184) %2)
  %12 = getelementptr inbounds i8, ptr %10, i64 40
  %13 = load ptr, ptr %12, align 8, !tbaa !5
  %.not28 = icmp eq ptr %13, null
  br i1 %.not28, label %.thread, label %14

14:                                               ; preds = %9
  %15 = getelementptr inbounds i8, ptr %11, i64 40
  %16 = load ptr, ptr %15, align 8, !tbaa !5
  %.not29 = icmp eq ptr %16, null
  br i1 %.not29, label %.thread, label %17

17:                                               ; preds = %14
  %18 = tail call noundef zeroext i1 @_ZNK3HIR9TraitImpl13overlaps_withERKNS_5CrateERKS0_(ptr noundef nonnull align 8 dereferenceable(328) %13, ptr noundef nonnull align 8 dereferenceable(944) %1, ptr noundef nonnull align 8 dereferenceable(328) %16)
  br label %.thread

19:                                               ; preds = %6
  %20 = tail call noundef nonnull align 8 dereferenceable(32) ptr @_ZNK7ImplRef4Data13as_BoundedPtrEv(ptr noundef nonnull align 8 dereferenceable(184) %0)
  %21 = tail call noundef nonnull align 8 dereferenceable(32) ptr @_ZNK7ImplRef4Data13as_BoundedPtrEv(ptr noundef nonnull align 8 dereferenceable(184) %2)
  %22 = getelementptr inbounds i8, ptr %20, i64 8
  %23 = load ptr, ptr %22, align 8, !tbaa !15
  %24 = getelementptr inbounds i8, ptr %21, i64 8
  %25 = load ptr, ptr %24, align 8, !tbaa !15
  %26 = tail call noundef zeroext i1 @_ZNK3HIR7TypeRefneERKS0_(ptr noundef nonnull align 8 dereferenceable(8) %23, ptr noundef nonnull align 8 dereferenceable(8) %25)
  br i1 %26, label %.thread, label %27

27:                                               ; preds = %19
  %28 = getelementptr inbounds i8, ptr %20, i64 16
  %29 = load ptr, ptr %28, align 8, !tbaa !17
  %30 = getelementptr inbounds i8, ptr %21, i64 16
  %31 = load ptr, ptr %30, align 8, !tbaa !17
  %32 = tail call noundef zeroext i1 @_ZNK3HIR10PathParamsneERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %29, ptr noundef nonnull align 8 dereferenceable(24) %31)
  %not.34 = xor i1 %32, true
  br label %.thread

33:                                               ; preds = %6
  %34 = tail call noundef nonnull align 8 dereferenceable(176) ptr @_ZNK7ImplRef4Data10as_BoundedEv(ptr noundef nonnull align 8 dereferenceable(184) %0)
  %35 = tail call noundef nonnull align 8 dereferenceable(176) ptr @_ZNK7ImplRef4Data10as_BoundedEv(ptr noundef nonnull align 8 dereferenceable(184) %2)
  %36 = getelementptr inbounds i8, ptr %34, i64 96
  %37 = getelementptr inbounds i8, ptr %35, i64 96
  %38 = tail call noundef zeroext i1 @_ZNK3HIR7TypeRefneERKS0_(ptr noundef nonnull align 8 dereferenceable(8) %36, ptr noundef nonnull align 8 dereferenceable(8) %37)
  br i1 %38, label %.thread, label %39

39:                                               ; preds = %33
  %40 = getelementptr inbounds i8, ptr %34, i64 104
  %41 = getelementptr inbounds i8, ptr %35, i64 104
  %42 = tail call noundef zeroext i1 @_ZNK3HIR10PathParamsneERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %40, ptr noundef nonnull align 8 dereferenceable(24) %41)
  %not. = xor i1 %42, true
  br label %.thread

.thread:                                          ; preds = %9, %14, %6, %17, %33, %39, %19, %27, %3
  %.3 = phi i1 [ %18, %17 ], [ false, %3 ], [ false, %19 ], [ %not.34, %27 ], [ false, %33 ], [ %not., %39 ], [ false, %6 ], [ false, %14 ], [ false, %9 ]
  ret i1 %.3
}

declare noundef zeroext i1 @_ZNK3HIR9TraitImpl13overlaps_withERKNS_5CrateERKS0_(ptr noundef nonnull align 8 dereferenceable(328), ptr noundef nonnull align 8 dereferenceable(944), ptr noundef nonnull align 8 dereferenceable(328)) local_unnamed_addr #3

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

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

attributes #0 = { 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 #1 = { noreturn nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { noreturn 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, !9, i64 40}
!6 = !{!"_ZTSN7ImplRef4Data14Data_TraitImplE", !7, i64 0, !9, i64 24, !9, i64 32, !9, i64 40, !14, i64 48}
!7 = !{!"_ZTSN3HIR10PathParamsE", !8, i64 0, !12, i64 8, !13, i64 16}
!8 = !{!"_ZTS10ThinVectorIN3HIR11LifetimeRefEE", !9, i64 0}
!9 = !{!"any pointer", !10, i64 0}
!10 = !{!"omnipotent char", !11, i64 0}
!11 = !{!"Simple C++ TBAA"}
!12 = !{!"_ZTS10ThinVectorIN3HIR7TypeRefEE", !9, i64 0}
!13 = !{!"_ZTS10ThinVectorIN3HIR12ConstGenericEE", !9, i64 0}
!14 = !{!"_ZTSN3HIR7TypeRefE", !9, i64 0}
!15 = !{!16, !9, i64 8}
!16 = !{!"_ZTSN7ImplRef4Data15Data_BoundedPtrE", !9, i64 0, !9, i64 8, !9, i64 16, !9, i64 24}
!17 = !{!16, !9, i64 16}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,SROAPass,SimplifyCFGPass,TailCallElimPass