; LLVM IR from facebook/redex :: libredex (SourceBlockConsistencyCheck)

; 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.std::__detail::_Node_iterator" = type { %"struct.std::__detail::_Node_iterator_base" }
%"struct.std::__detail::_Node_iterator_base" = type { ptr }
%"class.std::vector.54" = type { %"struct.std::_Vector_base.55" }
%"struct.std::_Vector_base.55" = type { %"struct.std::_Vector_base<cfg::Block *, std::allocator<cfg::Block *>>::_Vector_impl" }
%"struct.std::_Vector_base<cfg::Block *, std::allocator<cfg::Block *>>::_Vector_impl" = type { %"struct.std::_Vector_base<cfg::Block *, std::allocator<cfg::Block *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<cfg::Block *, std::allocator<cfg::Block *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%class.anon.59 = type { ptr }
%"class.source_blocks::SourceBlockDomInfo" = type { %"class.source_blocks::SourceBlockDomTree" }
%"class.source_blocks::SourceBlockDomTree" = type { %"class.std::map", %"class.std::set" }
%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<source_blocks::SourceBlockInfo, std::pair<const source_blocks::SourceBlockInfo, source_blocks::DomTreeNode>, std::_Select1st<std::pair<const source_blocks::SourceBlockInfo, source_blocks::DomTreeNode>>, std::less<source_blocks::SourceBlockInfo>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<source_blocks::SourceBlockInfo, std::pair<const source_blocks::SourceBlockInfo, source_blocks::DomTreeNode>, std::_Select1st<std::pair<const source_blocks::SourceBlockInfo, source_blocks::DomTreeNode>>, std::less<source_blocks::SourceBlockInfo>>::_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 }
%"class.std::set" = type { %"class.std::_Rb_tree.6" }
%"class.std::_Rb_tree.6" = type { %"struct.std::_Rb_tree<source_blocks::SourceBlockInfo, source_blocks::SourceBlockInfo, std::_Identity<source_blocks::SourceBlockInfo>, std::less<source_blocks::SourceBlockInfo>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<source_blocks::SourceBlockInfo, source_blocks::SourceBlockInfo, std::_Identity<source_blocks::SourceBlockInfo>, std::less<source_blocks::SourceBlockInfo>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"class.source_blocks::SourceBlockConsistencyCheck" = type <{ %"class.std::unordered_map", i8, [7 x i8] }>
%"class.std::unordered_map" = type { %"class.std::_Hashtable.29" }
%"class.std::_Hashtable.29" = 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 }
%"struct.std::pair" = type { ptr, %"struct.source_blocks::SBConsistencyContext" }
%"struct.source_blocks::SBConsistencyContext" = type { %"class.std::set", %"class.std::set", %"class.source_blocks::SourceBlockDomInfo" }

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) #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 uwtable
define dso_local void @_ZN13source_blocks27SourceBlockConsistencyCheck12rebuild_sbdiEP9DexMethodRKN3cfg16ControlFlowGraphE(ptr noundef nonnull align 8 dereferenceable(57) %0, ptr noundef %1, ptr noundef nonnull align 8 dereferenceable(160) %2) #1 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca %"struct.std::__detail::_Node_iterator", align 8
  %8 = alloca %"struct.std::__detail::_Node_iterator", align 8
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca %"class.std::vector.54", align 8
  %13 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %14 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %15 = alloca ptr, align 8
  %16 = alloca %class.anon.59, align 8
  %17 = alloca ptr, align 8
  %18 = alloca i32, align 4
  %19 = alloca %"class.source_blocks::SourceBlockDomInfo", align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  store ptr %2, ptr %6, align 8, !tbaa !5
  %20 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #6
  %21 = getelementptr inbounds %"class.source_blocks::SourceBlockConsistencyCheck", ptr %20, i32 0, i32 0
  %22 = call ptr @_ZNSt13unordered_mapIP9DexMethodN13source_blocks20SBConsistencyContextESt4hashIS1_ESt8equal_toIS1_ESaISt4pairIKS1_S3_EEE4findERS9_(ptr noundef nonnull align 8 dereferenceable(56) %21, ptr noundef nonnull align 8 dereferenceable(8) %5)
  %23 = getelementptr inbounds %"struct.std::__detail::_Node_iterator", ptr %7, i32 0, i32 0
  %24 = getelementptr inbounds %"struct.std::__detail::_Node_iterator_base", ptr %23, i32 0, i32 0
  store ptr %22, ptr %24, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #6
  %25 = getelementptr inbounds %"class.source_blocks::SourceBlockConsistencyCheck", ptr %20, i32 0, i32 0
  %26 = call ptr @_ZNSt13unordered_mapIP9DexMethodN13source_blocks20SBConsistencyContextESt4hashIS1_ESt8equal_toIS1_ESaISt4pairIKS1_S3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(56) %25) #6
  %27 = getelementptr inbounds %"struct.std::__detail::_Node_iterator", ptr %8, i32 0, i32 0
  %28 = getelementptr inbounds %"struct.std::__detail::_Node_iterator_base", ptr %27, i32 0, i32 0
  store ptr %26, ptr %28, align 8
  %29 = call noundef zeroext i1 @_ZNSt8__detaileqERKNS_19_Node_iterator_baseISt4pairIKP9DexMethodN13source_blocks20SBConsistencyContextEELb0EEESA_(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  br i1 %29, label %30, label %31

30:                                               ; preds = %3
  store i32 1, ptr %9, align 4
  br label %68

31:                                               ; preds = %3
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #6
  %32 = call noundef ptr @_ZNKSt8__detail14_Node_iteratorISt4pairIKP9DexMethodN13source_blocks20SBConsistencyContextEELb0ELb0EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #6
  %33 = getelementptr inbounds %"struct.std::pair", ptr %32, i32 0, i32 1
  store ptr %33, ptr %10, align 8, !tbaa !5
  %34 = load ptr, ptr %10, align 8, !tbaa !5
  %35 = getelementptr inbounds %"struct.source_blocks::SBConsistencyContext", ptr %34, i32 0, i32 0
  call void @_ZNSt3setIN13source_blocks15SourceBlockInfoESt4lessIS1_ESaIS1_EE5clearEv(ptr noundef nonnull align 8 dereferenceable(48) %35) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  call void @llvm.lifetime.start.p0(i64 24, ptr %12) #6
  %36 = load ptr, ptr %6, align 8, !tbaa !5
  call void @_ZNK3cfg16ControlFlowGraph6blocksEv(ptr dead_on_unwind writable sret(%"class.std::vector.54") align 8 %12, ptr noundef nonnull align 8 dereferenceable(160) %36)
  store ptr %12, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #6
  %37 = load ptr, ptr %11, align 8, !tbaa !5
  %38 = call ptr @_ZNSt6vectorIPN3cfg5BlockESaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %37) #6
  %39 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %13, i32 0, i32 0
  store ptr %38, ptr %39, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #6
  %40 = load ptr, ptr %11, align 8, !tbaa !5
  %41 = call ptr @_ZNSt6vectorIPN3cfg5BlockESaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %40) #6
  %42 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %14, i32 0, i32 0
  store ptr %41, ptr %42, align 8
  br label %43

