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

; 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.boost::intrusive::list_iterator" = type { %"struct.boost::intrusive::iiterator_members" }
%"struct.boost::intrusive::iiterator_members" = type { ptr }
%"class.UnorderedSet<cfg::Edge *>::ConstUnorderedIterable" = type { ptr }
%"struct.std::__detail::_Node_const_iterator" = type { %"struct.std::__detail::_Node_iterator_base.407" }
%"struct.std::__detail::_Node_iterator_base.407" = type { ptr }
%"class.boost::optional" = type { %"class.boost::optional_detail::tc_optional_base" }
%"class.boost::optional_detail::tc_optional_base" = type { i8, i32 }
%"struct.boost::none_t" = type { i8 }
%struct.MethodItemEntry = type { %"class.boost::intrusive::list_member_hook", i32, %union.anon.16 }
%"class.boost::intrusive::list_member_hook" = type { %"class.boost::intrusive::generic_hook" }
%"class.boost::intrusive::generic_hook" = type { %"struct.boost::intrusive::list_node" }
%"struct.boost::intrusive::list_node" = type { ptr, ptr }
%union.anon.16 = type { ptr }
%"class.cfg::ControlFlowGraph" = type { %"class.std::map", %class.UnorderedSet, ptr, ptr, ptr, i32, i8, i8, i8, %"class.std::vector" }
%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<unsigned long, std::pair<const unsigned long, cfg::Block *>, std::_Select1st<std::pair<const unsigned long, cfg::Block *>>, std::less<unsigned long>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<unsigned long, std::pair<const unsigned long, cfg::Block *>, std::_Select1st<std::pair<const unsigned long, cfg::Block *>>, std::less<unsigned long>>::_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.UnorderedSet = type { %"class.std::unordered_set" }
%"class.std::unordered_set" = 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 }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<IRInstruction *, std::allocator<IRInstruction *>>::_Vector_impl" }
%"struct.std::_Vector_base<IRInstruction *, std::allocator<IRInstruction *>>::_Vector_impl" = type { %"struct.std::_Vector_base<IRInstruction *, std::allocator<IRInstruction *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<IRInstruction *, std::allocator<IRInstruction *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.cfg::Block" = type { i64, %class.IRList, %"class.boost::intrusive::list_iterator", %"class.boost::intrusive::list_iterator", %"class.std::vector.11", %"class.std::vector.11", ptr }
%class.IRList = type { %"class.boost::intrusive::list" }
%"class.boost::intrusive::list" = type { %"class.boost::intrusive::list_impl" }
%"class.boost::intrusive::list_impl" = type { %"struct.boost::intrusive::list_impl<boost::intrusive::mhtraits<MethodItemEntry, boost::intrusive::list_member_hook<>, &MethodItemEntry::list_hook_>, unsigned long, true, void>::data_t" }
%"struct.boost::intrusive::list_impl<boost::intrusive::mhtraits<MethodItemEntry, boost::intrusive::list_member_hook<>, &MethodItemEntry::list_hook_>, unsigned long, true, void>::data_t" = type { %"struct.boost::intrusive::list_impl<boost::intrusive::mhtraits<MethodItemEntry, boost::intrusive::list_member_hook<>, &MethodItemEntry::list_hook_>, unsigned long, true, void>::root_plus_size" }
%"struct.boost::intrusive::list_impl<boost::intrusive::mhtraits<MethodItemEntry, boost::intrusive::list_member_hook<>, &MethodItemEntry::list_hook_>, unsigned long, true, void>::root_plus_size" = type { %"struct.boost::intrusive::detail::size_holder", %"struct.boost::intrusive::detail::default_header_holder" }
%"struct.boost::intrusive::detail::size_holder" = type { i64 }
%"struct.boost::intrusive::detail::default_header_holder" = type { %"struct.boost::intrusive::list_node" }
%"class.std::vector.11" = type { %"struct.std::_Vector_base.12" }
%"struct.std::_Vector_base.12" = type { %"struct.std::_Vector_base<cfg::Edge *, std::allocator<cfg::Edge *>>::_Vector_impl" }
%"struct.std::_Vector_base<cfg::Edge *, std::allocator<cfg::Edge *>>::_Vector_impl" = type { %"struct.std::_Vector_base<cfg::Edge *, std::allocator<cfg::Edge *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<cfg::Edge *, std::allocator<cfg::Edge *>>::_Vector_impl_data" = type { ptr, ptr, 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 uwtable
declare dso_local void @_ZN3cfg5Block3endEv(ptr dead_on_unwind noalias writable sret(%"class.boost::intrusive::list_iterator") align 8, ptr noundef nonnull align 8 dereferenceable(104)) #1 align 2

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN6IRList17erase_and_disposeERKN5boost9intrusive13list_iteratorINS1_8mhtraitsI15MethodItemEntryNS1_16list_member_hookIJEEEXadL_ZNS4_10list_hook_EEEEELb0EEE(ptr dead_on_unwind noalias writable sret(%"class.boost::intrusive::list_iterator") align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(8)) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i16 @_ZNK13IRInstruction6opcodeEv(ptr noundef nonnull align 8 dereferenceable(32)) #3 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN6opcode9is_switchE8IROpcode(i16 noundef zeroext) #4

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN6opcode23is_a_conditional_branchE8IROpcode(i16 noundef zeroext) #4

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN3cfg5Block13get_last_insnEv(ptr dead_on_unwind noalias writable sret(%"class.boost::intrusive::list_iterator") align 8, ptr noundef nonnull align 8 dereferenceable(104)) #1 align 2

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3cfg16ControlFlowGraph21cleanup_deleted_edgesERK12UnorderedSetIPNS_4EdgeESt4hashIS3_ESt8equal_toIS3_EE(ptr noundef nonnull align 8 dereferenceable(160) %0, ptr noundef nonnull align 8 dereferenceable(56) %1) #1 align 2 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca %"class.UnorderedSet<cfg::Edge *>::ConstUnorderedIterable", align 8
  %7 = alloca %"struct.std::__detail::_Node_const_iterator", align 8
  %8 = alloca %"struct.std::__detail::_Node_const_iterator", align 8
  %9 = alloca i32, align 4
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca %"class.boost::intrusive::list_iterator", align 8
  %13 = alloca %"class.boost::intrusive::list_iterator", align 8
  %14 = alloca ptr, align 8
  %15 = alloca i16, align 2
  %16 = alloca ptr, align 8
  %17 = alloca %"class.boost::intrusive::list_iterator", align 8
  %18 = alloca %"class.boost::optional", align 4
  %19 = alloca %"struct.boost::none_t", align 1
  store ptr %0, ptr %3, align 8, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !5
  %20 = load ptr, ptr %3, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  %21 = load ptr, ptr %4, align 8, !tbaa !5
  %22 = call ptr @_Z17UnorderedIterableI12UnorderedSetIPN3cfg4EdgeESt4hashIS3_ESt8equal_toIS3_EETnNSt9enable_ifIXsr3stdE12is_base_of_vI13UnorderedBaseIT_ESB_EEbE4typeELb1EEDaRKSB_(ptr noundef nonnull align 8 dereferenceable(56) %21)
  %23 = getelementptr inbounds %"class.UnorderedSet<cfg::Edge *>::ConstUnorderedIterable", ptr %6, i32 0, i32 0
  store ptr %22, ptr %23, align 8
  store ptr %6, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  %24 = load ptr, ptr %5, align 8, !tbaa !5
  %25 = call ptr @_ZNK12UnorderedSetIPN3cfg4EdgeESt4hashIS2_ESt8equal_toIS2_EE22ConstUnorderedIterable5beginEv(ptr noundef nonnull align 8 dereferenceable(8) %24)
  %26 = getelementptr inbounds %"struct.std::__detail::_Node_const_iterator", ptr %7, i32 0, i32 0
  %27 = getelementptr inbounds %"struct.std::__detail::_Node_iterator_base.407", ptr %26, i32 0, i32 0
  store ptr %25, ptr %27, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #5
  %28 = load ptr, ptr %5, align 8, !tbaa !5
  %29 = call ptr @_ZNK12UnorderedSetIPN3cfg4EdgeESt4hashIS2_ESt8equal_toIS2_EE22ConstUnorderedIterable3endEv(ptr noundef nonnull align 8 dereferenceable(8) %28)
  %30 = getelementptr inbounds %"struct.std::__detail::_Node_const_iterator", ptr %8, i32 0, i32 0
  %31 = getelementptr inbounds %"struct.std::__detail::_Node_iterator_base.407", ptr %30, i32 0, i32 0
  store ptr %29, ptr %31, align 8
  br label %32

32:                                               ; preds = %77, %2
  %33 = call noundef zeroext i1 @_ZNSt8__detailneERKNS_19_Node_iterator_baseIPN3cfg4EdgeELb0EEES6_(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8) #5
  br i1 %33, label %35, label %34

34:                                               ; preds = %32
  store i32 2, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #5
  br label %79

35:                                               ; preds = %32
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  %36 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt8__detail20_Node_const_iteratorIPN3cfg4EdgeELb1ELb0EEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #5
  %37 = load ptr, ptr %36, align 8, !tbaa !5
  store ptr %37, ptr %10, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  %38 = load ptr, ptr %10, align 8, !tbaa !5
  %39 = call noundef ptr @_ZNK3cfg4Edge3srcEv(ptr noundef nonnull align 8 dereferenceable(32) %38)
  store ptr %39, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  %40 = load ptr, ptr %11, align 8, !tbaa !5
  call void @_ZN3cfg5Block13get_last_insnEv(ptr dead_on_unwind writable sret(%"class.boost::intrusive::list_iterator") align 8 %12, ptr noundef nonnull align 8 dereferenceable(104) %40)
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #5
  %41 = load ptr, ptr %11, align 8, !tbaa !5
  call void @_ZN3cfg5Block3endEv(ptr dead_on_unwind writable sret(%"class.boost::intrusive::list_iterator") align 8 %13, ptr noundef nonnull align 8 dereferenceable(104) %41)
  %42 = call noundef zeroext i1 @_ZN5boost9intrusiveneERKNS0_13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb0EEES9_(ptr noundef nonnull align 8 dereferenceable(8) %12, ptr noundef nonnull align 8 dereferenceable(8) %13)
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #5
  br i1 %42, label %43, label %70

43:                                               ; preds = %35
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #5
  %44 = call noundef ptr @_ZNK5boost9intrusive13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb0EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %12)
  %45 = getelementptr inbounds %struct.MethodItemEntry, ptr %44, i32 0, i32 2
  %46 = load ptr, ptr %45, align 8, !tbaa !9
  store ptr %46, ptr %14, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 2, ptr %15) #5
  %47 = load ptr, ptr %14, align 8, !tbaa !5
  %48 = call noundef zeroext i16 @_ZNK13IRInstruction6opcodeEv(ptr noundef nonnull align 8 dereferenceable(32) %47)
  store i16 %48, ptr %15, align 2, !tbaa !10
  %49 = load i16, ptr %15, align 2, !tbaa !10
  %50 = call noundef zeroext i1 @_ZN6opcode23is_a_conditional_branchE8IROpcode(i16 noundef zeroext %49)
  br i1 %50, label %55, label %51

51:                                               ; preds = %43
  %52 = load i16, ptr %15, align 2, !tbaa !10
  %53 = call noundef zeroext i1 @_ZN6opcode9is_switchE8IROpcode(i16 noundef zeroext %52)
  br i1 %53, label %55, label %54

54:                                               ; preds = %51
  store i32 3, ptr %9, align 4
  br label %67

55:                                               ; preds = %51, %43
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #5
  %56 = load ptr, ptr %11, align 8, !tbaa !5
  %57 = call noundef ptr @_ZN3cfg12_GLOBAL__N_133get_singleton_normal_forward_edgeEPNS_5BlockE(ptr noundef %56)
  store ptr %57, ptr %16, align 8, !tbaa !5
  %58 = load ptr, ptr %16, align 8, !tbaa !5
  %59 = icmp ne ptr %58, null
  br i1 %59, label %60, label %66

60:                                               ; preds = %55
  %61 = getelementptr inbounds %"class.cfg::ControlFlowGraph", ptr %20, i32 0, i32 9
  call void @_ZNSt6vectorIP13IRInstructionSaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %61, ptr noundef nonnull align 8 dereferenceable(8) %14)
  %62 = load ptr, ptr %11, align 8, !tbaa !5
  %63 = getelementptr inbounds %"class.cfg::Block", ptr %62, i32 0, i32 1
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #5
  call void @_ZN6IRList17erase_and_disposeERKN5boost9intrusive13list_iteratorINS1_8mhtraitsI15MethodItemEntryNS1_16list_member_hookIJEEEXadL_ZNS4_10list_hook_EEEEELb0EEE(ptr dead_on_unwind writable sret(%"class.boost::intrusive::list_iterator") align 8 %17, ptr noundef nonnull align 8 dereferenceable(24) %63, ptr noundef nonnull align 8 dereferenceable(8) %12)
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  %64 = load ptr, ptr %16, align 8, !tbaa !5
  call void @_ZN3cfg4Edge8set_typeENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(32) %64, i8 noundef zeroext 0)
  %65 = load ptr, ptr %16, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #5
  call void @_ZN5boost8optionalIiEC2ENS_6none_tE(ptr noundef nonnull align 4 dereferenceable(8) %18) #5
  call void @_ZN3cfg4Edge12set_case_keyERKN5boost8optionalIiEE(ptr noundef nonnull align 8 dereferenceable(32) %65, ptr noundef nonnull align 4 dereferenceable(8) %18)
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  br label %66

