; LLVM IR from facebook/redex :: service/switch-partitioning (SwitchEquivFinder)

; 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.anon.395 = type { ptr, ptr }
%"class.UnorderedMap<cfg::Block *, std::map<unsigned int, IRInstruction *>>::ConstFixedIterator" = type { %"struct.std::__detail::_Node_const_iterator.396" }
%"struct.std::__detail::_Node_const_iterator.396" = type { %"struct.std::__detail::_Node_iterator_base.160" }
%"struct.std::__detail::_Node_iterator_base.160" = type { ptr }
%"struct.std::_Rb_tree_const_iterator.397" = type { ptr }
%"class.cfg::InstructionIteratorImpl" = type { ptr, %"struct.std::_Rb_tree_const_iterator", %"class.ir_list::InstructionIteratorImpl" }
%"struct.std::_Rb_tree_const_iterator" = type { ptr }
%"class.ir_list::InstructionIteratorImpl" = type { %"class.boost::intrusive::list_iterator", %"class.boost::intrusive::list_iterator" }
%"class.boost::intrusive::list_iterator" = type { %"struct.boost::intrusive::iiterator_members" }
%"struct.boost::intrusive::iiterator_members" = type { ptr }
%"struct.std::pair.161" = type { ptr, %"class.std::map.95" }
%"class.std::map.95" = type { %"class.std::_Rb_tree.96" }
%"class.std::_Rb_tree.96" = type { %"struct.std::_Rb_tree<unsigned int, std::pair<const unsigned int, IRInstruction *>, std::_Select1st<std::pair<const unsigned int, IRInstruction *>>, std::less<unsigned int>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<unsigned int, std::pair<const unsigned int, IRInstruction *>, std::_Select1st<std::pair<const unsigned int, IRInstruction *>>, std::less<unsigned int>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"struct.std::pair.398" = type { i32, ptr }
%struct.MethodItemEntry = type { %"class.boost::intrusive::list_member_hook", i32, %union.anon.30 }
%"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.30 = type { 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 noundef ptr @_ZNK3cfg23InstructionIteratorImplILb0EEptEv(ptr noundef nonnull align 8 dereferenceable(32)) #1 align 2

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i64 @_ZN17SwitchEquivEditor30copy_extra_loads_to_leaf_blockERK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS6_EEESt4hashIS3_ESt8equal_toIS3_EEPNS1_16ControlFlowGraphES3_(ptr noundef nonnull align 8 dereferenceable(56) %0, ptr noundef %1, ptr noundef %2) #1 align 2 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i64, align 8
  %8 = alloca %class.anon.395, align 8
  %9 = alloca ptr, align 8
  %10 = alloca %"class.UnorderedMap<cfg::Block *, std::map<unsigned int, IRInstruction *>>::ConstFixedIterator", align 8
  %11 = alloca %"class.UnorderedMap<cfg::Block *, std::map<unsigned int, IRInstruction *>>::ConstFixedIterator", align 8
  %12 = alloca ptr, align 8
  %13 = alloca %"struct.std::_Rb_tree_const_iterator.397", align 8
  %14 = alloca %"struct.std::_Rb_tree_const_iterator.397", align 8
  %15 = alloca ptr, align 8
  %16 = alloca ptr, align 8
  %17 = alloca %"class.cfg::InstructionIteratorImpl", align 8
  %18 = alloca %"class.cfg::InstructionIteratorImpl", 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
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #6
  store i64 0, ptr %7, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 16, ptr %8) #6
  %19 = getelementptr inbounds %class.anon.395, ptr %8, i32 0, i32 0
  store ptr %6, ptr %19, align 8, !tbaa !5
  %20 = getelementptr inbounds %class.anon.395, ptr %8, i32 0, i32 1
  store ptr %7, ptr %20, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #6
  %21 = load ptr, ptr %4, align 8, !tbaa !5
  %22 = call ptr @_ZNK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS5_EEESt4hashIS2_ESt8equal_toIS2_EE4findERKS2_(ptr noundef nonnull align 8 dereferenceable(56) %21, ptr noundef nonnull align 8 dereferenceable(8) %6)
  %23 = getelementptr inbounds %"class.UnorderedMap<cfg::Block *, std::map<unsigned int, IRInstruction *>>::ConstFixedIterator", ptr %10, i32 0, i32 0
  %24 = getelementptr inbounds %"struct.std::__detail::_Node_const_iterator.396", ptr %23, i32 0, i32 0
  %25 = getelementptr inbounds %"struct.std::__detail::_Node_iterator_base.160", ptr %24, i32 0, i32 0
  store ptr %22, ptr %25, align 8
  store ptr %10, ptr %9, align 8, !tbaa !5
  %26 = load ptr, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #6
  %27 = load ptr, ptr %4, align 8, !tbaa !5
  %28 = call ptr @_ZNK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS5_EEESt4hashIS2_ESt8equal_toIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(56) %27)
  %29 = getelementptr inbounds %"class.UnorderedMap<cfg::Block *, std::map<unsigned int, IRInstruction *>>::ConstFixedIterator", ptr %11, i32 0, i32 0
  %30 = getelementptr inbounds %"struct.std::__detail::_Node_const_iterator.396", ptr %29, i32 0, i32 0
  %31 = getelementptr inbounds %"struct.std::__detail::_Node_iterator_base.160", ptr %30, i32 0, i32 0
  store ptr %28, ptr %31, align 8
  %32 = call noundef zeroext i1 @_ZNK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS5_EEESt4hashIS2_ESt8equal_toIS2_EE18ConstFixedIteratorneERKSI_(ptr noundef nonnull align 8 dereferenceable(8) %26, ptr noundef nonnull align 8 dereferenceable(8) %11)
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #6
  br i1 %32, label %33, label %70

