; LLVM IR from Razakhel/RaZ :: src/RaZ/Render/Window.ll (ZN3Raz6Window13processInputsEf)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"struct.std::__detail::_Node_const_iterator" = type { %"struct.std::__detail::_Node_iterator_base" }
%"struct.std::__detail::_Node_iterator_base" = type { ptr }
%"struct.std::__detail::_Node_iterator" = type { %"struct.std::__detail::_Node_iterator_base" }
%"class.Raz::Window" = type <{ %"class.Raz::OwnerValue", ptr, i32, i32, i32, i32, %"class.std::tuple", %"class.std::function.42", %"class.Raz::Overlay", i8, [7 x i8] }>
%"class.Raz::OwnerValue" = type { ptr }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Tuple_impl.3", %"struct.std::_Head_base.41" }
%"struct.std::_Tuple_impl.3" = type { %"struct.std::_Tuple_impl.4", %"struct.std::_Head_base.37" }
%"struct.std::_Tuple_impl.4" = type { %"struct.std::_Tuple_impl.5", %"struct.std::_Head_base.31" }
%"struct.std::_Tuple_impl.5" = type { %"struct.std::_Tuple_impl.6", %"struct.std::_Head_base.26" }
%"struct.std::_Tuple_impl.6" = type { %"struct.std::_Head_base" }
%"struct.std::_Head_base" = type { %"class.std::unordered_map" }
%"class.std::unordered_map" = type { %"class.std::_Hashtable.7" }
%"class.std::_Hashtable.7" = type { ptr, i64, %"struct.std::__detail::_Hash_node_base", i64, %"struct.std::__detail::_Prime_rehash_policy", ptr }
%"struct.std::__detail::_Hash_node_base" = type { ptr }
%"struct.std::__detail::_Prime_rehash_policy" = type { float, i64 }
%"struct.std::_Head_base.26" = type { %"class.std::tuple.27" }
%"class.std::tuple.27" = type { %"struct.std::_Tuple_impl.28" }
%"struct.std::_Tuple_impl.28" = type { %"struct.std::_Tuple_impl.29", %"struct.std::_Head_base.36" }
%"struct.std::_Tuple_impl.29" = type { %"struct.std::_Tuple_impl.30", %"struct.std::_Head_base.35" }
%"struct.std::_Tuple_impl.30" = type { %"struct.std::_Head_base.31" }
%"struct.std::_Head_base.35" = type { double }
%"struct.std::_Head_base.36" = type { double }
%"struct.std::_Head_base.31" = type { %"class.std::function.32" }
%"class.std::function.32" = type { %"class.std::_Function_base", ptr }
%"class.std::_Function_base" = type { %"union.std::_Any_data", ptr }
%"union.std::_Any_data" = type { %"union.std::_Nocopy_types" }
%"union.std::_Nocopy_types" = type { { i64, i64 } }
%"struct.std::_Head_base.37" = type { %"class.std::vector" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::tuple<int, std::function<void (float)>, Raz::Input::ActionTrigger, std::function<void ()>>, std::allocator<std::tuple<int, std::function<void (float)>, Raz::Input::ActionTrigger, std::function<void ()>>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::tuple<int, std::function<void (float)>, Raz::Input::ActionTrigger, std::function<void ()>>, std::allocator<std::tuple<int, std::function<void (float)>, Raz::Input::ActionTrigger, std::function<void ()>>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::tuple<int, std::function<void (float)>, Raz::Input::ActionTrigger, std::function<void ()>>, std::allocator<std::tuple<int, std::function<void (float)>, Raz::Input::ActionTrigger, std::function<void ()>>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::tuple<int, std::function<void (float)>, Raz::Input::ActionTrigger, std::function<void ()>>, std::allocator<std::tuple<int, std::function<void (float)>, Raz::Input::ActionTrigger, std::function<void ()>>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::_Head_base.41" = type { %"class.std::vector" }
%"class.std::function.42" = type { %"class.std::_Function_base", ptr }
%"class.Raz::Overlay" = type { %"class.std::vector.44" }
%"class.std::vector.44" = type { %"struct.std::_Vector_base.45" }
%"struct.std::_Vector_base.45" = type { %"struct.std::_Vector_base<std::unique_ptr<Raz::OverlayWindow>, std::allocator<std::unique_ptr<Raz::OverlayWindow>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::unique_ptr<Raz::OverlayWindow>, std::allocator<std::unique_ptr<Raz::OverlayWindow>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::unique_ptr<Raz::OverlayWindow>, std::allocator<std::unique_ptr<Raz::OverlayWindow>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::unique_ptr<Raz::OverlayWindow>, std::allocator<std::unique_ptr<Raz::OverlayWindow>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::pair.213" = type { i32, [4 x i8], %"struct.std::pair.215" }
%"struct.std::pair.215" = type <{ %"class.std::function.176", i32, [4 x i8] }>
%"class.std::function.176" = type { %"class.std::_Function_base", 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: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #1

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3Raz6Window13processInputsEf(ptr noundef nonnull align 8 dereferenceable(273) %0, float noundef %1) #2 align 2 {
  %3 = alloca ptr, align 8
  %4 = alloca float, align 4
  %5 = alloca ptr, align 8
  %6 = alloca %"struct.std::__detail::_Node_const_iterator", align 8
  %7 = alloca %"struct.std::__detail::_Node_const_iterator", align 8
  %8 = alloca ptr, align 8
  %9 = alloca %"struct.std::__detail::_Node_const_iterator", align 8
  %10 = alloca %"struct.std::__detail::_Node_iterator", align 8
  %11 = alloca %"struct.std::__detail::_Node_const_iterator", align 8
  store ptr %0, ptr %3, align 8, !tbaa !5
  store float %1, ptr %4, align 4, !tbaa !9
  %12 = load ptr, ptr %3, align 8
  call void @glfwPollEvents()
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #5
  %13 = getelementptr inbounds %"class.Raz::Window", ptr %12, i32 0, i32 6
  %14 = call noundef nonnull align 8 dereferenceable(56) ptr @_ZSt3getISt13unordered_mapIiSt4pairISt8functionIFvfEEN3Raz5Input13ActionTriggerEESt4hashIiESt8equal_toIiESaIS1_IKiS8_EEEJSt6vectorISt5tupleIJiS4_S7_S2_IFvvEEEESaISL_EESN_S2_IFvddEESI_IJddSP_EESG_EERT_RSI_IJDpT0_EE(ptr noundef nonnull align 8 dereferenceable(184) %13) #5
  store ptr %14, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  %15 = load ptr, ptr %5, align 8, !tbaa !5
  %16 = call ptr @_ZNKSt13unordered_mapIiSt4pairISt8functionIFvfEEN3Raz5Input13ActionTriggerEESt4hashIiESt8equal_toIiESaIS0_IKiS7_EEE6cbeginEv(ptr noundef nonnull align 8 dereferenceable(56) %15) #5
  %17 = getelementptr inbounds %"struct.std::__detail::_Node_const_iterator", ptr %6, i32 0, i32 0
  %18 = getelementptr inbounds %"struct.std::__detail::_Node_iterator_base", ptr %17, i32 0, i32 0
  store ptr %16, ptr %18, align 8
  br label %19

19:                                               ; preds = %45, %2
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  %20 = load ptr, ptr %5, align 8, !tbaa !5
  %21 = call ptr @_ZNKSt13unordered_mapIiSt4pairISt8functionIFvfEEN3Raz5Input13ActionTriggerEESt4hashIiESt8equal_toIiESaIS0_IKiS7_EEE4cendEv(ptr noundef nonnull align 8 dereferenceable(56) %20) #5
  %22 = getelementptr inbounds %"struct.std::__detail::_Node_const_iterator", ptr %7, i32 0, i32 0
  %23 = getelementptr inbounds %"struct.std::__detail::_Node_iterator_base", ptr %22, i32 0, i32 0
  store ptr %21, ptr %23, align 8
  %24 = call noundef zeroext i1 @_ZNSt8__detailneERKNS_19_Node_iterator_baseISt4pairIKiS1_ISt8functionIFvfEEN3Raz5Input13ActionTriggerEEELb0EEESD_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %7) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  br i1 %24, label %25, label %46

25:                                               ; preds = %19
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #5
  %26 = call noundef ptr @_ZNKSt8__detail20_Node_const_iteratorISt4pairIKiS1_ISt8functionIFvfEEN3Raz5Input13ActionTriggerEEELb0ELb0EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  %27 = getelementptr inbounds %"struct.std::pair.213", ptr %26, i32 0, i32 2
  store ptr %27, ptr %8, align 8, !tbaa !5
  %28 = load ptr, ptr %8, align 8, !tbaa !5
  %29 = getelementptr inbounds %"struct.std::pair.215", ptr %28, i32 0, i32 0
  %30 = load float, ptr %4, align 4, !tbaa !9
  call void @_ZNKSt8functionIFvfEEclEf(ptr noundef nonnull align 8 dereferenceable(32) %29, float noundef %30)
  %31 = load ptr, ptr %8, align 8, !tbaa !5
  %32 = getelementptr inbounds %"struct.std::pair.215", ptr %31, i32 0, i32 1
  %33 = load i32, ptr %32, align 8, !tbaa !11
  %34 = icmp eq i32 %33, 0
  br i1 %34, label %35, label %43

35:                                               ; preds = %25
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  %36 = load ptr, ptr %5, align 8, !tbaa !5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %11, ptr align 8 %6, i64 8, i1 false)
  %37 = getelementptr inbounds %"struct.std::__detail::_Node_const_iterator", ptr %11, i32 0, i32 0
  %38 = getelementptr inbounds %"struct.std::__detail::_Node_iterator_base", ptr %37, i32 0, i32 0
  %39 = load ptr, ptr %38, align 8
  %40 = call ptr @_ZNSt13unordered_mapIiSt4pairISt8functionIFvfEEN3Raz5Input13ActionTriggerEESt4hashIiESt8equal_toIiESaIS0_IKiS7_EEE5eraseENSt8__detail20_Node_const_iteratorISD_Lb0ELb0EEE(ptr noundef nonnull align 8 dereferenceable(56) %36, ptr %39)
  %41 = getelementptr inbounds %"struct.std::__detail::_Node_iterator", ptr %10, i32 0, i32 0
  %42 = getelementptr inbounds %"struct.std::__detail::_Node_iterator_base", ptr %41, i32 0, i32 0
  store ptr %40, ptr %42, align 8
  call void @_ZNSt8__detail20_Node_const_iteratorISt4pairIKiS1_ISt8functionIFvfEEN3Raz5Input13ActionTriggerEEELb0ELb0EEC2ERKNS_14_Node_iteratorISA_Lb0ELb0EEE(ptr noundef nonnull align 8 dereferenceable(8) %9, ptr noundef nonnull align 8 dereferenceable(8) %10) #5
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %6, ptr align 8 %9, i64 8, i1 false)
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #5
  br label %45