66:                                               ; preds = %60, %55
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #5
  store i32 0, ptr %9, align 4
  br label %67

67:                                               ; preds = %66, %54
  call void @llvm.lifetime.end.p0(i64 2, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  %68 = load i32, ptr %9, align 4
  switch i32 %68, label %71 [
    i32 0, label %69
  ]

69:                                               ; preds = %67
  br label %70

70:                                               ; preds = %69, %35
  store i32 0, ptr %9, align 4
  br label %71

71:                                               ; preds = %70, %67
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  %72 = load i32, ptr %9, align 4
  switch i32 %72, label %74 [
    i32 0, label %73
  ]

73:                                               ; preds = %71
  store i32 0, ptr %9, align 4
  br label %74

74:                                               ; preds = %73, %71
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  %75 = load i32, ptr %9, align 4
  switch i32 %75, label %80 [
    i32 0, label %76
    i32 3, label %77
  ]

76:                                               ; preds = %74
  br label %77

77:                                               ; preds = %76, %74
  %78 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8__detail20_Node_const_iteratorIPN3cfg4EdgeELb1ELb0EEppEv(ptr noundef nonnull align 8 dereferenceable(8) %7) #5
  br label %32

79:                                               ; preds = %34
  ret void

80:                                               ; preds = %74
  unreachable
}

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef ptr @_ZN3cfg12_GLOBAL__N_133get_singleton_normal_forward_edgeEPNS_5BlockE(ptr noundef) #3

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN3cfg4Edge8set_typeENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(32), i8 noundef zeroext) #1 align 2

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

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { 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 #3 = { 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 #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 = { 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 = !{!7, !7, i64 0}
!10 = !{!11, !11, i64 0}
!11 = !{!"_ZTS8IROpcode", !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.boost::intrusive::list_iterator" = type { %"struct.boost::intrusive::iiterator_members" }
%"struct.boost::intrusive::iiterator_members" = type { ptr }
%"class.UnorderedSet<cfg::Edge *>::ConstUnorderedIterable" = type { ptr }
%"struct.std::__detail::_Node_const_iterator" = type { %"struct.std::__detail::_Node_iterator_base.407" }
%"struct.std::__detail::_Node_iterator_base.407" = type { ptr }
%"class.boost::optional" = type { %"class.boost::optional_detail::tc_optional_base" }
%"class.boost::optional_detail::tc_optional_base" = type { i8, i32 }

; 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
declare dso_local void @_ZN3cfg5Block3endEv(ptr dead_on_unwind noalias writable sret(%"class.boost::intrusive::list_iterator") align 8, ptr noundef nonnull align 8 dereferenceable(104)) local_unnamed_addr #1 align 2

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN6IRList17erase_and_disposeERKN5boost9intrusive13list_iteratorINS1_8mhtraitsI15MethodItemEntryNS1_16list_member_hookIJEEEXadL_ZNS4_10list_hook_EEEEELb0EEE(ptr dead_on_unwind noalias writable sret(%"class.boost::intrusive::list_iterator") align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i16 @_ZNK13IRInstruction6opcodeEv(ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN6opcode9is_switchE8IROpcode(i16 noundef zeroext) local_unnamed_addr #4

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZN6opcode23is_a_conditional_branchE8IROpcode(i16 noundef zeroext) local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN3cfg5Block13get_last_insnEv(ptr dead_on_unwind noalias writable sret(%"class.boost::intrusive::list_iterator") align 8, ptr noundef nonnull align 8 dereferenceable(104)) local_unnamed_addr #1 align 2

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3cfg16ControlFlowGraph21cleanup_deleted_edgesERK12UnorderedSetIPNS_4EdgeESt4hashIS3_ESt8equal_toIS3_EE(ptr noundef nonnull align 8 dereferenceable(160) %0, ptr noundef nonnull align 8 dereferenceable(56) %1) local_unnamed_addr #1 align 2 {
  %3 = alloca %"class.UnorderedSet<cfg::Edge *>::ConstUnorderedIterable", align 8
  %4 = alloca %"struct.std::__detail::_Node_const_iterator", align 8
  %5 = alloca %"struct.std::__detail::_Node_const_iterator", align 8
  %6 = alloca %"class.boost::intrusive::list_iterator", align 8
  %7 = alloca %"class.boost::intrusive::list_iterator", align 8
  %8 = alloca ptr, align 8
  %9 = alloca %"class.boost::intrusive::list_iterator", align 8
  %10 = alloca %"class.boost::optional", align 4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #5
  %11 = tail call ptr @_Z17UnorderedIterableI12UnorderedSetIPN3cfg4EdgeESt4hashIS3_ESt8equal_toIS3_EETnNSt9enable_ifIXsr3stdE12is_base_of_vI13UnorderedBaseIT_ESB_EEbE4typeELb1EEDaRKSB_(ptr noundef nonnull align 8 dereferenceable(56) %1)
  store ptr %11, ptr %3, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #5
  %12 = call ptr @_ZNK12UnorderedSetIPN3cfg4EdgeESt4hashIS2_ESt8equal_toIS2_EE22ConstUnorderedIterable5beginEv(ptr noundef nonnull align 8 dereferenceable(8) %3)
  store ptr %12, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #5
  %13 = call ptr @_ZNK12UnorderedSetIPN3cfg4EdgeESt4hashIS2_ESt8equal_toIS2_EE22ConstUnorderedIterable3endEv(ptr noundef nonnull align 8 dereferenceable(8) %3)
  store ptr %13, ptr %5, align 8
  %14 = call noundef zeroext i1 @_ZNSt8__detailneERKNS_19_Node_iterator_baseIPN3cfg4EdgeELb0EEES6_(ptr noundef nonnull align 8 dereferenceable(8) %4, ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  br i1 %14, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %2
  %15 = getelementptr inbounds i8, ptr %0, i64 136
  br label %16

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

16:                                               ; preds = %.lr.ph, %34
  %17 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt8__detail20_Node_const_iteratorIPN3cfg4EdgeELb1ELb0EEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %4) #5
  %18 = load ptr, ptr %17, align 8, !tbaa !5
  %19 = call noundef ptr @_ZNK3cfg4Edge3srcEv(ptr noundef nonnull align 8 dereferenceable(32) %18)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #5
  call void @_ZN3cfg5Block13get_last_insnEv(ptr dead_on_unwind nonnull writable sret(%"class.boost::intrusive::list_iterator") align 8 %6, ptr noundef nonnull align 8 dereferenceable(104) %19)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #5
  call void @_ZN3cfg5Block3endEv(ptr dead_on_unwind nonnull writable sret(%"class.boost::intrusive::list_iterator") align 8 %7, ptr noundef nonnull align 8 dereferenceable(104) %19)
  %20 = call noundef zeroext i1 @_ZN5boost9intrusiveneERKNS0_13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb0EEES9_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %7)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #5
  br i1 %20, label %21, label %34

21:                                               ; preds = %16
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #5
  %22 = call noundef ptr @_ZNK5boost9intrusive13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb0EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %6)
  %23 = getelementptr inbounds i8, ptr %22, i64 24
  %24 = load ptr, ptr %23, align 8, !tbaa !9
  store ptr %24, ptr %8, align 8, !tbaa !5
  %25 = call noundef zeroext i16 @_ZNK13IRInstruction6opcodeEv(ptr noundef nonnull align 8 dereferenceable(32) %24)
  %26 = call noundef zeroext i1 @_ZN6opcode23is_a_conditional_branchE8IROpcode(i16 noundef zeroext %25)
  br i1 %26, label %29, label %27

27:                                               ; preds = %21
  %28 = call noundef zeroext i1 @_ZN6opcode9is_switchE8IROpcode(i16 noundef zeroext %25)
  br i1 %28, label %29, label %.critedge

29:                                               ; preds = %27, %21
  %30 = call noundef ptr @_ZN3cfg12_GLOBAL__N_133get_singleton_normal_forward_edgeEPNS_5BlockE(ptr noundef nonnull %19)
  %.not = icmp eq ptr %30, null
  br i1 %.not, label %33, label %31

31:                                               ; preds = %29
  call void @_ZNSt6vectorIP13IRInstructionSaIS1_EE9push_backERKS1_(ptr noundef nonnull align 8 dereferenceable(24) %15, ptr noundef nonnull align 8 dereferenceable(8) %8)
  %32 = getelementptr inbounds i8, ptr %19, i64 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #5
  call void @_ZN6IRList17erase_and_disposeERKN5boost9intrusive13list_iteratorINS1_8mhtraitsI15MethodItemEntryNS1_16list_member_hookIJEEEXadL_ZNS4_10list_hook_EEEEELb0EEE(ptr dead_on_unwind nonnull writable sret(%"class.boost::intrusive::list_iterator") align 8 %9, ptr noundef nonnull align 8 dereferenceable(24) %32, ptr noundef nonnull align 8 dereferenceable(8) %6)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #5
  call void @_ZN3cfg4Edge8set_typeENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(32) %30, i8 noundef zeroext 0)
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #5
  call void @_ZN5boost8optionalIiEC2ENS_6none_tE(ptr noundef nonnull align 4 dereferenceable(8) %10) #5
  call void @_ZN3cfg4Edge12set_case_keyERKN5boost8optionalIiEE(ptr noundef nonnull align 8 dereferenceable(32) %30, ptr noundef nonnull align 4 dereferenceable(8) %10)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #5
  br label %33

33:                                               ; preds = %29, %31
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #5
  br label %34

.critedge:                                        ; preds = %27
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #5
  br label %34

34:                                               ; preds = %16, %33, %.critedge
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #5
  %35 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8__detail20_Node_const_iteratorIPN3cfg4EdgeELb1ELb0EEppEv(ptr noundef nonnull align 8 dereferenceable(8) %4) #5
  %36 = call noundef zeroext i1 @_ZNSt8__detailneERKNS_19_Node_iterator_baseIPN3cfg4EdgeELb0EEES6_(ptr noundef nonnull align 8 dereferenceable(8) %4, ptr noundef nonnull align 8 dereferenceable(8) %5) #5
  br i1 %36, label %16, label %._crit_edge
}

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef ptr @_ZN3cfg12_GLOBAL__N_133get_singleton_normal_forward_edgeEPNS_5BlockE(ptr noundef) local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN3cfg4Edge8set_typeENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(32), i8 noundef zeroext) local_unnamed_addr #1 align 2

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

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

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


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