33:                                               ; preds = %3
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #6
  %34 = load ptr, ptr %9, align 8, !tbaa !5
  %35 = call noundef ptr @_ZNK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS5_EEESt4hashIS2_ESt8equal_toIS2_EE18ConstFixedIteratorptEv(ptr noundef nonnull align 8 dereferenceable(8) %34)
  %36 = getelementptr inbounds %"struct.std::pair.161", ptr %35, i32 0, i32 1
  store ptr %36, ptr %12, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #6
  %37 = load ptr, ptr %12, align 8, !tbaa !5
  %38 = call ptr @_ZNKSt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS1_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %37) #6
  %39 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator.397", 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 %12, align 8, !tbaa !5
  %41 = call ptr @_ZNKSt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS1_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %40) #6
  %42 = getelementptr inbounds %"struct.std::_Rb_tree_const_iterator.397", ptr %14, i32 0, i32 0
  store ptr %41, ptr %42, align 8
  br label %43

43:                                               ; preds = %67, %33
  %44 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorISt4pairIKjP13IRInstructionEES7_(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
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #6
  br label %69

46:                                               ; preds = %43
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #6
  %47 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNKSt23_Rb_tree_const_iteratorISt4pairIKjP13IRInstructionEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #6
  store ptr %47, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #6
  %48 = load ptr, ptr %15, align 8, !tbaa !5
  %49 = getelementptr inbounds %"struct.std::pair.398", ptr %48, i32 0, i32 1
  %50 = load ptr, ptr %49, align 8, !tbaa !11
  store ptr %50, ptr %16, align 8, !tbaa !5
  %51 = load ptr, ptr %16, align 8, !tbaa !5
  %52 = icmp ne ptr %51, null
  br i1 %52, label %53, label %66

53:                                               ; preds = %46
  %54 = load ptr, ptr %16, align 8, !tbaa !5
  call void @"_ZZN17SwitchEquivEditor30copy_extra_loads_to_leaf_blockERK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS6_EEESt4hashIS3_ESt8equal_toIS3_EEPNS1_16ControlFlowGraphES3_ENK3$_0clES6_"(ptr noundef nonnull align 8 dereferenceable(16) %8, ptr noundef %54)
  %55 = load ptr, ptr %16, align 8, !tbaa !5
  %56 = call noundef zeroext i16 @_ZNK13IRInstruction6opcodeEv(ptr noundef nonnull align 8 dereferenceable(32) %55)
  %57 = call noundef zeroext i1 @_ZN6opcode28is_move_result_pseudo_objectE8IROpcode(i16 noundef zeroext %56)
  br i1 %57, label %58, label %65

58:                                               ; preds = %53
  call void @llvm.lifetime.start.p0(i64 32, ptr %17) #6
  %59 = load ptr, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %18) #6
  %60 = load ptr, ptr %5, align 8, !tbaa !5
  %61 = load ptr, ptr %16, align 8, !tbaa !5
  call void @_ZN3cfg16ControlFlowGraph9find_insnEP13IRInstructionPNS_5BlockE(ptr dead_on_unwind writable sret(%"class.cfg::InstructionIteratorImpl") align 8 %18, ptr noundef nonnull align 8 dereferenceable(160) %60, ptr noundef %61, ptr noundef null)
  call void @_ZN3cfg16ControlFlowGraph34primary_instruction_of_move_resultERKNS_23InstructionIteratorImplILb0EEE(ptr dead_on_unwind writable sret(%"class.cfg::InstructionIteratorImpl") align 8 %17, ptr noundef nonnull align 8 dereferenceable(160) %59, ptr noundef nonnull align 8 dereferenceable(32) %18)
  call void @llvm.lifetime.end.p0(i64 32, ptr %18) #6
  %62 = call noundef ptr @_ZNK3cfg23InstructionIteratorImplILb0EEptEv(ptr noundef nonnull align 8 dereferenceable(32) %17)
  %63 = getelementptr inbounds %struct.MethodItemEntry, ptr %62, i32 0, i32 2
  %64 = load ptr, ptr %63, align 8, !tbaa !14
  call void @"_ZZN17SwitchEquivEditor30copy_extra_loads_to_leaf_blockERK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS6_EEESt4hashIS3_ESt8equal_toIS3_EEPNS1_16ControlFlowGraphES3_ENK3$_0clES6_"(ptr noundef nonnull align 8 dereferenceable(16) %8, ptr noundef %64)
  call void @llvm.lifetime.end.p0(i64 32, ptr %17) #6
  br label %65

