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

; 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.38" = type { %"struct.boost::intrusive::iiterator_members" }
%"struct.boost::intrusive::iiterator_members" = type { 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" }
%"struct.boost::intrusive::list_node" = type { ptr, ptr }
%"class.boost::intrusive::list_iterator" = type { %"struct.boost::intrusive::iiterator_members" }
%"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 }
%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" }
%union.anon.16 = type { ptr }

@.str.8 = external hidden unnamed_addr constant [73 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [14 x i8], align 1
@__PRETTY_FUNCTION__._ZNK3cfg5Block13branchingnessEv = external hidden unnamed_addr constant [56 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [55 x i8], align 1

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

; Function Attrs: noreturn
declare void @_Z11assert_failPKcS0_jS0_10RedexErrorS0_z(ptr noundef, ptr noundef, i32 noundef, ptr noundef, i32 noundef, ptr noundef, ...) #2

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i8 @_ZNK3cfg5Block13branchingnessEv(ptr noundef nonnull align 8 dereferenceable(104) %0) #1 align 2 {
  %2 = alloca i8, align 1
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca %"class.boost::intrusive::list_iterator.38", align 8
  %6 = alloca %"class.boost::intrusive::list_iterator.38", align 8
  %7 = alloca i16, align 2
  %8 = alloca i32, align 4
  %9 = alloca %"class.boost::intrusive::list_iterator.38", align 8
  %10 = alloca i8, align 1
  store ptr %0, ptr %3, align 8, !tbaa !5
  %11 = load ptr, ptr %3, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #7
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #7
  call void @_ZNK3cfg5Block13get_last_insnEv(ptr dead_on_unwind writable sret(%"class.boost::intrusive::list_iterator.38") align 8 %5, ptr noundef nonnull align 8 dereferenceable(104) %11)
  store ptr %5, ptr %4, align 8, !tbaa !5
  %12 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK3cfg5Block5succsEv(ptr noundef nonnull align 8 dereferenceable(104) %11)
  %13 = call noundef zeroext i1 @_ZNKSt6vectorIPN3cfg4EdgeESaIS2_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %12) #7
  br i1 %13, label %23, label %14

14:                                               ; preds = %1
  %15 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK3cfg5Block5succsEv(ptr noundef nonnull align 8 dereferenceable(104) %11)
  %16 = call noundef i64 @_ZNKSt6vectorIPN3cfg4EdgeESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %15) #7
  %17 = icmp eq i64 %16, 1
  br i1 %17, label %18, label %46

18:                                               ; preds = %14
  %19 = getelementptr inbounds %"class.cfg::Block", ptr %11, i32 0, i32 6
  %20 = load ptr, ptr %19, align 8, !tbaa !9
  %21 = call noundef ptr @_ZNK3cfg16ControlFlowGraph21get_succ_edge_of_typeEPKNS_5BlockENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(160) %20, ptr noundef %11, i8 noundef zeroext 3)
  %22 = icmp ne ptr %21, null
  br i1 %22, label %23, label %46

23:                                               ; preds = %18, %1
  %24 = load ptr, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #7
  call void @_ZNK3cfg5Block3endEv(ptr dead_on_unwind writable sret(%"class.boost::intrusive::list_iterator.38") align 8 %6, ptr noundef nonnull align 8 dereferenceable(104) %11)
  %25 = call noundef zeroext i1 @_ZN5boost9intrusiveneERKNS0_13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb1EEES9_(ptr noundef nonnull align 8 dereferenceable(8) %24, ptr noundef nonnull align 8 dereferenceable(8) %6)
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #7
  br i1 %25, label %26, label %45

26:                                               ; preds = %23
  call void @llvm.lifetime.start.p0(i64 2, ptr %7) #7
  %27 = load ptr, ptr %4, align 8, !tbaa !5
  %28 = call noundef ptr @_ZNK5boost9intrusive13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb1EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %27)
  %29 = getelementptr inbounds %struct.MethodItemEntry, ptr %28, i32 0, i32 2
  %30 = load ptr, ptr %29, align 8, !tbaa !26
  %31 = call noundef zeroext i16 @_ZNK13IRInstruction6opcodeEv(ptr noundef nonnull align 8 dereferenceable(32) %30)
  store i16 %31, ptr %7, align 2, !tbaa !27
  %32 = load i16, ptr %7, align 2, !tbaa !27
  %33 = call noundef zeroext i1 @_ZN6opcode11is_a_returnE8IROpcode(i16 noundef zeroext %32)
  br i1 %33, label %34, label %35

