; LLVM IR from dynexcoin/Dynex :: src/WalletLegacy (WalletLegacy)

; 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.std::shared_ptr.243" = type { %"class.std::__shared_ptr.244" }
%"class.std::__shared_ptr.244" = type { ptr, %"class.std::__shared_count" }
%"class.std::__shared_count" = type { ptr }
%"class.DynexCN::WalletLegacy" = type { %"class.DynexCN::IWalletLegacy", %"class.DynexCN::IBlockchainSynchronizerObserver", %"class.DynexCN::ITransfersObserver", i32, %"class.std::mutex", %"class.DynexCN::AccountBase", %"class.std::__cxx11::basic_string", ptr, ptr, ptr, i8, %"struct.std::atomic", %"struct.std::atomic", %"struct.std::atomic", %"class.DynexCN::BlockchainSynchronizer", %"class.DynexCN::TransfersSyncronizer", ptr, %"class.DynexCN::WalletUserTransactionsCache", %"class.std::unique_ptr.99", %"class.DynexCN::WalletAsyncContextCounter", %"class.Tools::ObserverManager.107", %"class.std::unique_ptr.113" }
%"class.DynexCN::IWalletLegacy" = type { ptr }
%"class.DynexCN::IBlockchainSynchronizerObserver" = type { ptr }
%"class.DynexCN::ITransfersObserver" = type { ptr }
%"class.std::mutex" = type { %"class.std::__mutex_base" }
%"class.std::__mutex_base" = type { %union.pthread_mutex_t }
%union.pthread_mutex_t = type { %struct.__pthread_mutex_s }
%struct.__pthread_mutex_s = type { i32, i32, i32, i32, i32, i16, i16, %struct.__pthread_internal_list }
%struct.__pthread_internal_list = type { ptr, ptr }
%"class.DynexCN::AccountBase" = type { %"struct.DynexCN::AccountKeys", i64 }
%"struct.DynexCN::AccountKeys" = type { %"struct.DynexCN::AccountPublicAddress", %"struct.Crypto::SecretKey", %"struct.Crypto::SecretKey" }
%"struct.DynexCN::AccountPublicAddress" = type { %"struct.Crypto::PublicKey", %"struct.Crypto::PublicKey" }
%"struct.Crypto::PublicKey" = type { [32 x i8] }
%"struct.Crypto::SecretKey" = type { [32 x i8] }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"struct.std::atomic" = type { %"struct.std::__atomic_base" }
%"struct.std::__atomic_base" = type { i64 }
%"class.DynexCN::BlockchainSynchronizer" = type { %"class.DynexCN::IObservableImpl", %"class.DynexCN::INodeObserver", %"class.Logging::LoggerRef", %"class.std::map", ptr, %"struct.Crypto::Hash", %"struct.Crypto::Hash", i32, i32, %"class.std::unique_ptr", %"class.std::__cxx11::list", %"class.std::__cxx11::list.15", %"class.std::mutex", %"class.std::mutex", %"class.std::condition_variable" }
%"class.DynexCN::IObservableImpl" = type { %"class.DynexCN::IBlockchainSynchronizer", %"class.Tools::ObserverManager" }
%"class.DynexCN::IBlockchainSynchronizer" = type { %"class.DynexCN::IObservable", %"class.DynexCN::IStreamSerializable" }
%"class.DynexCN::IObservable" = type { ptr }
%"class.DynexCN::IStreamSerializable" = type { ptr }
%"class.Tools::ObserverManager" = type { %"class.std::vector", %"class.std::mutex" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<DynexCN::IBlockchainSynchronizerObserver *, std::allocator<DynexCN::IBlockchainSynchronizerObserver *>>::_Vector_impl" }
%"struct.std::_Vector_base<DynexCN::IBlockchainSynchronizerObserver *, std::allocator<DynexCN::IBlockchainSynchronizerObserver *>>::_Vector_impl" = type { %"struct.std::_Vector_base<DynexCN::IBlockchainSynchronizerObserver *, std::allocator<DynexCN::IBlockchainSynchronizerObserver *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<DynexCN::IBlockchainSynchronizerObserver *, std::allocator<DynexCN::IBlockchainSynchronizerObserver *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.DynexCN::INodeObserver" = type { ptr }
%"class.Logging::LoggerRef" = type { ptr, %"class.std::__cxx11::basic_string" }
%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<DynexCN::IBlockchainConsumer *, std::pair<DynexCN::IBlockchainConsumer *const, std::shared_ptr<DynexCN::SynchronizationState>>, std::_Select1st<std::pair<DynexCN::IBlockchainConsumer *const, std::shared_ptr<DynexCN::SynchronizationState>>>, std::less<DynexCN::IBlockchainConsumer *>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<DynexCN::IBlockchainConsumer *, std::pair<DynexCN::IBlockchainConsumer *const, std::shared_ptr<DynexCN::SynchronizationState>>, std::_Select1st<std::pair<DynexCN::IBlockchainConsumer *const, std::shared_ptr<DynexCN::SynchronizationState>>>, std::less<DynexCN::IBlockchainConsumer *>>::_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.Crypto::Hash" = type { [32 x i8] }
%"class.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.11" }
%"struct.std::_Head_base.11" = type { ptr }
%"class.std::__cxx11::list" = type { %"class.std::__cxx11::_List_base" }
%"class.std::__cxx11::_List_base" = type { %"struct.std::__cxx11::_List_base<std::pair<const DynexCN::ITransactionReader *, std::promise<std::error_code>>, std::allocator<std::pair<const DynexCN::ITransactionReader *, std::promise<std::error_code>>>>::_List_impl" }
%"struct.std::__cxx11::_List_base<std::pair<const DynexCN::ITransactionReader *, std::promise<std::error_code>>, std::allocator<std::pair<const DynexCN::ITransactionReader *, std::promise<std::error_code>>>>::_List_impl" = type { %"struct.std::__detail::_List_node_header" }
%"struct.std::__detail::_List_node_header" = type { %"struct.std::__detail::_List_node_base", i64 }
%"struct.std::__detail::_List_node_base" = type { ptr, ptr }
%"class.std::__cxx11::list.15" = type { %"class.std::__cxx11::_List_base.16" }
%"class.std::__cxx11::_List_base.16" = type { %"struct.std::__cxx11::_List_base<std::pair<const Crypto::Hash *, std::promise<void>>, std::allocator<std::pair<const Crypto::Hash *, std::promise<void>>>>::_List_impl" }
%"struct.std::__cxx11::_List_base<std::pair<const Crypto::Hash *, std::promise<void>>, std::allocator<std::pair<const Crypto::Hash *, std::promise<void>>>>::_List_impl" = type { %"struct.std::__detail::_List_node_header" }
%"class.std::condition_variable" = type { %"class.std::__condvar" }
%"class.std::__condvar" = type { %union.pthread_cond_t }
%union.pthread_cond_t = type { %struct.__pthread_cond_s }
%struct.__pthread_cond_s = type { %union.__atomic_wide_counter, %union.__atomic_wide_counter, [2 x i32], [2 x i32], i32, i32, [2 x i32] }
%union.__atomic_wide_counter = type { i64 }
%"class.DynexCN::TransfersSyncronizer" = type { %"class.DynexCN::ITransfersSynchronizer", %"class.DynexCN::IBlockchainConsumerObserver", %"class.Logging::LoggerRef", %"class.std::unordered_map", %"class.std::unordered_map.25", ptr, ptr, ptr }
%"class.DynexCN::ITransfersSynchronizer" = type { %"class.DynexCN::IStreamSerializable" }
%"class.DynexCN::IBlockchainConsumerObserver" = type { ptr }
%"class.std::unordered_map" = 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::unordered_map.25" = type { %"class.std::_Hashtable.26" }
%"class.std::_Hashtable.26" = type { ptr, i64, %"struct.std::__detail::_Hash_node_base", i64, %"struct.std::__detail::_Prime_rehash_policy", ptr }
%"class.DynexCN::WalletUserTransactionsCache" = type { %"class.std::vector.39", %"class.std::vector.44", %"class.DynexCN::WalletUnconfirmedTransactions", %"class.std::unordered_map.85" }
%"class.std::vector.39" = type { %"struct.std::_Vector_base.40" }
%"struct.std::_Vector_base.40" = type { %"struct.std::_Vector_base<DynexCN::WalletLegacyTransaction, std::allocator<DynexCN::WalletLegacyTransaction>>::_Vector_impl" }
%"struct.std::_Vector_base<DynexCN::WalletLegacyTransaction, std::allocator<DynexCN::WalletLegacyTransaction>>::_Vector_impl" = type { %"struct.std::_Vector_base<DynexCN::WalletLegacyTransaction, std::allocator<DynexCN::WalletLegacyTransaction>>::_Vector_impl_data" }
%"struct.std::_Vector_base<DynexCN::WalletLegacyTransaction, std::allocator<DynexCN::WalletLegacyTransaction>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.44" = type { %"struct.std::_Vector_base.45" }
%"struct.std::_Vector_base.45" = type { %"struct.std::_Vector_base<DynexCN::WalletLegacyTransfer, std::allocator<DynexCN::WalletLegacyTransfer>>::_Vector_impl" }
%"struct.std::_Vector_base<DynexCN::WalletLegacyTransfer, std::allocator<DynexCN::WalletLegacyTransfer>>::_Vector_impl" = type { %"struct.std::_Vector_base<DynexCN::WalletLegacyTransfer, std::allocator<DynexCN::WalletLegacyTransfer>>::_Vector_impl_data" }
%"struct.std::_Vector_base<DynexCN::WalletLegacyTransfer, std::allocator<DynexCN::WalletLegacyTransfer>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.DynexCN::WalletUnconfirmedTransactions" = type { %"class.std::unordered_map.49", %"class.std::unordered_set", i64 }
%"class.std::unordered_map.49" = type { %"class.std::_Hashtable.50" }
%"class.std::_Hashtable.50" = type { ptr, i64, %"struct.std::__detail::_Hash_node_base", i64, %"struct.std::__detail::_Prime_rehash_policy", ptr }
%"class.std::unordered_set" = type { %"class.std::_Hashtable.67" }
%"class.std::_Hashtable.67" = type { ptr, i64, %"struct.std::__detail::_Hash_node_base", i64, %"struct.std::__detail::_Prime_rehash_policy", ptr }
%"class.std::unordered_map.85" = type { %"class.std::_Hashtable.86" }
%"class.std::_Hashtable.86" = type { ptr, i64, %"struct.std::__detail::_Hash_node_base", i64, %"struct.std::__detail::_Prime_rehash_policy", ptr }
%"class.std::unique_ptr.99" = type { %"struct.std::__uniq_ptr_data.100" }
%"struct.std::__uniq_ptr_data.100" = type { %"class.std::__uniq_ptr_impl.101" }
%"class.std::__uniq_ptr_impl.101" = type { %"class.std::tuple.102" }
%"class.std::tuple.102" = type { %"struct.std::_Tuple_impl.103" }
%"struct.std::_Tuple_impl.103" = type { %"struct.std::_Head_base.106" }
%"struct.std::_Head_base.106" = type { ptr }
%"class.DynexCN::WalletAsyncContextCounter" = type { i32, %"class.std::condition_variable", %"class.std::mutex" }
%"class.Tools::ObserverManager.107" = type { %"class.std::vector.108", %"class.std::mutex" }
%"class.std::vector.108" = type { %"struct.std::_Vector_base.109" }
%"struct.std::_Vector_base.109" = type { %"struct.std::_Vector_base<DynexCN::IWalletLegacyObserver *, std::allocator<DynexCN::IWalletLegacyObserver *>>::_Vector_impl" }
%"struct.std::_Vector_base<DynexCN::IWalletLegacyObserver *, std::allocator<DynexCN::IWalletLegacyObserver *>>::_Vector_impl" = type { %"struct.std::_Vector_base<DynexCN::IWalletLegacyObserver *, std::allocator<DynexCN::IWalletLegacyObserver *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<DynexCN::IWalletLegacyObserver *, std::allocator<DynexCN::IWalletLegacyObserver *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::unique_ptr.113" = type { %"struct.std::__uniq_ptr_data.114" }
%"struct.std::__uniq_ptr_data.114" = type { %"class.std::__uniq_ptr_impl.115" }
%"class.std::__uniq_ptr_impl.115" = type { %"class.std::tuple.116" }
%"class.std::tuple.116" = type { %"struct.std::_Tuple_impl.117" }
%"struct.std::_Tuple_impl.117" = type { %"struct.std::_Head_base.120" }
%"struct.std::_Head_base.120" = type { ptr }

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN7DynexCN12WalletLegacy13notifyClientsERSt5dequeISt10shared_ptrINS_17WalletLegacyEventEESaIS4_EE(ptr noundef nonnull align 8 dereferenceable(1336) %0, ptr noundef nonnull align 8 dereferenceable(80) %1) #1 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca %"class.std::shared_ptr.243", align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  store ptr %0, ptr %3, align 8, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !5
  %8 = load ptr, ptr %3, align 8
  br label %9

9:                                                ; preds = %21, %2
  %10 = load ptr, ptr %4, align 8, !tbaa !5
  %11 = call noundef zeroext i1 @_ZNKSt5dequeISt10shared_ptrIN7DynexCN17WalletLegacyEventEESaIS3_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(80) %10) #3
  %12 = xor i1 %11, true
  br i1 %12, label %13, label %27

13:                                               ; preds = %9
  call void @llvm.lifetime.start.p0(i64 16, ptr %5) #3
  %14 = load ptr, ptr %4, align 8, !tbaa !5
  %15 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt5dequeISt10shared_ptrIN7DynexCN17WalletLegacyEventEESaIS3_EE5frontEv(ptr noundef nonnull align 8 dereferenceable(80) %14) #3
  call void @_ZNSt10shared_ptrIN7DynexCN17WalletLegacyEventEEC2ERKS2_(ptr noundef nonnull align 8 dereferenceable(16) %5, ptr noundef nonnull align 8 dereferenceable(16) %15) #3
  %16 = call noundef ptr @_ZNKSt19__shared_ptr_accessIN7DynexCN17WalletLegacyEventELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv(ptr noundef nonnull align 1 dereferenceable(1) %5) #3
  %17 = getelementptr inbounds %"class.DynexCN::WalletLegacy", ptr %8, i32 0, i32 20
  %18 = load ptr, ptr %16, align 8, !tbaa !9
  %19 = getelementptr inbounds ptr, ptr %18, i64 2
  %20 = load ptr, ptr %19, align 8
  invoke void %20(ptr noundef nonnull align 8 dereferenceable(8) %16, ptr noundef nonnull align 8 dereferenceable(64) %17)
          to label %21 unwind label %23

21:                                               ; preds = %13
  %22 = load ptr, ptr %4, align 8, !tbaa !5
  call void @_ZNSt5dequeISt10shared_ptrIN7DynexCN17WalletLegacyEventEESaIS3_EE9pop_frontEv(ptr noundef nonnull align 8 dereferenceable(80) %22) #3
  call void @_ZNSt12__shared_ptrIN7DynexCN17WalletLegacyEventELN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %5) #3
  call void @llvm.lifetime.end.p0(i64 16, ptr %5) #3
  br label %9, !llvm.loop !11