65:                                               ; preds = %58, %53
  br label %66

66:                                               ; preds = %65, %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 %67

67:                                               ; preds = %66
  %68 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorISt4pairIKjP13IRInstructionEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %13) #6
  br label %43

69:                                               ; preds = %45
  br label %70

70:                                               ; preds = %69, %3
  %71 = load i64, ptr %7, align 8, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %8) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #6
  ret i64 %71
}

; Function Attrs: mustprogress uwtable
declare dso_local ptr @_ZNK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS5_EEESt4hashIS2_ESt8equal_toIS2_EE4findERKS2_(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 @_ZNK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS5_EEESt4hashIS2_ESt8equal_toIS2_EE18ConstFixedIteratorneERKSI_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) #2 align 2

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

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

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

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

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

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

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZZN17SwitchEquivEditor30copy_extra_loads_to_leaf_blockERK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS6_EEESt4hashIS3_ESt8equal_toIS3_EEPNS1_16ControlFlowGraphES3_ENK3$_0clES6_"(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) #3 align 2

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

declare void @_ZN3cfg16ControlFlowGraph34primary_instruction_of_move_resultERKNS_23InstructionIteratorImplILb0EEE(ptr dead_on_unwind writable sret(%"class.cfg::InstructionIteratorImpl") align 8, ptr noundef nonnull align 8 dereferenceable(160), ptr noundef nonnull align 8 dereferenceable(32)) #5