34:                                               ; preds = %26
  store i8 1, ptr %2, align 1
  store i32 1, ptr %8, align 4
  br label %42

35:                                               ; preds = %26
  %36 = load i16, ptr %7, align 2, !tbaa !27
  %37 = zext i16 %36 to i32
  %38 = icmp eq i32 %37, 25
  br i1 %38, label %39, label %40

39:                                               ; preds = %35
  store i8 5, ptr %2, align 1
  store i32 1, ptr %8, align 4
  br label %42

40:                                               ; preds = %35
  br label %41

41:                                               ; preds = %40
  store i32 0, ptr %8, align 4
  br label %42

42:                                               ; preds = %41, %39, %34
  call void @llvm.lifetime.end.p0(i64 2, ptr %7) #7
  %43 = load i32, ptr %8, align 4
  switch i32 %43, label %89 [
    i32 0, label %44
  ]

44:                                               ; preds = %42
  br label %45

45:                                               ; preds = %44, %23
  store i8 0, ptr %2, align 1
  store i32 1, ptr %8, align 4
  br label %89

46:                                               ; preds = %18, %14
  %47 = getelementptr inbounds %"class.cfg::Block", ptr %11, i32 0, i32 6
  %48 = load ptr, ptr %47, align 8, !tbaa !9
  %49 = call noundef ptr @_ZNK3cfg16ControlFlowGraph21get_succ_edge_of_typeEPKNS_5BlockENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(160) %48, ptr noundef %11, i8 noundef zeroext 2)
  %50 = icmp ne ptr %49, null
  br i1 %50, label %51, label %52

51:                                               ; preds = %46
  store i8 5, ptr %2, align 1
  store i32 1, ptr %8, align 4
  br label %89

52:                                               ; preds = %46
  %53 = getelementptr inbounds %"class.cfg::Block", ptr %11, i32 0, i32 6
  %54 = load ptr, ptr %53, align 8, !tbaa !9
  %55 = call noundef ptr @_ZNK3cfg16ControlFlowGraph21get_succ_edge_of_typeEPKNS_5BlockENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(160) %54, ptr noundef %11, i8 noundef zeroext 1)
  %56 = icmp ne ptr %55, null
  br i1 %56, label %57, label %82

57:                                               ; preds = %52
  %58 = load ptr, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #7
  call void @_ZNK3cfg5Block3endEv(ptr dead_on_unwind writable sret(%"class.boost::intrusive::list_iterator.38") align 8 %9, ptr noundef nonnull align 8 dereferenceable(104) %11)
  %59 = call noundef zeroext i1 @_ZN5boost9intrusiveneERKNS0_13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb1EEES9_(ptr noundef nonnull align 8 dereferenceable(8) %58, ptr noundef nonnull align 8 dereferenceable(8) %9)
  br i1 %59, label %60, label %61

60:                                               ; preds = %57
  br label %63

61:                                               ; preds = %57
  call void (ptr, ptr, i32, ptr, i32, ptr, ...) @_Z11assert_failPKcS0_jS0_10RedexErrorS0_z(ptr noundef @.str.11, ptr noundef @.str.8, i32 noundef 329, ptr noundef @__PRETTY_FUNCTION__._ZNK3cfg5Block13branchingnessEv, i32 noundef 2, ptr noundef @.str.9) #8
  unreachable

62:                                               ; No predecessors!
  br label %63