43:                                               ; preds = %25
  %44 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8__detail20_Node_const_iteratorISt4pairIKiS1_ISt8functionIFvfEEN3Raz5Input13ActionTriggerEEELb0ELb0EEppEv(ptr noundef nonnull align 8 dereferenceable(8) %6) #5
  br label %45

45:                                               ; preds = %43, %35
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #5
  br label %19, !llvm.loop !16

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

declare void @glfwPollEvents() #3

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

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

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

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

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

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

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

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

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 = { "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 = { 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 = !{!10, !10, i64 0}
!10 = !{!"float", !7, i64 0}
!11 = !{!12, !15, i64 32}
!12 = !{!"_ZTSSt4pairISt8functionIFvfEEN3Raz5Input13ActionTriggerEE", !13, i64 0, !15, i64 32}
!13 = !{!"_ZTSSt8functionIFvfEE", !14, i64 0, !6, i64 24}
!14 = !{!"_ZTSSt14_Function_base", !7, i64 0, !6, i64 16}
!15 = !{!"_ZTSN3Raz5Input13ActionTriggerE", !7, i64 0}
!16 = distinct !{!16, !17}
!17 = !{!"llvm.loop.mustprogress"}


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

%"struct.std::__detail::_Node_const_iterator" = type { %"struct.std::__detail::_Node_iterator_base" }
%"struct.std::__detail::_Node_iterator_base" = type { ptr }
%"struct.std::__detail::_Node_iterator" = type { %"struct.std::__detail::_Node_iterator_base" }

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3Raz6Window13processInputsEf(ptr noundef nonnull align 8 dereferenceable(273) %0, float noundef %1) local_unnamed_addr #1 align 2 {
  %3 = alloca %"struct.std::__detail::_Node_const_iterator", align 8
  %4 = alloca %"struct.std::__detail::_Node_const_iterator", align 8
  %5 = alloca %"struct.std::__detail::_Node_const_iterator", align 8
  %6 = alloca %"struct.std::__detail::_Node_iterator", align 8
  tail call void @glfwPollEvents()
  %7 = getelementptr inbounds i8, ptr %0, i64 32
  %8 = tail call noundef nonnull align 8 dereferenceable(56) ptr @_ZSt3getISt13unordered_mapIiSt4pairISt8functionIFvfEEN3Raz5Input13ActionTriggerEESt4hashIiESt8equal_toIiESaIS1_IKiS8_EEEJSt6vectorISt5tupleIJiS4_S7_S2_IFvvEEEESaISL_EESN_S2_IFvddEESI_IJddSP_EESG_EERT_RSI_IJDpT0_EE(ptr noundef nonnull align 8 dereferenceable(184) %7) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #4
  %9 = tail call ptr @_ZNKSt13unordered_mapIiSt4pairISt8functionIFvfEEN3Raz5Input13ActionTriggerEESt4hashIiESt8equal_toIiESaIS0_IKiS7_EEE6cbeginEv(ptr noundef nonnull align 8 dereferenceable(56) %8) #4
  store ptr %9, ptr %3, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #4
  %10 = tail call ptr @_ZNKSt13unordered_mapIiSt4pairISt8functionIFvfEEN3Raz5Input13ActionTriggerEESt4hashIiESt8equal_toIiESaIS0_IKiS7_EEE4cendEv(ptr noundef nonnull align 8 dereferenceable(56) %8) #4
  store ptr %10, ptr %4, align 8
  %11 = call noundef zeroext i1 @_ZNSt8__detailneERKNS_19_Node_iterator_baseISt4pairIKiS1_ISt8functionIFvfEEN3Raz5Input13ActionTriggerEEELb0EEESD_(ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef nonnull align 8 dereferenceable(8) %4) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #4
  br i1 %11, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %2, %22
  %12 = call noundef ptr @_ZNKSt8__detail20_Node_const_iteratorISt4pairIKiS1_ISt8functionIFvfEEN3Raz5Input13ActionTriggerEEELb0ELb0EEptEv(ptr noundef nonnull align 8 dereferenceable(8) %3) #4
  %13 = getelementptr inbounds i8, ptr %12, i64 8
  call void @_ZNKSt8functionIFvfEEclEf(ptr noundef nonnull align 8 dereferenceable(32) %13, float noundef %1)
  %14 = getelementptr inbounds i8, ptr %12, i64 40
  %15 = load i32, ptr %14, align 8, !tbaa !5
  %16 = icmp eq i32 %15, 0
  br i1 %16, label %17, label %20

17:                                               ; preds = %.lr.ph
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #4
  %.sroa.0.0.copyload = load ptr, ptr %3, align 8
  %18 = call ptr @_ZNSt13unordered_mapIiSt4pairISt8functionIFvfEEN3Raz5Input13ActionTriggerEESt4hashIiESt8equal_toIiESaIS0_IKiS7_EEE5eraseENSt8__detail20_Node_const_iteratorISD_Lb0ELb0EEE(ptr noundef nonnull align 8 dereferenceable(56) %8, ptr %.sroa.0.0.copyload)
  store ptr %18, ptr %6, align 8
  call void @_ZNSt8__detail20_Node_const_iteratorISt4pairIKiS1_ISt8functionIFvfEEN3Raz5Input13ActionTriggerEEELb0ELb0EEC2ERKNS_14_Node_iteratorISA_Lb0ELb0EEE(ptr noundef nonnull align 8 dereferenceable(8) %5, ptr noundef nonnull align 8 dereferenceable(8) %6) #4
  %19 = load i64, ptr %5, align 8
  store i64 %19, ptr %3, align 8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %5) #4
  br label %22