declare void @_ZN3cfg16ControlFlowGraph9find_insnEP13IRInstructionPNS_5BlockE(ptr dead_on_unwind writable sret(%"class.cfg::InstructionIteratorImpl") align 8, ptr noundef nonnull align 8 dereferenceable(160), ptr noundef, ptr noundef) #5

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorISt4pairIKjP13IRInstructionEEppEv(ptr noundef nonnull align 8 dereferenceable(8)) #2 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 = { 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 = { 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 #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 = { "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"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !6, i64 8}
!12 = !{!"_ZTSSt4pairIKjP13IRInstructionE", !13, i64 0, !6, i64 8}
!13 = !{!"int", !7, i64 0}
!14 = !{!7, !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.anon.395 = type { ptr, ptr }
%"class.UnorderedMap<cfg::Block *, std::map<unsigned int, IRInstruction *>>::ConstFixedIterator" = type { %"struct.std::__detail::_Node_const_iterator.396" }
%"struct.std::__detail::_Node_const_iterator.396" = type { %"struct.std::__detail::_Node_iterator_base.160" }
%"struct.std::__detail::_Node_iterator_base.160" = type { ptr }
%"struct.std::_Rb_tree_const_iterator.397" = type { ptr }
%"class.cfg::InstructionIteratorImpl" = type { ptr, %"struct.std::_Rb_tree_const_iterator", %"class.ir_list::InstructionIteratorImpl" }
%"struct.std::_Rb_tree_const_iterator" = type { ptr }
%"class.ir_list::InstructionIteratorImpl" = type { %"class.boost::intrusive::list_iterator", %"class.boost::intrusive::list_iterator" }
%"class.boost::intrusive::list_iterator" = type { %"struct.boost::intrusive::iiterator_members" }
%"struct.boost::intrusive::iiterator_members" = type { ptr }

; 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 noundef ptr @_ZNK3cfg23InstructionIteratorImplILb0EEptEv(ptr noundef nonnull align 8 dereferenceable(32)) 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 #2 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef i64 @_ZN17SwitchEquivEditor30copy_extra_loads_to_leaf_blockERK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS6_EEESt4hashIS3_ESt8equal_toIS3_EEPNS1_16ControlFlowGraphES3_(ptr noundef nonnull align 8 dereferenceable(56) %0, ptr noundef %1, ptr noundef %2) local_unnamed_addr #1 align 2 {
  %4 = alloca ptr, align 8
  %5 = alloca i64, align 8
  %6 = alloca %class.anon.395, align 8
  %7 = alloca %"class.UnorderedMap<cfg::Block *, std::map<unsigned int, IRInstruction *>>::ConstFixedIterator", align 8
  %8 = alloca %"class.UnorderedMap<cfg::Block *, std::map<unsigned int, IRInstruction *>>::ConstFixedIterator", align 8
  %9 = alloca %"struct.std::_Rb_tree_const_iterator.397", align 8
  %10 = alloca %"struct.std::_Rb_tree_const_iterator.397", align 8
  %11 = alloca %"class.cfg::InstructionIteratorImpl", align 8
  %12 = alloca %"class.cfg::InstructionIteratorImpl", align 8
  store ptr %2, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #6
  store i64 0, ptr %5, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %6) #6
  store ptr %4, ptr %6, align 8, !tbaa !5
  %13 = getelementptr inbounds i8, ptr %6, i64 8
  store ptr %5, ptr %13, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %7) #6
  %14 = call ptr @_ZNK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS5_EEESt4hashIS2_ESt8equal_toIS2_EE4findERKS2_(ptr noundef nonnull align 8 dereferenceable(56) %0, ptr noundef nonnull align 8 dereferenceable(8) %4)
  store ptr %14, ptr %7, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #6
  %15 = call ptr @_ZNK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS5_EEESt4hashIS2_ESt8equal_toIS2_EE3endEv(ptr noundef nonnull align 8 dereferenceable(56) %0)
  store ptr %15, ptr %8, align 8
  %16 = call noundef zeroext i1 @_ZNK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS5_EEESt4hashIS2_ESt8equal_toIS2_EE18ConstFixedIteratorneERKSI_(ptr noundef nonnull align 8 dereferenceable(8) %7, ptr noundef nonnull align 8 dereferenceable(8) %8)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #6
  br i1 %16, label %17, label %36

17:                                               ; preds = %3
  %18 = call noundef ptr @_ZNK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS5_EEESt4hashIS2_ESt8equal_toIS2_EE18ConstFixedIteratorptEv(ptr noundef nonnull align 8 dereferenceable(8) %7)
  %19 = getelementptr inbounds i8, ptr %18, i64 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #6
  %20 = call ptr @_ZNKSt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS1_EEE5beginEv(ptr noundef nonnull align 8 dereferenceable(48) %19) #6
  store ptr %20, ptr %9, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #6
  %21 = call ptr @_ZNKSt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS1_EEE3endEv(ptr noundef nonnull align 8 dereferenceable(48) %19) #6
  store ptr %21, ptr %10, align 8
  %22 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorISt4pairIKjP13IRInstructionEES7_(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %10) #6
  br i1 %22, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %33, %17
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #6
  br label %36

.lr.ph:                                           ; preds = %17, %33
  %23 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNKSt23_Rb_tree_const_iteratorISt4pairIKjP13IRInstructionEEdeEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #6
  %24 = getelementptr inbounds i8, ptr %23, i64 8
  %25 = load ptr, ptr %24, align 8, !tbaa !11
  %.not = icmp eq ptr %25, null
  br i1 %.not, label %33, label %26

26:                                               ; preds = %.lr.ph
  call void @"_ZZN17SwitchEquivEditor30copy_extra_loads_to_leaf_blockERK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS6_EEESt4hashIS3_ESt8equal_toIS3_EEPNS1_16ControlFlowGraphES3_ENK3$_0clES6_"(ptr noundef nonnull align 8 dereferenceable(16) %6, ptr noundef nonnull %25)
  %27 = call noundef zeroext i16 @_ZNK13IRInstruction6opcodeEv(ptr noundef nonnull align 8 dereferenceable(32) %25)
  %28 = call noundef zeroext i1 @_ZN6opcode28is_move_result_pseudo_objectE8IROpcode(i16 noundef zeroext %27)
  br i1 %28, label %29, label %33