63:                                               ; preds = %62, %60
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #7
  call void @llvm.lifetime.start.p0(i64 1, ptr %10) #7
  %64 = load ptr, ptr %4, align 8, !tbaa !5
  %65 = call noundef ptr @_ZNK5boost9intrusive13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb1EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %64)
  %66 = getelementptr inbounds %struct.MethodItemEntry, ptr %65, i32 0, i32 2
  %67 = load ptr, ptr %66, align 8, !tbaa !26
  %68 = call noundef zeroext i16 @_ZNK13IRInstruction6opcodeEv(ptr noundef nonnull align 8 dereferenceable(32) %67)
  %69 = call noundef zeroext i8 @_ZN6opcode13branchingnessE8IROpcode(i16 noundef zeroext %68)
  store i8 %69, ptr %10, align 1, !tbaa !29
  %70 = load i8, ptr %10, align 1, !tbaa !29
  %71 = zext i8 %70 to i32
  %72 = icmp eq i32 %71, 3
  br i1 %72, label %77, label %73

73:                                               ; preds = %63
  %74 = load i8, ptr %10, align 1, !tbaa !29
  %75 = zext i8 %74 to i32
  %76 = icmp eq i32 %75, 4
  br i1 %76, label %77, label %78

77:                                               ; preds = %73, %63
  br label %80

78:                                               ; preds = %73
  call void (ptr, ptr, i32, ptr, i32, ptr, ...) @_Z11assert_failPKcS0_jS0_10RedexErrorS0_z(ptr noundef @.str.12, ptr noundef @.str.8, i32 noundef 331, ptr noundef @__PRETTY_FUNCTION__._ZNK3cfg5Block13branchingnessEv, i32 noundef 2, ptr noundef @.str.9) #8
  unreachable

79:                                               ; No predecessors!
  br label %80

80:                                               ; preds = %79, %77
  %81 = load i8, ptr %10, align 1, !tbaa !29
  store i8 %81, ptr %2, align 1
  store i32 1, ptr %8, align 4
  call void @llvm.lifetime.end.p0(i64 1, ptr %10) #7
  br label %89

82:                                               ; preds = %52
  %83 = getelementptr inbounds %"class.cfg::Block", ptr %11, i32 0, i32 6
  %84 = load ptr, ptr %83, align 8, !tbaa !9
  %85 = call noundef ptr @_ZNK3cfg16ControlFlowGraph21get_succ_edge_of_typeEPKNS_5BlockENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(160) %84, ptr noundef %11, i8 noundef zeroext 0)
  %86 = icmp ne ptr %85, null
  br i1 %86, label %87, label %88

87:                                               ; preds = %82
  store i8 2, ptr %2, align 1
  store i32 1, ptr %8, align 4
  br label %89

88:                                               ; preds = %82
  store i8 0, ptr %2, align 1
  store i32 1, ptr %8, align 4
  br label %89

89:                                               ; preds = %88, %87, %80, %51, %45, %42
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #7
  %90 = load i8, ptr %2, align 1
  ret i8 %90
}

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZNK5boost9intrusive13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb1EEptEv(ptr noundef nonnull align 8 dereferenceable(8)) #4 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 @_ZN6opcode11is_a_returnE8IROpcode(i16 noundef zeroext) #5