23:                                               ; preds = %13
  %24 = landingpad { ptr, i32 }
          cleanup
  %25 = extractvalue { ptr, i32 } %24, 0
  store ptr %25, ptr %6, align 8
  %26 = extractvalue { ptr, i32 } %24, 1
  store i32 %26, ptr %7, align 4
  call void @_ZNSt12__shared_ptrIN7DynexCN17WalletLegacyEventELN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %5) #3
  call void @llvm.lifetime.end.p0(i64 16, ptr %5) #3
  br label %28

27:                                               ; preds = %9
  ret void

28:                                               ; preds = %23
  %29 = load ptr, ptr %6, align 8
  %30 = load i32, ptr %7, align 4
  %31 = insertvalue { ptr, i32 } poison, ptr %29, 0
  %32 = insertvalue { ptr, i32 } %31, i32 %30, 1
  resume { ptr, i32 } %32
}

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt12__shared_ptrIN7DynexCN17WalletLegacyEventELN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #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 = { 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 = !{!"vtable pointer", !8, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"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"

%"class.std::shared_ptr.243" = type { %"class.std::__shared_ptr.244" }
%"class.std::__shared_ptr.244" = type { ptr, %"class.std::__shared_count" }
%"class.std::__shared_count" = type { ptr }

declare i32 @__gxx_personality_v0(...)

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN7DynexCN12WalletLegacy13notifyClientsERSt5dequeISt10shared_ptrINS_17WalletLegacyEventEESaIS4_EE(ptr noundef nonnull align 8 dereferenceable(1336) %0, ptr noundef nonnull align 8 dereferenceable(80) %1) local_unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca %"class.std::shared_ptr.243", align 8
  %4 = tail call noundef zeroext i1 @_ZNKSt5dequeISt10shared_ptrIN7DynexCN17WalletLegacyEventEESaIS3_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(80) %1) #3
  br i1 %4, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %2
  %5 = getelementptr inbounds i8, ptr %0, i64 1264
  br label %6