20:                                               ; preds = %.lr.ph
  %21 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8__detail20_Node_const_iteratorISt4pairIKiS1_ISt8functionIFvfEEN3Raz5Input13ActionTriggerEEELb0ELb0EEppEv(ptr noundef nonnull align 8 dereferenceable(8) %3) #4
  br label %22

22:                                               ; preds = %20, %17
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #4
  %23 = call ptr @_ZNKSt13unordered_mapIiSt4pairISt8functionIFvfEEN3Raz5Input13ActionTriggerEESt4hashIiESt8equal_toIiESaIS0_IKiS7_EEE4cendEv(ptr noundef nonnull align 8 dereferenceable(56) %8) #4
  store ptr %23, ptr %4, align 8
  %24 = call noundef zeroext i1 @_ZNSt8__detailneERKNS_19_Node_iterator_baseISt4pairIKiS1_ISt8functionIFvfEEN3Raz5Input13ActionTriggerEEELb0EEESD_(ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef nonnull align 8 dereferenceable(8) %4) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #4
  br i1 %24, label %.lr.ph, label %._crit_edge, !llvm.loop !13

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

declare void @glfwPollEvents() local_unnamed_addr #2

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

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

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt8__detail20_Node_const_iteratorISt4pairIKiS1_ISt8functionIFvfEEN3Raz5Input13ActionTriggerEEELb0ELb0EEppEv(ptr noundef nonnull align 8 dereferenceable(8)) local_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 = { "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 = { nounwind }

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

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


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