declare noundef zeroext i8 @_ZN6opcode13branchingnessE8IROpcode(i16 noundef zeroext) #6

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 = { noreturn "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #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 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 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 #6 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nounwind }
attributes #8 = { noreturn }

!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 96}
!10 = !{!"_ZTSN3cfg5BlockE", !11, i64 0, !12, i64 8, !20, i64 32, !20, i64 40, !22, i64 48, !22, i64 72, !6, i64 96}
!11 = !{!"long", !7, i64 0}
!12 = !{!"_ZTS6IRList", !13, i64 0}
!13 = !{!"_ZTSN5boost9intrusive4listI15MethodItemEntryJNS0_11member_hookIS2_NS0_16list_member_hookIJEEEXadL_ZNS2_10list_hook_EEEEEEEE", !14, i64 0}
!14 = !{!"_ZTSN5boost9intrusive9list_implINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEEmLb1EvEE", !15, i64 0}
!15 = !{!"_ZTSN5boost9intrusive9list_implINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEEmLb1EvE6data_tE", !16, i64 0}
!16 = !{!"_ZTSN5boost9intrusive9list_implINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEEmLb1EvE14root_plus_sizeE", !17, i64 0, !18, i64 8}
!17 = !{!"_ZTSN5boost9intrusive6detail11size_holderILb1EmvEE", !11, i64 0}
!18 = !{!"_ZTSN5boost9intrusive6detail21default_header_holderINS0_16list_node_traitsIPvEEEE", !19, i64 0}
!19 = !{!"_ZTSN5boost9intrusive9list_nodeIPvEE", !6, i64 0, !6, i64 8}
!20 = !{!"_ZTSN5boost9intrusive13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb0EEE", !21, i64 0}
!21 = !{!"_ZTSN5boost9intrusive17iiterator_membersIPNS0_9list_nodeIPvEEPKNS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS7_10list_hook_EEEEELb0EEE", !6, i64 0}
!22 = !{!"_ZTSSt6vectorIPN3cfg4EdgeESaIS2_EE", !23, i64 0}
!23 = !{!"_ZTSSt12_Vector_baseIPN3cfg4EdgeESaIS2_EE", !24, i64 0}
!24 = !{!"_ZTSNSt12_Vector_baseIPN3cfg4EdgeESaIS2_EE12_Vector_implE", !25, i64 0}
!25 = !{!"_ZTSNSt12_Vector_baseIPN3cfg4EdgeESaIS2_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!26 = !{!7, !7, i64 0}
!27 = !{!28, !28, i64 0}
!28 = !{!"_ZTS8IROpcode", !7, i64 0}
!29 = !{!30, !30, i64 0}
!30 = !{!"_ZTSN6opcode13BranchingnessE", !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.38" = type { %"struct.boost::intrusive::iiterator_members" }
%"struct.boost::intrusive::iiterator_members" = type { ptr }

@.str.8 = external hidden unnamed_addr constant [73 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [14 x i8], align 1
@__PRETTY_FUNCTION__._ZNK3cfg5Block13branchingnessEv = external hidden unnamed_addr constant [56 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [55 x i8], align 1

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

; Function Attrs: noreturn
declare void @_Z11assert_failPKcS0_jS0_10RedexErrorS0_z(ptr noundef, ptr noundef, i32 noundef, ptr noundef, i32 noundef, ptr noundef, ...) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i8 @_ZNK3cfg5Block13branchingnessEv(ptr noundef nonnull align 8 dereferenceable(104) %0) local_unnamed_addr #1 align 2 {
  %2 = alloca %"class.boost::intrusive::list_iterator.38", align 8
  %3 = alloca %"class.boost::intrusive::list_iterator.38", align 8
  %4 = alloca %"class.boost::intrusive::list_iterator.38", align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #7
  call void @_ZNK3cfg5Block13get_last_insnEv(ptr dead_on_unwind nonnull writable sret(%"class.boost::intrusive::list_iterator.38") align 8 %2, ptr noundef nonnull align 8 dereferenceable(104) %0)
  %5 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK3cfg5Block5succsEv(ptr noundef nonnull align 8 dereferenceable(104) %0)
  %6 = call noundef zeroext i1 @_ZNKSt6vectorIPN3cfg4EdgeESaIS2_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %5) #7
  br i1 %6, label %15, label %7

7:                                                ; preds = %1
  %8 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK3cfg5Block5succsEv(ptr noundef nonnull align 8 dereferenceable(104) %0)
  %9 = call noundef i64 @_ZNKSt6vectorIPN3cfg4EdgeESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %8) #7
  %10 = icmp eq i64 %9, 1
  br i1 %10, label %11, label %25

11:                                               ; preds = %7
  %12 = getelementptr inbounds i8, ptr %0, i64 96
  %13 = load ptr, ptr %12, align 8, !tbaa !5
  %14 = call noundef ptr @_ZNK3cfg16ControlFlowGraph21get_succ_edge_of_typeEPKNS_5BlockENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(160) %13, ptr noundef nonnull %0, i8 noundef zeroext 3)
  %.not = icmp eq ptr %14, null
  br i1 %.not, label %25, label %15

15:                                               ; preds = %11, %1
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #7
  call void @_ZNK3cfg5Block3endEv(ptr dead_on_unwind nonnull writable sret(%"class.boost::intrusive::list_iterator.38") align 8 %3, ptr noundef nonnull align 8 dereferenceable(104) %0)
  %16 = call noundef zeroext i1 @_ZN5boost9intrusiveneERKNS0_13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb1EEES9_(ptr noundef nonnull align 8 dereferenceable(8) %2, ptr noundef nonnull align 8 dereferenceable(8) %3)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #7
  br i1 %16, label %17, label %24

17:                                               ; preds = %15
  %18 = call noundef ptr @_ZNK5boost9intrusive13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb1EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %2)
  %19 = getelementptr inbounds i8, ptr %18, i64 24
  %20 = load ptr, ptr %19, align 8, !tbaa !25
  %21 = call noundef zeroext i16 @_ZNK13IRInstruction6opcodeEv(ptr noundef nonnull align 8 dereferenceable(32) %20)
  %22 = call noundef zeroext i1 @_ZN6opcode11is_a_returnE8IROpcode(i16 noundef zeroext %21)
  br i1 %22, label %.thread, label %23