43:                                               ; preds = %53, %31
  %44 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPPN3cfg5BlockESt6vectorIS3_SaIS3_EEEEbRKNS_17__normal_iteratorIT_T0_EESD_(ptr noundef nonnull align 8 dereferenceable(8) %13, ptr noundef nonnull align 8 dereferenceable(8) %14) #6
  br i1 %44, label %46, label %45

45:                                               ; preds = %43
  store i32 2, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  call void @_ZNSt6vectorIPN3cfg5BlockESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  br label %59

46:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #6
  %47 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPPN3cfg5BlockESt6vectorIS3_SaIS3_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #6
  %48 = load ptr, ptr %47, align 8, !tbaa !5
  store ptr %48, ptr %15, align 8, !tbaa !5
  %49 = load ptr, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  %50 = getelementptr inbounds %class.anon.59, ptr %16, i32 0, i32 0
  %51 = load ptr, ptr %10, align 8, !tbaa !5
  store ptr %51, ptr %50, align 8, !tbaa !5
  invoke void @"_ZN13source_blocks20foreach_source_blockIZNS_27SourceBlockConsistencyCheck12rebuild_sbdiEP9DexMethodRKN3cfg16ControlFlowGraphEE3$_0EEvPNS4_5BlockERKT_"(ptr noundef %49, ptr noundef nonnull align 8 dereferenceable(8) %16)
          to label %52 unwind label %55

52:                                               ; preds = %46
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #6
  br label %53

53:                                               ; preds = %52
  %54 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPPN3cfg5BlockESt6vectorIS3_SaIS3_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #6
  br label %43

55:                                               ; preds = %46
  %56 = landingpad { ptr, i32 }
          cleanup
  %57 = extractvalue { ptr, i32 } %56, 0
  store ptr %57, ptr %17, align 8
  %58 = extractvalue { ptr, i32 } %56, 1
  store i32 %58, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  call void @_ZNSt6vectorIPN3cfg5BlockESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %12) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #6
  br label %71