29:                                               ; preds = %26
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %11) #6
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %12) #6
  call void @_ZN3cfg16ControlFlowGraph9find_insnEP13IRInstructionPNS_5BlockE(ptr dead_on_unwind nonnull writable sret(%"class.cfg::InstructionIteratorImpl") align 8 %12, ptr noundef nonnull align 8 dereferenceable(160) %1, ptr noundef nonnull %25, ptr noundef null)
  call void @_ZN3cfg16ControlFlowGraph34primary_instruction_of_move_resultERKNS_23InstructionIteratorImplILb0EEE(ptr dead_on_unwind nonnull writable sret(%"class.cfg::InstructionIteratorImpl") align 8 %11, ptr noundef nonnull align 8 dereferenceable(160) %1, ptr noundef nonnull align 8 dereferenceable(32) %12)
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %12) #6
  %30 = call noundef ptr @_ZNK3cfg23InstructionIteratorImplILb0EEptEv(ptr noundef nonnull align 8 dereferenceable(32) %11)
  %31 = getelementptr inbounds i8, ptr %30, i64 24
  %32 = load ptr, ptr %31, align 8, !tbaa !14
  call void @"_ZZN17SwitchEquivEditor30copy_extra_loads_to_leaf_blockERK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS6_EEESt4hashIS3_ESt8equal_toIS3_EEPNS1_16ControlFlowGraphES3_ENK3$_0clES6_"(ptr noundef nonnull align 8 dereferenceable(16) %6, ptr noundef %32)
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %11) #6
  br label %33

33:                                               ; preds = %26, %29, %.lr.ph
  %34 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorISt4pairIKjP13IRInstructionEEppEv(ptr noundef nonnull align 8 dereferenceable(8) %9) #6
  %35 = call noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorISt4pairIKjP13IRInstructionEES7_(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %10) #6
  br i1 %35, label %.lr.ph, label %._crit_edge

36:                                               ; preds = %._crit_edge, %3
  %37 = load i64, ptr %5, align 8, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %7) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %6) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #6
  ret i64 %37
}

; Function Attrs: mustprogress uwtable
declare dso_local ptr @_ZNK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS5_EEESt4hashIS2_ESt8equal_toIS2_EE4findERKS2_(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 @_ZNK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS5_EEESt4hashIS2_ESt8equal_toIS2_EE18ConstFixedIteratorneERKSI_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #2 align 2

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZStneRKSt23_Rb_tree_const_iteratorISt4pairIKjP13IRInstructionEES7_(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 noundef nonnull align 8 dereferenceable(16) ptr @_ZNKSt23_Rb_tree_const_iteratorISt4pairIKjP13IRInstructionEEdeEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #2 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare hidden void @"_ZZN17SwitchEquivEditor30copy_extra_loads_to_leaf_blockERK12UnorderedMapIPN3cfg5BlockESt3mapIjP13IRInstructionSt4lessIjESaISt4pairIKjS6_EEESt4hashIS3_ESt8equal_toIS3_EEPNS1_16ControlFlowGraphES3_ENK3$_0clES6_"(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) local_unnamed_addr #3 align 2

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

declare void @_ZN3cfg16ControlFlowGraph34primary_instruction_of_move_resultERKNS_23InstructionIteratorImplILb0EEE(ptr dead_on_unwind writable sret(%"class.cfg::InstructionIteratorImpl") align 8, ptr noundef nonnull align 8 dereferenceable(160), ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #5

declare void @_ZN3cfg16ControlFlowGraph9find_insnEP13IRInstructionPNS_5BlockE(ptr dead_on_unwind writable sret(%"class.cfg::InstructionIteratorImpl") align 8, ptr noundef nonnull align 8 dereferenceable(160), ptr noundef, ptr noundef) local_unnamed_addr #5

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt23_Rb_tree_const_iteratorISt4pairIKjP13IRInstructionEEppEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #2 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 = { 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 = { 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 #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 = { "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"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !6, i64 8}
!12 = !{!"_ZTSSt4pairIKjP13IRInstructionE", !13, i64 0, !6, i64 8}
!13 = !{!"int", !7, i64 0}
!14 = !{!7, !7, i64 0}


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