23:                                               ; preds = %17
  %.not21 = icmp eq i16 %21, 25
  br i1 %.not21, label %.thread, label %24

24:                                               ; preds = %23, %15
  br label %.thread

25:                                               ; preds = %11, %7
  %26 = getelementptr inbounds i8, ptr %0, i64 96
  %27 = load ptr, ptr %26, align 8, !tbaa !5
  %28 = call noundef ptr @_ZNK3cfg16ControlFlowGraph21get_succ_edge_of_typeEPKNS_5BlockENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(160) %27, ptr noundef nonnull %0, i8 noundef zeroext 2)
  %.not14 = icmp eq ptr %28, null
  br i1 %.not14, label %29, label %.thread

29:                                               ; preds = %25
  %30 = load ptr, ptr %26, align 8, !tbaa !5
  %31 = call noundef ptr @_ZNK3cfg16ControlFlowGraph21get_succ_edge_of_typeEPKNS_5BlockENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(160) %30, ptr noundef nonnull %0, i8 noundef zeroext 1)
  %.not15 = icmp eq ptr %31, null
  br i1 %.not15, label %43, label %32

32:                                               ; preds = %29
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #7
  call void @_ZNK3cfg5Block3endEv(ptr dead_on_unwind nonnull writable sret(%"class.boost::intrusive::list_iterator.38") align 8 %4, ptr noundef nonnull align 8 dereferenceable(104) %0)
  %33 = call noundef zeroext i1 @_ZN5boost9intrusiveneERKNS0_13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb1EEES9_(ptr noundef nonnull align 8 dereferenceable(8) %2, ptr noundef nonnull align 8 dereferenceable(8) %4)
  br i1 %33, label %35, label %34

34:                                               ; preds = %32
  call void (ptr, ptr, i32, ptr, i32, ptr, ...) @_Z11assert_failPKcS0_jS0_10RedexErrorS0_z(ptr noundef nonnull @.str.11, ptr noundef nonnull @.str.8, i32 noundef 329, ptr noundef nonnull @__PRETTY_FUNCTION__._ZNK3cfg5Block13branchingnessEv, i32 noundef 2, ptr noundef nonnull @.str.9) #8
  unreachable

35:                                               ; preds = %32
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #7
  %36 = call noundef ptr @_ZNK5boost9intrusive13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb1EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %2)
  %37 = getelementptr inbounds i8, ptr %36, i64 24
  %38 = load ptr, ptr %37, align 8, !tbaa !25
  %39 = call noundef zeroext i16 @_ZNK13IRInstruction6opcodeEv(ptr noundef nonnull align 8 dereferenceable(32) %38)
  %40 = call noundef zeroext i8 @_ZN6opcode13branchingnessE8IROpcode(i16 noundef zeroext %39)
  %41 = add i8 %40, -3
  %or.cond = icmp ult i8 %41, 2
  br i1 %or.cond, label %.thread, label %42

42:                                               ; preds = %35
  call void (ptr, ptr, i32, ptr, i32, ptr, ...) @_Z11assert_failPKcS0_jS0_10RedexErrorS0_z(ptr noundef nonnull @.str.12, ptr noundef nonnull @.str.8, i32 noundef 331, ptr noundef nonnull @__PRETTY_FUNCTION__._ZNK3cfg5Block13branchingnessEv, i32 noundef 2, ptr noundef nonnull @.str.9) #8
  unreachable