59:                                               ; preds = %45
  call void @llvm.lifetime.start.p0(i64 96, ptr %19) #6
  %60 = load ptr, ptr %6, align 8, !tbaa !5
  %61 = load ptr, ptr %10, align 8, !tbaa !5
  %62 = getelementptr inbounds %"struct.source_blocks::SBConsistencyContext", ptr %61, i32 0, i32 0
  %63 = call noundef i64 @_ZNKSt3setIN13source_blocks15SourceBlockInfoESt4lessIS1_ESaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %62) #6
  %64 = trunc i64 %63 to i32
  call void @_ZN13source_blocks18SourceBlockDomInfoC1ERKN3cfg16ControlFlowGraphEj(ptr noundef nonnull align 8 dereferenceable(96) %19, ptr noundef nonnull align 8 dereferenceable(160) %60, i32 noundef %64)
  %65 = load ptr, ptr %10, align 8, !tbaa !5
  %66 = getelementptr inbounds %"struct.source_blocks::SBConsistencyContext", ptr %65, i32 0, i32 2
  %67 = call noundef nonnull align 8 dereferenceable(96) ptr @_ZN13source_blocks18SourceBlockDomInfoaSEOS0_(ptr noundef nonnull align 8 dereferenceable(96) %66, ptr noundef nonnull align 8 dereferenceable(96) %19) #6
  call void @_ZN13source_blocks18SourceBlockDomInfoD2Ev(ptr noundef nonnull align 8 dereferenceable(96) %19) #6
  call void @llvm.lifetime.end.p0(i64 96, ptr %19) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  store i32 0, ptr %9, align 4
  br label %68

68:                                               ; preds = %59, %30
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #6
  %69 = load i32, ptr %9, align 4
  switch i32 %69, label %76 [
    i32 0, label %70
    i32 1, label %70
  ]

70:                                               ; preds = %68, %68
  ret void

71:                                               ; preds = %55
  %72 = load ptr, ptr %17, align 8
  %73 = load i32, ptr %18, align 4
  %74 = insertvalue { ptr, i32 } poison, ptr %72, 0
  %75 = insertvalue { ptr, i32 } %74, i32 %73, 1
  resume { ptr, i32 } %75

76:                                               ; preds = %68
  unreachable
}

; Function Attrs: mustprogress uwtable
declare dso_local ptr @_ZNSt13unordered_mapIP9DexMethodN13source_blocks20SBConsistencyContextESt4hashIS1_ESt8equal_toIS1_ESaISt4pairIKS1_S3_EEE4findERS9_(ptr noundef nonnull align 8 dereferenceable(56), ptr noundef nonnull align 8 dereferenceable(8)) #1 align 2

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

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

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

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

declare void @_ZNK3cfg16ControlFlowGraph6blocksEv(ptr dead_on_unwind writable sret(%"class.std::vector.54") align 8, ptr noundef nonnull align 8 dereferenceable(160)) #3

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPPN3cfg5BlockESt6vectorIS3_SaIS3_EEEEbRKNS_17__normal_iteratorIT_T0_EESD_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #4

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

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZN13source_blocks20foreach_source_blockIZNS_27SourceBlockConsistencyCheck12rebuild_sbdiEP9DexMethodRKN3cfg16ControlFlowGraphEE3$_0EEvPNS4_5BlockERKT_"(ptr noundef, ptr noundef nonnull align 8 dereferenceable(8)) #5

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(96) ptr @_ZN13source_blocks18SourceBlockDomInfoaSEOS0_(ptr noundef nonnull align 8 dereferenceable(96), ptr noundef nonnull align 8 dereferenceable(96)) #4 align 2

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

declare void @_ZN13source_blocks18SourceBlockDomInfoC1ERKN3cfg16ControlFlowGraphEj(ptr, ptr, i32)

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


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