6:                                                ; preds = %.lr.ph, %12
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %3) #3
  %7 = call noundef nonnull align 8 dereferenceable(16) ptr @_ZNSt5dequeISt10shared_ptrIN7DynexCN17WalletLegacyEventEESaIS3_EE5frontEv(ptr noundef nonnull align 8 dereferenceable(80) %1) #3
  call void @_ZNSt10shared_ptrIN7DynexCN17WalletLegacyEventEEC2ERKS2_(ptr noundef nonnull align 8 dereferenceable(16) %3, ptr noundef nonnull align 8 dereferenceable(16) %7) #3
  %8 = call noundef ptr @_ZNKSt19__shared_ptr_accessIN7DynexCN17WalletLegacyEventELN9__gnu_cxx12_Lock_policyE2ELb0ELb0EEptEv(ptr noundef nonnull align 1 dereferenceable(1) %3) #3
  %9 = load ptr, ptr %8, align 8, !tbaa !5
  %10 = getelementptr inbounds i8, ptr %9, i64 16
  %11 = load ptr, ptr %10, align 8
  invoke void %11(ptr noundef nonnull align 8 dereferenceable(8) %8, ptr noundef nonnull align 8 dereferenceable(64) %5)
          to label %12 unwind label %14

12:                                               ; preds = %6
  call void @_ZNSt5dequeISt10shared_ptrIN7DynexCN17WalletLegacyEventEESaIS3_EE9pop_frontEv(ptr noundef nonnull align 8 dereferenceable(80) %1) #3
  call void @_ZNSt12__shared_ptrIN7DynexCN17WalletLegacyEventELN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %3) #3
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %3) #3
  %13 = call noundef zeroext i1 @_ZNKSt5dequeISt10shared_ptrIN7DynexCN17WalletLegacyEventEESaIS3_EE5emptyEv(ptr noundef nonnull align 8 dereferenceable(80) %1) #3
  br i1 %13, label %._crit_edge, label %6, !llvm.loop !8

14:                                               ; preds = %6
  %15 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt12__shared_ptrIN7DynexCN17WalletLegacyEventELN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16) %3) #3
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %3) #3
  resume { ptr, i32 } %15

._crit_edge:                                      ; preds = %12, %2
  ret void
}

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

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

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt12__shared_ptrIN7DynexCN17WalletLegacyEventELN9__gnu_cxx12_Lock_policyE2EED2Ev(ptr noundef nonnull align 8 dereferenceable(16)) 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 = { 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 = !{!"vtable pointer", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = distinct !{!8, !9}
!9 = !{!"llvm.loop.mustprogress"}


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