43:                                               ; preds = %29
  %44 = load ptr, ptr %26, align 8, !tbaa !5
  %45 = call noundef ptr @_ZNK3cfg16ControlFlowGraph21get_succ_edge_of_typeEPKNS_5BlockENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(160) %44, ptr noundef nonnull %0, i8 noundef zeroext 0)
  %.not16 = icmp eq ptr %45, null
  %.18 = select i1 %.not16, i8 0, i8 2
  br label %.thread

.thread:                                          ; preds = %17, %43, %35, %25, %23, %24
  %.1 = phi i8 [ 0, %24 ], [ 5, %23 ], [ 5, %25 ], [ %40, %35 ], [ %.18, %43 ], [ 1, %17 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #7
  ret i8 %.1
}

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_ZNK3cfg16ControlFlowGraph21get_succ_edge_of_typeEPKNS_5BlockENS_8EdgeTypeE(ptr noundef nonnull align 8 dereferenceable(160), ptr noundef, i8 noundef zeroext) 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_EEEEELb1EEES9_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local noundef ptr @_ZNK5boost9intrusive13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb1EEptEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4 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 @_ZN6opcode11is_a_returnE8IROpcode(i16 noundef zeroext) local_unnamed_addr #5

declare noundef zeroext i8 @_ZN6opcode13branchingnessE8IROpcode(i16 noundef zeroext) local_unnamed_addr #6

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 = { noreturn "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #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 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 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 #6 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nounwind }
attributes #8 = { noreturn }

!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, !18, i64 96}
!6 = !{!"_ZTSN3cfg5BlockE", !7, i64 0, !10, i64 8, !19, i64 32, !19, i64 40, !21, i64 48, !21, i64 72, !18, i64 96}
!7 = !{!"long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"_ZTS6IRList", !11, i64 0}
!11 = !{!"_ZTSN5boost9intrusive4listI15MethodItemEntryJNS0_11member_hookIS2_NS0_16list_member_hookIJEEEXadL_ZNS2_10list_hook_EEEEEEEE", !12, i64 0}
!12 = !{!"_ZTSN5boost9intrusive9list_implINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEEmLb1EvEE", !13, i64 0}
!13 = !{!"_ZTSN5boost9intrusive9list_implINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEEmLb1EvE6data_tE", !14, i64 0}
!14 = !{!"_ZTSN5boost9intrusive9list_implINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEEmLb1EvE14root_plus_sizeE", !15, i64 0, !16, i64 8}
!15 = !{!"_ZTSN5boost9intrusive6detail11size_holderILb1EmvEE", !7, i64 0}
!16 = !{!"_ZTSN5boost9intrusive6detail21default_header_holderINS0_16list_node_traitsIPvEEEE", !17, i64 0}
!17 = !{!"_ZTSN5boost9intrusive9list_nodeIPvEE", !18, i64 0, !18, i64 8}
!18 = !{!"any pointer", !8, i64 0}
!19 = !{!"_ZTSN5boost9intrusive13list_iteratorINS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS3_10list_hook_EEEEELb0EEE", !20, i64 0}
!20 = !{!"_ZTSN5boost9intrusive17iiterator_membersIPNS0_9list_nodeIPvEEPKNS0_8mhtraitsI15MethodItemEntryNS0_16list_member_hookIJEEEXadL_ZNS7_10list_hook_EEEEELb0EEE", !18, i64 0}
!21 = !{!"_ZTSSt6vectorIPN3cfg4EdgeESaIS2_EE", !22, i64 0}
!22 = !{!"_ZTSSt12_Vector_baseIPN3cfg4EdgeESaIS2_EE", !23, i64 0}
!23 = !{!"_ZTSNSt12_Vector_baseIPN3cfg4EdgeESaIS2_EE12_Vector_implE", !24, i64 0}
!24 = !{!"_ZTSNSt12_Vector_baseIPN3cfg4EdgeESaIS2_EE17_Vector_impl_dataE", !18, i64 0, !18, i64 8, !18, i64 16}
!25 = !{!8, !8, i64 0}


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