; LLVM IR from opset/openset :: src (attributes)

; 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.robin_hood::detail::unordered_map<true, 80, openset::db::attr_key_s, openset::db::Attr_s *, robin_hood::hash<openset::db::attr_key_s>, std::equal_to<openset::db::attr_key_s>>::Iter.317" = type { ptr, ptr }
%"struct.openset::db::attr_key_s" = type <{ i32, i64 }>
%"class.openset::db::Attributes" = type <{ %"class.robin_hood::detail::unordered_map", %"class.robin_hood::detail::unordered_map.292", ptr, ptr, ptr, i32, [4 x i8] }>
%"class.robin_hood::detail::unordered_map" = type { ptr, ptr, i64, i64, i64, i32, i32 }
%"class.robin_hood::detail::unordered_map.292" = type { ptr, ptr, i64, i64, i64, i32, i32 }
%"struct.robin_hood::pair" = type { %"struct.openset::db::attr_key_s", ptr }

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN7openset2db10attr_key_sC2Eil(ptr noundef nonnull align 1 dereferenceable(12), i32 noundef, i64 noundef) unnamed_addr #1 align 2

declare noundef i64 @_Z8MakeHashRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(32)) #2

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, ptr } @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE4findERKS4_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 1 dereferenceable(12)) #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE4IterILb1EEneILb1EEEbRKNSC_IXT_EEE(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(16)) #1 align 2

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, ptr } @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE3endEv(ptr noundef nonnull align 8 dereferenceable(48)) #3 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local noundef ptr @_ZNK7openset2db10Attributes3getEiRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(124) %0, i32 noundef %1, ptr noundef nonnull align 8 dereferenceable(32) %2) #3 align 2 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca ptr, align 8
  %8 = alloca %"class.robin_hood::detail::unordered_map<true, 80, openset::db::attr_key_s, openset::db::Attr_s *, robin_hood::hash<openset::db::attr_key_s>, std::equal_to<openset::db::attr_key_s>>::Iter.317", align 8
  %9 = alloca %"struct.openset::db::attr_key_s", align 1
  %10 = alloca %"class.robin_hood::detail::unordered_map<true, 80, openset::db::attr_key_s, openset::db::Attr_s *, robin_hood::hash<openset::db::attr_key_s>, std::equal_to<openset::db::attr_key_s>>::Iter.317", align 8
  %11 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store i32 %1, ptr %6, align 4, !tbaa !9
  store ptr %2, ptr %7, align 8, !tbaa !5
  %12 = load ptr, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 16, ptr %8) #4
  %13 = getelementptr inbounds %"class.openset::db::Attributes", ptr %12, i32 0, i32 0
  call void @llvm.lifetime.start.p0(i64 12, ptr %9) #4
  %14 = load i32, ptr %6, align 4, !tbaa !9
  %15 = load ptr, ptr %7, align 8, !tbaa !5
  %16 = call noundef i64 @_Z8MakeHashRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(32) %15)
  call void @_ZN7openset2db10attr_key_sC2Eil(ptr noundef nonnull align 1 dereferenceable(12) %9, i32 noundef %14, i64 noundef %16)
  %17 = call { ptr, ptr } @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE4findERKS4_(ptr noundef nonnull align 8 dereferenceable(48) %13, ptr noundef nonnull align 1 dereferenceable(12) %9)
  %18 = getelementptr inbounds { ptr, ptr }, ptr %8, i32 0, i32 0
  %19 = extractvalue { ptr, ptr } %17, 0
  store ptr %19, ptr %18, align 8
  %20 = getelementptr inbounds { ptr, ptr }, ptr %8, i32 0, i32 1
  %21 = extractvalue { ptr, ptr } %17, 1
  store ptr %21, ptr %20, align 8
  call void @llvm.lifetime.end.p0(i64 12, ptr %9) #4
  call void @llvm.lifetime.start.p0(i64 16, ptr %10) #4
  %22 = getelementptr inbounds %"class.openset::db::Attributes", ptr %12, i32 0, i32 0
  %23 = call { ptr, ptr } @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %22)
  %24 = getelementptr inbounds { ptr, ptr }, ptr %10, i32 0, i32 0
  %25 = extractvalue { ptr, ptr } %23, 0
  store ptr %25, ptr %24, align 8
  %26 = getelementptr inbounds { ptr, ptr }, ptr %10, i32 0, i32 1
  %27 = extractvalue { ptr, ptr } %23, 1
  store ptr %27, ptr %26, align 8
  %28 = call noundef zeroext i1 @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE4IterILb1EEneILb1EEEbRKNSC_IXT_EEE(ptr noundef nonnull align 8 dereferenceable(16) %8, ptr noundef nonnull align 8 dereferenceable(16) %10) #4
  call void @llvm.lifetime.end.p0(i64 16, ptr %10) #4
  br i1 %28, label %29, label %33

29:                                               ; preds = %3
  %30 = call noundef ptr @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE4IterILb1EEptEv(ptr noundef nonnull align 8 dereferenceable(16) %8)
  %31 = getelementptr inbounds %"struct.robin_hood::pair", ptr %30, i32 0, i32 1
  %32 = load ptr, ptr %31, align 8, !tbaa !11
  store ptr %32, ptr %4, align 8
  store i32 1, ptr %11, align 4
  br label %34

33:                                               ; preds = %3
  store i32 0, ptr %11, align 4
  br label %34