%"struct.std::__detail::_Node_iterator" = type { %"struct.std::__detail::_Node_iterator_base" }
%"struct.std::__detail::_Node_iterator_base" = type { ptr }
%"class.std::vector.54" = type { %"struct.std::_Vector_base.55" }
%"struct.std::_Vector_base.55" = type { %"struct.std::_Vector_base<cfg::Block *, std::allocator<cfg::Block *>>::_Vector_impl" }
%"struct.std::_Vector_base<cfg::Block *, std::allocator<cfg::Block *>>::_Vector_impl" = type { %"struct.std::_Vector_base<cfg::Block *, std::allocator<cfg::Block *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<cfg::Block *, std::allocator<cfg::Block *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.__gnu_cxx::__normal_iterator" = type { ptr }
%class.anon.59 = type { ptr }
%"class.source_blocks::SourceBlockDomInfo" = type { %"class.source_blocks::SourceBlockDomTree" }
%"class.source_blocks::SourceBlockDomTree" = type { %"class.std::map", %"class.std::set" }
%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<source_blocks::SourceBlockInfo, std::pair<const source_blocks::SourceBlockInfo, source_blocks::DomTreeNode>, std::_Select1st<std::pair<const source_blocks::SourceBlockInfo, source_blocks::DomTreeNode>>, std::less<source_blocks::SourceBlockInfo>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<source_blocks::SourceBlockInfo, std::pair<const source_blocks::SourceBlockInfo, source_blocks::DomTreeNode>, std::_Select1st<std::pair<const source_blocks::SourceBlockInfo, source_blocks::DomTreeNode>>, std::less<source_blocks::SourceBlockInfo>>::_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 }
%"class.std::set" = type { %"class.std::_Rb_tree.6" }
%"class.std::_Rb_tree.6" = type { %"struct.std::_Rb_tree<source_blocks::SourceBlockInfo, source_blocks::SourceBlockInfo, std::_Identity<source_blocks::SourceBlockInfo>, std::less<source_blocks::SourceBlockInfo>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<source_blocks::SourceBlockInfo, source_blocks::SourceBlockInfo, std::_Identity<source_blocks::SourceBlockInfo>, std::less<source_blocks::SourceBlockInfo>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }

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) #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 uwtable
define dso_local void @_ZN13source_blocks27SourceBlockConsistencyCheck12rebuild_sbdiEP9DexMethodRKN3cfg16ControlFlowGraphE(ptr noundef nonnull align 8 dereferenceable(57) %0, ptr noundef %1, ptr noundef nonnull align 8 dereferenceable(160) %2) local_unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca %"struct.std::__detail::_Node_iterator", align 8
  %6 = alloca %"struct.std::__detail::_Node_iterator", align 8
  %7 = alloca %"class.std::vector.54", align 8
  %8 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %9 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %10 = alloca %class.anon.59, align 8
  %11 = alloca %"class.source_blocks::SourceBlockDomInfo", align 8
  store ptr %1, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #6
  %12 = call ptr @_ZNSt13unordered_mapIP9DexMethodN13source_blocks20SBConsistencyContextESt4hashIS1_ESt8equal_toIS1_ESaISt4pairIKS1_S3_EEE4findERS9_(ptr noundef nonnull align 8 dereferenceable(56) %0, ptr noundef nonnull align 8 dereferenceable(8) %4)
  store ptr %12, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #6
  %13 = call ptr @_ZNSt13unordered_mapIP9DexMethodN13source_blocks20SBConsistencyContextESt4hashIS1_ESt8equal_toIS1_ESaISt4pairIKS1_S3_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(56) %0) #6
  store ptr %13, ptr %6, align 8
  %14 = call noundef zeroext i1 @_ZNSt8__detaileqERKNS_19_Node_iterator_baseISt4pairIKP9DexMethodN13source_blocks20SBConsistencyContextEELb0EEESA_(ptr noundef nonnull align 8 dereferenceable(8) %5, ptr noundef nonnull align 8 dereferenceable(8) %6) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #6
  br i1 %14, label %32, label %15