34:                                               ; preds = %33, %29
  call void @llvm.lifetime.end.p0(i64 16, ptr %8) #4
  %35 = load i32, ptr %11, align 4
  switch i32 %35, label %39 [
    i32 0, label %36
    i32 1, label %37
  ]

36:                                               ; preds = %34
  store ptr null, ptr %4, align 8
  br label %37

37:                                               ; preds = %36, %34
  %38 = load ptr, ptr %4, align 8
  ret ptr %38

39:                                               ; preds = %34
  unreachable
}

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !6, i64 16}
!12 = !{!"_ZTSN10robin_hood4pairIN7openset2db10attr_key_sEPNS2_6Attr_sEEE", !13, i64 0, !6, i64 16}
!13 = !{!"_ZTSN7openset2db10attr_key_sE", !10, i64 0, !14, i64 4}
!14 = !{!"long", !7, i64 0}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.robin_hood::detail::unordered_map<true, 80, openset::db::attr_key_s, openset::db::Attr_s *, robin_hood::hash<openset::db::attr_key_s>, std::equal_to<openset::db::attr_key_s>>::Iter.317" = type { ptr, ptr }
%"struct.openset::db::attr_key_s" = type <{ i32, i64 }>

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN7openset2db10attr_key_sC2Eil(ptr noundef nonnull align 1 dereferenceable(12), i32 noundef, i64 noundef) unnamed_addr #1 align 2

declare noundef i64 @_Z8MakeHashRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, ptr } @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE4findERKS4_(ptr noundef nonnull align 8 dereferenceable(48), ptr noundef nonnull align 1 dereferenceable(12)) local_unnamed_addr #3 align 2

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

; Function Attrs: mustprogress uwtable
declare dso_local { ptr, ptr } @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE3endEv(ptr noundef nonnull align 8 dereferenceable(48)) local_unnamed_addr #3 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local noundef ptr @_ZNK7openset2db10Attributes3getEiRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(124) %0, i32 noundef %1, ptr noundef nonnull align 8 dereferenceable(32) %2) local_unnamed_addr #3 align 2 {
  %4 = alloca %"class.robin_hood::detail::unordered_map<true, 80, openset::db::attr_key_s, openset::db::Attr_s *, robin_hood::hash<openset::db::attr_key_s>, std::equal_to<openset::db::attr_key_s>>::Iter.317", align 8
  %5 = alloca %"struct.openset::db::attr_key_s", align 1
  %6 = alloca %"class.robin_hood::detail::unordered_map<true, 80, openset::db::attr_key_s, openset::db::Attr_s *, robin_hood::hash<openset::db::attr_key_s>, std::equal_to<openset::db::attr_key_s>>::Iter.317", align 8
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %4) #4
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %5) #4
  %7 = tail call noundef i64 @_Z8MakeHashRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(32) %2)
  call void @_ZN7openset2db10attr_key_sC2Eil(ptr noundef nonnull align 1 dereferenceable(12) %5, i32 noundef %1, i64 noundef %7)
  %8 = call { ptr, ptr } @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE4findERKS4_(ptr noundef nonnull align 8 dereferenceable(48) %0, ptr noundef nonnull align 1 dereferenceable(12) %5)
  %9 = extractvalue { ptr, ptr } %8, 0
  store ptr %9, ptr %4, align 8
  %10 = getelementptr inbounds i8, ptr %4, i64 8
  %11 = extractvalue { ptr, ptr } %8, 1
  store ptr %11, ptr %10, align 8
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) #4
  %12 = call { ptr, ptr } @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %0)
  %13 = extractvalue { ptr, ptr } %12, 0
  store ptr %13, ptr %6, align 8
  %14 = getelementptr inbounds i8, ptr %6, i64 8
  %15 = extractvalue { ptr, ptr } %12, 1
  store ptr %15, ptr %14, align 8
  %16 = call noundef zeroext i1 @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE4IterILb1EEneILb1EEEbRKNSC_IXT_EEE(ptr noundef nonnull align 8 dereferenceable(16) %4, ptr noundef nonnull align 8 dereferenceable(16) %6) #4
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #4
  br i1 %16, label %17, label %21

17:                                               ; preds = %3
  %18 = call noundef ptr @_ZNK10robin_hood6detail13unordered_mapILb1ELm80EN7openset2db10attr_key_sEPNS3_6Attr_sENS_4hashIS4_EESt8equal_toIS4_EE4IterILb1EEptEv(ptr noundef nonnull align 8 dereferenceable(16) %4)
  %19 = getelementptr inbounds i8, ptr %18, i64 16
  %20 = load ptr, ptr %19, align 8, !tbaa !5
  br label %21

21:                                               ; preds = %3, %17
  %spec.select = phi ptr [ %20, %17 ], [ null, %3 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %4) #4
  ret ptr %spec.select
}

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !12, i64 16}
!6 = !{!"_ZTSN10robin_hood4pairIN7openset2db10attr_key_sEPNS2_6Attr_sEEE", !7, i64 0, !12, i64 16}
!7 = !{!"_ZTSN7openset2db10attr_key_sE", !8, i64 0, !11, i64 4}
!8 = !{!"int", !9, i64 0}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C++ TBAA"}
!11 = !{!"long", !9, i64 0}
!12 = !{!"any pointer", !9, i64 0}


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