15:                                               ; preds = %3
  %16 = call noundef ptr @_ZNKSt8__detail14_Node_iteratorISt4pairIKP9DexMethodN13source_blocks20SBConsistencyContextEELb0ELb0EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %5) #6
  %17 = getelementptr inbounds i8, ptr %16, i64 8
  call void @_ZNSt3setIN13source_blocks15SourceBlockInfoESt4lessIS1_ESaIS1_EE5clearEv(ptr noundef nonnull align 8 dereferenceable(48) %17) #6
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #6
  call void @_ZNK3cfg16ControlFlowGraph6blocksEv(ptr dead_on_unwind nonnull writable sret(%"class.std::vector.54") align 8 %7, ptr noundef nonnull align 8 dereferenceable(160) %2)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #6
  %18 = call ptr @_ZNSt6vectorIPN3cfg5BlockESaIS2_EE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #6
  store ptr %18, ptr %8, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #6
  %19 = call ptr @_ZNSt6vectorIPN3cfg5BlockESaIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #6
  store ptr %19, ptr %9, align 8
  %20 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPPN3cfg5BlockESt6vectorIS3_SaIS3_EEEEbRKNS_17__normal_iteratorIT_T0_EESD_(ptr noundef nonnull align 8 dereferenceable(8) %8, ptr noundef nonnull align 8 dereferenceable(8) %9) #6
  br i1 %20, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %27, %15
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #6
  call void @_ZNSt6vectorIPN3cfg5BlockESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #6
  call void @llvm.lifetime.start.p0(i64 96, ptr nonnull %11) #6
  %21 = call noundef i64 @_ZNKSt3setIN13source_blocks15SourceBlockInfoESt4lessIS1_ESaIS1_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(48) %17) #6
  %22 = trunc i64 %21 to i32
  call void @_ZN13source_blocks18SourceBlockDomInfoC1ERKN3cfg16ControlFlowGraphEj(ptr noundef nonnull align 8 dereferenceable(96) %11, ptr noundef nonnull align 8 dereferenceable(160) %2, i32 noundef %22)
  %23 = getelementptr inbounds i8, ptr %16, i64 104
  %24 = call noundef nonnull align 8 dereferenceable(96) ptr @_ZN13source_blocks18SourceBlockDomInfoaSEOS0_(ptr noundef nonnull align 8 dereferenceable(96) %23, ptr noundef nonnull align 8 dereferenceable(96) %11) #6
  call void @_ZN13source_blocks18SourceBlockDomInfoD2Ev(ptr noundef nonnull align 8 dereferenceable(96) %11) #6
  call void @llvm.lifetime.end.p0(i64 96, ptr nonnull %11) #6
  br label %32

.lr.ph:                                           ; preds = %15, %27
  %25 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK9__gnu_cxx17__normal_iteratorIPPN3cfg5BlockESt6vectorIS3_SaIS3_EEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %8) #6
  %26 = load ptr, ptr %25, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #6
  store ptr %17, ptr %10, align 8, !tbaa !5
  invoke void @"_ZN13source_blocks20foreach_source_blockIZNS_27SourceBlockConsistencyCheck12rebuild_sbdiEP9DexMethodRKN3cfg16ControlFlowGraphEE3$_0EEvPNS4_5BlockERKT_"(ptr noundef %26, ptr noundef nonnull align 8 dereferenceable(8) %10)
          to label %27 unwind label %30

27:                                               ; preds = %.lr.ph
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #6
  %28 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN9__gnu_cxx17__normal_iteratorIPPN3cfg5BlockESt6vectorIS3_SaIS3_EEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %8) #6
  %29 = call noundef zeroext i1 @_ZN9__gnu_cxxneIPPN3cfg5BlockESt6vectorIS3_SaIS3_EEEEbRKNS_17__normal_iteratorIT_T0_EESD_(ptr noundef nonnull align 8 dereferenceable(8) %8, ptr noundef nonnull align 8 dereferenceable(8) %9) #6
  br i1 %29, label %.lr.ph, label %._crit_edge

30:                                               ; preds = %.lr.ph
  %31 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #6
  call void @_ZNSt6vectorIPN3cfg5BlockESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #6
  resume { ptr, i32 } %31

32:                                               ; preds = %3, %._crit_edge
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #6
  ret void
}

; Function Attrs: mustprogress uwtable
declare dso_local ptr @_ZNSt13unordered_mapIP9DexMethodN13source_blocks20SBConsistencyContextESt4hashIS1_ESt8equal_toIS1_ESaISt4pairIKS1_S3_EEE4findERS9_(ptr noundef nonnull align 8 dereferenceable(56), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #1 align 2

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

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

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

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

declare void @_ZNK3cfg16ControlFlowGraph6blocksEv(ptr dead_on_unwind writable sret(%"class.std::vector.54") align 8, ptr noundef nonnull align 8 dereferenceable(160)) local_unnamed_addr #3

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN9__gnu_cxxneIPPN3cfg5BlockESt6vectorIS3_SaIS3_EEEEbRKNS_17__normal_iteratorIT_T0_EESD_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4

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

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZN13source_blocks20foreach_source_blockIZNS_27SourceBlockConsistencyCheck12rebuild_sbdiEP9DexMethodRKN3cfg16ControlFlowGraphEE3$_0EEvPNS4_5BlockERKT_"(ptr noundef, ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #5

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

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

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(96) ptr @_ZN13source_blocks18SourceBlockDomInfoaSEOS0_(ptr noundef nonnull align 8 dereferenceable(96), ptr noundef nonnull align 8 dereferenceable(96)) local_unnamed_addr #4 align 2

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

declare void @_ZN13source_blocks18SourceBlockDomInfoC1ERKN3cfg16ControlFlowGraphEj(ptr, ptr, i32) local_unnamed_addr

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


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass