; LLVM IR from mkazhdan/DMG :: Util/Socket.ll (ZN21DataStreamConstructor6doStepEi)

; 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::__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] }
%"class.boost::asio::ip::address" = type { i32, %"class.boost::asio::ip::address_v4", %"class.boost::asio::ip::address_v6" }
%"class.boost::asio::ip::address_v4" = type { %struct.in_addr }
%struct.in_addr = type { i32 }
%"class.boost::asio::ip::address_v6" = type { %struct.in6_addr, i64 }
%struct.in6_addr = type { %union.anon.4 }
%union.anon.4 = type { [4 x i32] }
%"class.SharedMemoryBuffer::StreamPair" = type { ptr, ptr }
%class.DataStreamConstructor = type <{ ptr, i8, i8, [6 x i8], ptr, %"class.boost::asio::ip::address", i32, [4 x i8] }>

; 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

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK5boost4asio2ip7address9to_stringB5cxx11Ev(ptr dead_on_unwind noalias writable sret(%"class.std::__cxx11::basic_string") align 8, ptr noundef nonnull align 8 dereferenceable(32)) #2 align 2

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

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znwm(i64 noundef) #4

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) #5

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN21DataStreamConstructor6doStepEi(ptr noundef nonnull align 8 dereferenceable(60) %0, i32 noundef %1) #6 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca ptr, align 8
  %4 = alloca i32, align 4
  %5 = alloca %"class.boost::asio::ip::address", align 8
  %6 = alloca i32, align 4
  %7 = alloca %"class.std::__cxx11::basic_string", align 8
  %8 = alloca %"class.std::__cxx11::basic_string", align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca %"class.SharedMemoryBuffer::StreamPair", align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  store ptr %0, ptr %3, align 8, !tbaa !5
  store i32 %1, ptr %4, align 4, !tbaa !9
  %14 = load ptr, ptr %3, align 8
  %15 = load i32, ptr %4, align 4, !tbaa !9
  switch i32 %15, label %117 [
    i32 0, label %16
    i32 1, label %30
    i32 2, label %86
  ]

16:                                               ; preds = %2
  %17 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 1
  %18 = load i8, ptr %17, align 8, !tbaa !11, !range !21, !noundef !22
  %19 = trunc i8 %18 to i1
  br i1 %19, label %29, label %20

20:                                               ; preds = %16
  %21 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 0
  %22 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 5
  %23 = call noundef ptr @_Z10GetPointerIN5boost4asio2ip7addressEEPT_RS4_(ptr noundef nonnull align 8 dereferenceable(32) %22)
  %24 = call noundef zeroext i1 @_Z12SendOnSocketIN5boost4asio2ip7addressEEbRPNS1_19basic_stream_socketINS2_3tcpENS1_9execution12any_executorIJNS6_12context_as_tIRNS1_17execution_contextEEENS6_6detail8blocking7never_tILi0EEENS6_11prefer_onlyINSD_10possibly_tILi0EEEEENSG_INSC_16outstanding_work9tracked_tILi0EEEEENSG_INSK_11untracked_tILi0EEEEENSG_INSC_12relationship6fork_tILi0EEEEENSG_INSR_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8) %21, ptr noundef %23, i64 noundef 32)
  %25 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 0
  %26 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 6
  %27 = call noundef ptr @_Z10GetPointerIiEPT_RS0_(ptr noundef nonnull align 4 dereferenceable(4) %26)
  %28 = call noundef zeroext i1 @_Z12SendOnSocketIiEbRPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8) %25, ptr noundef %27, i64 noundef 4)
  br label %29

29:                                               ; preds = %20, %16
  br label %117

30:                                               ; preds = %2
  %31 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 1
  %32 = load i8, ptr %31, align 8, !tbaa !11, !range !21, !noundef !22
  %33 = trunc i8 %32 to i1
  br i1 %33, label %34, label %85

34:                                               ; preds = %30
  call void @llvm.lifetime.start.p0(i64 32, ptr %5) #7
  call void @_ZN5boost4asio2ip7addressC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #7
  %35 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 0
  %36 = call noundef ptr @_Z10GetPointerIN5boost4asio2ip7addressEEPT_RS4_(ptr noundef nonnull align 8 dereferenceable(32) %5)
  %37 = call noundef zeroext i1 @_Z15ReceiveOnSocketIN5boost4asio2ip7addressEEbRPNS1_19basic_stream_socketINS2_3tcpENS1_9execution12any_executorIJNS6_12context_as_tIRNS1_17execution_contextEEENS6_6detail8blocking7never_tILi0EEENS6_11prefer_onlyINSD_10possibly_tILi0EEEEENSG_INSC_16outstanding_work9tracked_tILi0EEEEENSG_INSK_11untracked_tILi0EEEEENSG_INSC_12relationship6fork_tILi0EEEEENSG_INSR_14continuation_tILi0EEEEEEEEEEPT_m(ptr noundef nonnull align 8 dereferenceable(8) %35, ptr noundef %36, i64 noundef 32)
  %38 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 0
  %39 = call noundef ptr @_Z10GetPointerIiEPT_RS0_(ptr noundef nonnull align 4 dereferenceable(4) %6)
  %40 = call noundef zeroext i1 @_Z15ReceiveOnSocketIiEbRPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEEPT_m(ptr noundef nonnull align 8 dereferenceable(8) %38, ptr noundef %39, i64 noundef 4)
  call void @llvm.lifetime.start.p0(i64 32, ptr %7) #7
  %41 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 5
  call void @_ZNK5boost4asio2ip7address9to_stringB5cxx11Ev(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %7, ptr noundef nonnull align 8 dereferenceable(32) %41)
  call void @llvm.lifetime.start.p0(i64 32, ptr %8) #7
  invoke void @_ZNK5boost4asio2ip7address9to_stringB5cxx11Ev(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %8, ptr noundef nonnull align 8 dereferenceable(32) %5)
          to label %42 unwind label %65

42:                                               ; preds = %34
  %43 = call noundef zeroext i1 @_ZSteqIcEN9__gnu_cxx11__enable_ifIXsr9__is_charIT_EE7__valueEbE6__typeERKNSt7__cxx1112basic_stringIS2_St11char_traitsIS2_ESaIS2_EEESC_(ptr noundef nonnull align 8 dereferenceable(32) %7, ptr noundef nonnull align 8 dereferenceable(32) %8) #7
  br i1 %43, label %44, label %49

44:                                               ; preds = %42
  %45 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 6
  %46 = load i32, ptr %45, align 8, !tbaa !23
  %47 = load i32, ptr %6, align 4, !tbaa !9
  %48 = icmp eq i32 %46, %47
  br label %49

49:                                               ; preds = %44, %42
  %50 = phi i1 [ false, %42 ], [ %48, %44 ]
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr %8) #7
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %7) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr %7) #7
  br i1 %50, label %51, label %70

51:                                               ; preds = %49
  call void @llvm.lifetime.start.p0(i64 16, ptr %11) #7
  call void @_ZN18SharedMemoryBuffer10StreamPairC1Ev(ptr noundef nonnull align 8 dereferenceable(16) %11)
  %52 = call noundef zeroext i1 @_ZN18SharedMemoryBuffer10StreamPair22CreateSharedBufferPairERS0_(ptr noundef nonnull align 8 dereferenceable(16) %11)
  %53 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 0
  %54 = getelementptr inbounds %"class.SharedMemoryBuffer::StreamPair", ptr %11, i32 0, i32 1
  %55 = call noundef ptr @_Z10GetPointerIPN18SharedMemoryBuffer12SecondStreamEEPT_RS3_(ptr noundef nonnull align 8 dereferenceable(8) %54)
  %56 = call noundef zeroext i1 @_Z12SendOnSocketIPKN18SharedMemoryBuffer12SecondStreamEEbRPN5boost4asio19basic_stream_socketINS5_2ip3tcpENS5_9execution12any_executorIJNS9_12context_as_tIRNS5_17execution_contextEEENS9_6detail8blocking7never_tILi0EEENS9_11prefer_onlyINSG_10possibly_tILi0EEEEENSJ_INSF_16outstanding_work9tracked_tILi0EEEEENSJ_INSN_11untracked_tILi0EEEEENSJ_INSF_12relationship6fork_tILi0EEEEENSJ_INSU_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8) %53, ptr noundef %55, i64 noundef 8)
  %57 = getelementptr inbounds %"class.SharedMemoryBuffer::StreamPair", ptr %11, i32 0, i32 0
  %58 = load ptr, ptr %57, align 8, !tbaa !24
  %59 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 4
  store ptr %58, ptr %59, align 8, !tbaa !26
  %60 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 2
  %61 = load i8, ptr %60, align 1, !tbaa !27, !range !21, !noundef !22
  %62 = trunc i8 %61 to i1
  br i1 %62, label %63, label %69

63:                                               ; preds = %51
  %64 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 0
  call void @_Z11CloseSocketRPN5boost4asio19basic_stream_socketINS0_2ip3tcpENS0_9execution12any_executorIJNS4_12context_as_tIRNS0_17execution_contextEEENS4_6detail8blocking7never_tILi0EEENS4_11prefer_onlyINSB_10possibly_tILi0EEEEENSE_INSA_16outstanding_work9tracked_tILi0EEEEENSE_INSI_11untracked_tILi0EEEEENSE_INSA_12relationship6fork_tILi0EEEEENSE_INSP_14continuation_tILi0EEEEEEEEEE(ptr noundef nonnull align 8 dereferenceable(8) %64)
  br label %69

65:                                               ; preds = %34
  %66 = landingpad { ptr, i32 }
          cleanup
  %67 = extractvalue { ptr, i32 } %66, 0
  store ptr %67, ptr %9, align 8
  %68 = extractvalue { ptr, i32 } %66, 1
  store i32 %68, ptr %10, align 4
  call void @llvm.lifetime.end.p0(i64 32, ptr %8) #7
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %7) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr %7) #7
  br label %84

69:                                               ; preds = %63, %51
  call void @llvm.lifetime.end.p0(i64 16, ptr %11) #7
  br label %83

70:                                               ; preds = %49
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #7
  store ptr null, ptr %12, align 8, !tbaa !5
  %71 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 0
  %72 = call noundef ptr @_Z10GetPointerIPN18SharedMemoryBuffer12SecondStreamEEPT_RS3_(ptr noundef nonnull align 8 dereferenceable(8) %12)
  %73 = call noundef zeroext i1 @_Z12SendOnSocketIPKN18SharedMemoryBuffer12SecondStreamEEbRPN5boost4asio19basic_stream_socketINS5_2ip3tcpENS5_9execution12any_executorIJNS9_12context_as_tIRNS5_17execution_contextEEENS9_6detail8blocking7never_tILi0EEENS9_11prefer_onlyINSG_10possibly_tILi0EEEEENSJ_INSF_16outstanding_work9tracked_tILi0EEEEENSJ_INSN_11untracked_tILi0EEEEENSJ_INSF_12relationship6fork_tILi0EEEEENSJ_INSU_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8) %71, ptr noundef %72, i64 noundef 8)
  %74 = call noalias noundef nonnull ptr @_Znwm(i64 noundef 24) #8
  %75 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 0
  %76 = load ptr, ptr %75, align 8, !tbaa !28
  invoke void @_ZN12SocketStreamC1EPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEE(ptr noundef nonnull align 8 dereferenceable(17) %74, ptr noundef %76)
          to label %77 unwind label %79

77:                                               ; preds = %70
  %78 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 4
  store ptr %74, ptr %78, align 8, !tbaa !26
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #7
  br label %83

79:                                               ; preds = %70
  %80 = landingpad { ptr, i32 }
          cleanup
  %81 = extractvalue { ptr, i32 } %80, 0
  store ptr %81, ptr %9, align 8
  %82 = extractvalue { ptr, i32 } %80, 1
  store i32 %82, ptr %10, align 4
  call void @_ZdlPvm(ptr noundef %74, i64 noundef 24) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #7
  br label %84

83:                                               ; preds = %77, %69
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr %5) #7
  br label %85

84:                                               ; preds = %79, %65
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr %5) #7
  br label %118

85:                                               ; preds = %83, %30
  br label %117

86:                                               ; preds = %2
  %87 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 1
  %88 = load i8, ptr %87, align 8, !tbaa !11, !range !21, !noundef !22
  %89 = trunc i8 %88 to i1
  br i1 %89, label %116, label %90

90:                                               ; preds = %86
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #7
  %91 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 0
  %92 = call noundef ptr @_Z10GetPointerIPN18SharedMemoryBuffer12SecondStreamEEPT_RS3_(ptr noundef nonnull align 8 dereferenceable(8) %13)
  %93 = call noundef zeroext i1 @_Z15ReceiveOnSocketIPN18SharedMemoryBuffer12SecondStreamEEbRPN5boost4asio19basic_stream_socketINS4_2ip3tcpENS4_9execution12any_executorIJNS8_12context_as_tIRNS4_17execution_contextEEENS8_6detail8blocking7never_tILi0EEENS8_11prefer_onlyINSF_10possibly_tILi0EEEEENSI_INSE_16outstanding_work9tracked_tILi0EEEEENSI_INSM_11untracked_tILi0EEEEENSI_INSE_12relationship6fork_tILi0EEEEENSI_INST_14continuation_tILi0EEEEEEEEEEPT_m(ptr noundef nonnull align 8 dereferenceable(8) %91, ptr noundef %92, i64 noundef 8)
  %94 = load ptr, ptr %13, align 8, !tbaa !5
  %95 = icmp ne ptr %94, null
  br i1 %95, label %96, label %105

96:                                               ; preds = %90
  %97 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 2
  %98 = load i8, ptr %97, align 1, !tbaa !27, !range !21, !noundef !22
  %99 = trunc i8 %98 to i1
  br i1 %99, label %100, label %102

100:                                              ; preds = %96
  %101 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 0
  call void @_Z11CloseSocketRPN5boost4asio19basic_stream_socketINS0_2ip3tcpENS0_9execution12any_executorIJNS4_12context_as_tIRNS0_17execution_contextEEENS4_6detail8blocking7never_tILi0EEENS4_11prefer_onlyINSB_10possibly_tILi0EEEEENSE_INSA_16outstanding_work9tracked_tILi0EEEEENSE_INSI_11untracked_tILi0EEEEENSE_INSA_12relationship6fork_tILi0EEEEENSE_INSP_14continuation_tILi0EEEEEEEEEE(ptr noundef nonnull align 8 dereferenceable(8) %101)
  br label %102

102:                                              ; preds = %100, %96
  %103 = load ptr, ptr %13, align 8, !tbaa !5
  %104 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 4
  store ptr %103, ptr %104, align 8, !tbaa !26
  br label %115

105:                                              ; preds = %90
  %106 = call noalias noundef nonnull ptr @_Znwm(i64 noundef 24) #8
  %107 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 0
  %108 = load ptr, ptr %107, align 8, !tbaa !28
  invoke void @_ZN12SocketStreamC1EPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEE(ptr noundef nonnull align 8 dereferenceable(17) %106, ptr noundef %108)
          to label %109 unwind label %111

109:                                              ; preds = %105
  %110 = getelementptr inbounds %class.DataStreamConstructor, ptr %14, i32 0, i32 4
  store ptr %106, ptr %110, align 8, !tbaa !26
  br label %115

111:                                              ; preds = %105
  %112 = landingpad { ptr, i32 }
          cleanup
  %113 = extractvalue { ptr, i32 } %112, 0
  store ptr %113, ptr %9, align 8
  %114 = extractvalue { ptr, i32 } %112, 1
  store i32 %114, ptr %10, align 4
  call void @_ZdlPvm(ptr noundef %106, i64 noundef 24) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #7
  br label %118

115:                                              ; preds = %109, %102
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #7
  br label %116

116:                                              ; preds = %115, %86
  br label %117

117:                                              ; preds = %116, %85, %29, %2
  ret void

118:                                              ; preds = %111, %84
  %119 = load ptr, ptr %9, align 8
  %120 = load i32, ptr %10, align 4
  %121 = insertvalue { ptr, i32 } poison, ptr %119, 0
  %122 = insertvalue { ptr, i32 } %121, i32 %120, 1
  resume { ptr, i32 } %122
}

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z12SendOnSocketIN5boost4asio2ip7addressEEbRPNS1_19basic_stream_socketINS2_3tcpENS1_9execution12any_executorIJNS6_12context_as_tIRNS1_17execution_contextEEENS6_6detail8blocking7never_tILi0EEENS6_11prefer_onlyINSD_10possibly_tILi0EEEEENSG_INSC_16outstanding_work9tracked_tILi0EEEEENSG_INSK_11untracked_tILi0EEEEENSG_INSC_12relationship6fork_tILi0EEEEENSG_INSR_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, i64 noundef) #6

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z12SendOnSocketIiEbRPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, i64 noundef) #6

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z15ReceiveOnSocketIN5boost4asio2ip7addressEEbRPNS1_19basic_stream_socketINS2_3tcpENS1_9execution12any_executorIJNS6_12context_as_tIRNS1_17execution_contextEEENS6_6detail8blocking7never_tILi0EEENS6_11prefer_onlyINSD_10possibly_tILi0EEEEENSG_INSC_16outstanding_work9tracked_tILi0EEEEENSG_INSK_11untracked_tILi0EEEEENSG_INSC_12relationship6fork_tILi0EEEEENSG_INSR_14continuation_tILi0EEEEEEEEEEPT_m(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, i64 noundef) #6

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z15ReceiveOnSocketIiEbRPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEEPT_m(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, i64 noundef) #6

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN18SharedMemoryBuffer10StreamPair22CreateSharedBufferPairERS0_(ptr noundef nonnull align 8 dereferenceable(16)) #6 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z12SendOnSocketIPKN18SharedMemoryBuffer12SecondStreamEEbRPN5boost4asio19basic_stream_socketINS5_2ip3tcpENS5_9execution12any_executorIJNS9_12context_as_tIRNS5_17execution_contextEEENS9_6detail8blocking7never_tILi0EEENS9_11prefer_onlyINSG_10possibly_tILi0EEEEENSJ_INSF_16outstanding_work9tracked_tILi0EEEEENSJ_INSN_11untracked_tILi0EEEEENSJ_INSF_12relationship6fork_tILi0EEEEENSJ_INSU_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, i64 noundef) #6

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z15ReceiveOnSocketIPN18SharedMemoryBuffer12SecondStreamEEbRPN5boost4asio19basic_stream_socketINS4_2ip3tcpENS4_9execution12any_executorIJNS8_12context_as_tIRNS4_17execution_contextEEENS8_6detail8blocking7never_tILi0EEENS8_11prefer_onlyINSF_10possibly_tILi0EEEEENSI_INSE_16outstanding_work9tracked_tILi0EEEEENSI_INSM_11untracked_tILi0EEEEENSI_INSE_12relationship6fork_tILi0EEEEENSI_INST_14continuation_tILi0EEEEEEEEEEPT_m(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, i64 noundef) #6

declare void @_ZN12SocketStreamC1EPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEE(ptr, ptr)

declare void @_ZN18SharedMemoryBuffer10StreamPairC1Ev(ptr)

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 #4 = { nobuiltin allocsize(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 = { nobuiltin nounwind "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 = { 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 #7 = { nounwind }
attributes #8 = { builtin allocsize(0) }
attributes #9 = { builtin 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 = !{!"int", !7, i64 0}
!11 = !{!12, !13, i64 8}
!12 = !{!"_ZTS21DataStreamConstructor", !6, i64 0, !13, i64 8, !13, i64 9, !6, i64 16, !14, i64 24, !10, i64 56}
!13 = !{!"bool", !7, i64 0}
!14 = !{!"_ZTSN5boost4asio2ip7addressE", !15, i64 0, !16, i64 4, !18, i64 8}
!15 = !{!"_ZTSN5boost4asio2ip7addressUt_E", !7, i64 0}
!16 = !{!"_ZTSN5boost4asio2ip10address_v4E", !17, i64 0}
!17 = !{!"_ZTS7in_addr", !10, i64 0}
!18 = !{!"_ZTSN5boost4asio2ip10address_v6E", !19, i64 0, !20, i64 16}
!19 = !{!"_ZTS8in6_addr", !7, i64 0}
!20 = !{!"long", !7, i64 0}
!21 = !{i8 0, i8 2}
!22 = !{}
!23 = !{!12, !10, i64 56}
!24 = !{!25, !6, i64 0}
!25 = !{!"_ZTSN18SharedMemoryBuffer10StreamPairE", !6, i64 0, !6, i64 8}
!26 = !{!12, !6, i64 16}
!27 = !{!12, !13, i64 9}
!28 = !{!12, !6, 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.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] }
%"class.boost::asio::ip::address" = type { i32, %"class.boost::asio::ip::address_v4", %"class.boost::asio::ip::address_v6" }
%"class.boost::asio::ip::address_v4" = type { %struct.in_addr }
%struct.in_addr = type { i32 }
%"class.boost::asio::ip::address_v6" = type { %struct.in6_addr, i64 }
%struct.in6_addr = type { %union.anon.4 }
%union.anon.4 = type { [4 x i32] }
%"class.SharedMemoryBuffer::StreamPair" = type { ptr, 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

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZNK5boost4asio2ip7address9to_stringB5cxx11Ev(ptr dead_on_unwind noalias writable sret(%"class.std::__cxx11::basic_string") align 8, ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #2 align 2

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

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znwm(i64 noundef) local_unnamed_addr #4

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) local_unnamed_addr #5

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN21DataStreamConstructor6doStepEi(ptr noundef nonnull align 8 dereferenceable(60) %0, i32 noundef %1) local_unnamed_addr #6 align 2 personality ptr @__gxx_personality_v0 {
  %3 = alloca %"class.boost::asio::ip::address", align 8
  %4 = alloca i32, align 4
  %5 = alloca %"class.std::__cxx11::basic_string", align 8
  %6 = alloca %"class.std::__cxx11::basic_string", align 8
  %7 = alloca %"class.SharedMemoryBuffer::StreamPair", align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  switch i32 %1, label %83 [
    i32 0, label %10
    i32 1, label %21
    i32 2, label %63
  ]

10:                                               ; preds = %2
  %11 = getelementptr inbounds i8, ptr %0, i64 8
  %12 = load i8, ptr %11, align 8, !tbaa !5, !range !19, !noundef !20
  %13 = trunc nuw i8 %12 to i1
  br i1 %13, label %83, label %14

14:                                               ; preds = %10
  %15 = getelementptr inbounds i8, ptr %0, i64 24
  %16 = tail call noundef ptr @_Z10GetPointerIN5boost4asio2ip7addressEEPT_RS4_(ptr noundef nonnull align 8 dereferenceable(32) %15)
  %17 = tail call noundef zeroext i1 @_Z12SendOnSocketIN5boost4asio2ip7addressEEbRPNS1_19basic_stream_socketINS2_3tcpENS1_9execution12any_executorIJNS6_12context_as_tIRNS1_17execution_contextEEENS6_6detail8blocking7never_tILi0EEENS6_11prefer_onlyINSD_10possibly_tILi0EEEEENSG_INSC_16outstanding_work9tracked_tILi0EEEEENSG_INSK_11untracked_tILi0EEEEENSG_INSC_12relationship6fork_tILi0EEEEENSG_INSR_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef %16, i64 noundef 32)
  %18 = getelementptr inbounds i8, ptr %0, i64 56
  %19 = tail call noundef ptr @_Z10GetPointerIiEPT_RS0_(ptr noundef nonnull align 4 dereferenceable(4) %18)
  %20 = tail call noundef zeroext i1 @_Z12SendOnSocketIiEbRPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef %19, i64 noundef 4)
  br label %83

21:                                               ; preds = %2
  %22 = getelementptr inbounds i8, ptr %0, i64 8
  %23 = load i8, ptr %22, align 8, !tbaa !5, !range !19, !noundef !20
  %24 = trunc nuw i8 %23 to i1
  br i1 %24, label %25, label %83

25:                                               ; preds = %21
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %3) #7
  call void @_ZN5boost4asio2ip7addressC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %3) #7
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #7
  %26 = call noundef ptr @_Z10GetPointerIN5boost4asio2ip7addressEEPT_RS4_(ptr noundef nonnull align 8 dereferenceable(32) %3)
  %27 = call noundef zeroext i1 @_Z15ReceiveOnSocketIN5boost4asio2ip7addressEEbRPNS1_19basic_stream_socketINS2_3tcpENS1_9execution12any_executorIJNS6_12context_as_tIRNS1_17execution_contextEEENS6_6detail8blocking7never_tILi0EEENS6_11prefer_onlyINSD_10possibly_tILi0EEEEENSG_INSC_16outstanding_work9tracked_tILi0EEEEENSG_INSK_11untracked_tILi0EEEEENSG_INSC_12relationship6fork_tILi0EEEEENSG_INSR_14continuation_tILi0EEEEEEEEEEPT_m(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef %26, i64 noundef 32)
  %28 = call noundef ptr @_Z10GetPointerIiEPT_RS0_(ptr noundef nonnull align 4 dereferenceable(4) %4)
  %29 = call noundef zeroext i1 @_Z15ReceiveOnSocketIiEbRPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEEPT_m(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef %28, i64 noundef 4)
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %5) #7
  %30 = getelementptr inbounds i8, ptr %0, i64 24
  call void @_ZNK5boost4asio2ip7address9to_stringB5cxx11Ev(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %5, ptr noundef nonnull align 8 dereferenceable(32) %30)
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #7
  invoke void @_ZNK5boost4asio2ip7address9to_stringB5cxx11Ev(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %6, ptr noundef nonnull align 8 dereferenceable(32) %3)
          to label %31 unwind label %49

31:                                               ; preds = %25
  %32 = call noundef zeroext i1 @_ZSteqIcEN9__gnu_cxx11__enable_ifIXsr9__is_charIT_EE7__valueEbE6__typeERKNSt7__cxx1112basic_stringIS2_St11char_traitsIS2_ESaIS2_EEESC_(ptr noundef nonnull align 8 dereferenceable(32) %5, ptr noundef nonnull align 8 dereferenceable(32) %6) #7
  br i1 %32, label %33, label %.critedge

33:                                               ; preds = %31
  %34 = getelementptr inbounds i8, ptr %0, i64 56
  %35 = load i32, ptr %34, align 8, !tbaa !21
  %36 = load i32, ptr %4, align 4, !tbaa !22
  %37 = icmp eq i32 %35, %36
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #7
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #7
  br i1 %37, label %38, label %52

38:                                               ; preds = %33
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %7) #7
  call void @_ZN18SharedMemoryBuffer10StreamPairC1Ev(ptr noundef nonnull align 8 dereferenceable(16) %7)
  %39 = call noundef zeroext i1 @_ZN18SharedMemoryBuffer10StreamPair22CreateSharedBufferPairERS0_(ptr noundef nonnull align 8 dereferenceable(16) %7)
  %40 = getelementptr inbounds i8, ptr %7, i64 8
  %41 = call noundef ptr @_Z10GetPointerIPN18SharedMemoryBuffer12SecondStreamEEPT_RS3_(ptr noundef nonnull align 8 dereferenceable(8) %40)
  %42 = call noundef zeroext i1 @_Z12SendOnSocketIPKN18SharedMemoryBuffer12SecondStreamEEbRPN5boost4asio19basic_stream_socketINS5_2ip3tcpENS5_9execution12any_executorIJNS9_12context_as_tIRNS5_17execution_contextEEENS9_6detail8blocking7never_tILi0EEENS9_11prefer_onlyINSG_10possibly_tILi0EEEEENSJ_INSF_16outstanding_work9tracked_tILi0EEEEENSJ_INSN_11untracked_tILi0EEEEENSJ_INSF_12relationship6fork_tILi0EEEEENSJ_INSU_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef %41, i64 noundef 8)
  %43 = load ptr, ptr %7, align 8, !tbaa !23
  %44 = getelementptr inbounds i8, ptr %0, i64 16
  store ptr %43, ptr %44, align 8, !tbaa !25
  %45 = getelementptr inbounds i8, ptr %0, i64 9
  %46 = load i8, ptr %45, align 1, !tbaa !26, !range !19, !noundef !20
  %47 = trunc nuw i8 %46 to i1
  br i1 %47, label %48, label %51

48:                                               ; preds = %38
  call void @_Z11CloseSocketRPN5boost4asio19basic_stream_socketINS0_2ip3tcpENS0_9execution12any_executorIJNS4_12context_as_tIRNS0_17execution_contextEEENS4_6detail8blocking7never_tILi0EEENS4_11prefer_onlyINSB_10possibly_tILi0EEEEENSE_INSA_16outstanding_work9tracked_tILi0EEEEENSE_INSI_11untracked_tILi0EEEEENSE_INSA_12relationship6fork_tILi0EEEEENSE_INSP_14continuation_tILi0EEEEEEEEEE(ptr noundef nonnull align 8 dereferenceable(8) %0)
  br label %51

49:                                               ; preds = %25
  %50 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #7
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #7
  br label %62

51:                                               ; preds = %48, %38
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %7) #7
  br label %61

.critedge:                                        ; preds = %31
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #7
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #7
  br label %52

52:                                               ; preds = %.critedge, %33
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %8) #7
  store ptr null, ptr %8, align 8, !tbaa !27
  %53 = call noundef ptr @_Z10GetPointerIPN18SharedMemoryBuffer12SecondStreamEEPT_RS3_(ptr noundef nonnull align 8 dereferenceable(8) %8)
  %54 = call noundef zeroext i1 @_Z12SendOnSocketIPKN18SharedMemoryBuffer12SecondStreamEEbRPN5boost4asio19basic_stream_socketINS5_2ip3tcpENS5_9execution12any_executorIJNS9_12context_as_tIRNS5_17execution_contextEEENS9_6detail8blocking7never_tILi0EEENS9_11prefer_onlyINSG_10possibly_tILi0EEEEENSJ_INSF_16outstanding_work9tracked_tILi0EEEEENSJ_INSN_11untracked_tILi0EEEEENSJ_INSF_12relationship6fork_tILi0EEEEENSJ_INSU_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef %53, i64 noundef 8)
  %55 = call noalias noundef nonnull dereferenceable(24) ptr @_Znwm(i64 noundef 24) #8
  %56 = load ptr, ptr %0, align 8, !tbaa !28
  invoke void @_ZN12SocketStreamC1EPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEE(ptr noundef nonnull align 8 dereferenceable(17) %55, ptr noundef %56)
          to label %57 unwind label %59

57:                                               ; preds = %52
  %58 = getelementptr inbounds i8, ptr %0, i64 16
  store ptr %55, ptr %58, align 8, !tbaa !25
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #7
  br label %61

59:                                               ; preds = %52
  %60 = landingpad { ptr, i32 }
          cleanup
  call void @_ZdlPvm(ptr noundef nonnull %55, i64 noundef 24) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %8) #7
  br label %62

61:                                               ; preds = %57, %51
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %3) #7
  br label %83

62:                                               ; preds = %59, %49
  %.pn = phi { ptr, i32 } [ %60, %59 ], [ %50, %49 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %3) #7
  br label %84

63:                                               ; preds = %2
  %64 = getelementptr inbounds i8, ptr %0, i64 8
  %65 = load i8, ptr %64, align 8, !tbaa !5, !range !19, !noundef !20
  %66 = trunc nuw i8 %65 to i1
  br i1 %66, label %83, label %67

67:                                               ; preds = %63
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %9) #7
  %68 = call noundef ptr @_Z10GetPointerIPN18SharedMemoryBuffer12SecondStreamEEPT_RS3_(ptr noundef nonnull align 8 dereferenceable(8) %9)
  %69 = call noundef zeroext i1 @_Z15ReceiveOnSocketIPN18SharedMemoryBuffer12SecondStreamEEbRPN5boost4asio19basic_stream_socketINS4_2ip3tcpENS4_9execution12any_executorIJNS8_12context_as_tIRNS4_17execution_contextEEENS8_6detail8blocking7never_tILi0EEENS8_11prefer_onlyINSF_10possibly_tILi0EEEEENSI_INSE_16outstanding_work9tracked_tILi0EEEEENSI_INSM_11untracked_tILi0EEEEENSI_INSE_12relationship6fork_tILi0EEEEENSI_INST_14continuation_tILi0EEEEEEEEEEPT_m(ptr noundef nonnull align 8 dereferenceable(8) %0, ptr noundef %68, i64 noundef 8)
  %70 = load ptr, ptr %9, align 8, !tbaa !27
  %.not = icmp eq ptr %70, null
  br i1 %.not, label %76, label %71

71:                                               ; preds = %67
  %72 = getelementptr inbounds i8, ptr %0, i64 9
  %73 = load i8, ptr %72, align 1, !tbaa !26, !range !19, !noundef !20
  %74 = trunc nuw i8 %73 to i1
  br i1 %74, label %75, label %81

75:                                               ; preds = %71
  call void @_Z11CloseSocketRPN5boost4asio19basic_stream_socketINS0_2ip3tcpENS0_9execution12any_executorIJNS4_12context_as_tIRNS0_17execution_contextEEENS4_6detail8blocking7never_tILi0EEENS4_11prefer_onlyINSB_10possibly_tILi0EEEEENSE_INSA_16outstanding_work9tracked_tILi0EEEEENSE_INSI_11untracked_tILi0EEEEENSE_INSA_12relationship6fork_tILi0EEEEENSE_INSP_14continuation_tILi0EEEEEEEEEE(ptr noundef nonnull align 8 dereferenceable(8) %0)
  %.pre = load ptr, ptr %9, align 8, !tbaa !27
  br label %81

76:                                               ; preds = %67
  %77 = call noalias noundef nonnull dereferenceable(24) ptr @_Znwm(i64 noundef 24) #8
  %78 = load ptr, ptr %0, align 8, !tbaa !28
  invoke void @_ZN12SocketStreamC1EPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEE(ptr noundef nonnull align 8 dereferenceable(17) %77, ptr noundef %78)
          to label %81 unwind label %79

79:                                               ; preds = %76
  %80 = landingpad { ptr, i32 }
          cleanup
  call void @_ZdlPvm(ptr noundef nonnull %77, i64 noundef 24) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #7
  br label %84

81:                                               ; preds = %76, %71, %75
  %.sink = phi ptr [ %.pre, %75 ], [ %70, %71 ], [ %77, %76 ]
  %82 = getelementptr inbounds i8, ptr %0, i64 16
  store ptr %.sink, ptr %82, align 8, !tbaa !25
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %9) #7
  br label %83

83:                                               ; preds = %63, %81, %21, %61, %10, %14, %2
  ret void

84:                                               ; preds = %79, %62
  %.pn6 = phi { ptr, i32 } [ %80, %79 ], [ %.pn, %62 ]
  resume { ptr, i32 } %.pn6
}

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z12SendOnSocketIN5boost4asio2ip7addressEEbRPNS1_19basic_stream_socketINS2_3tcpENS1_9execution12any_executorIJNS6_12context_as_tIRNS1_17execution_contextEEENS6_6detail8blocking7never_tILi0EEENS6_11prefer_onlyINSD_10possibly_tILi0EEEEENSG_INSC_16outstanding_work9tracked_tILi0EEEEENSG_INSK_11untracked_tILi0EEEEENSG_INSC_12relationship6fork_tILi0EEEEENSG_INSR_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, i64 noundef) local_unnamed_addr #6

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z12SendOnSocketIiEbRPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, i64 noundef) local_unnamed_addr #6

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z15ReceiveOnSocketIN5boost4asio2ip7addressEEbRPNS1_19basic_stream_socketINS2_3tcpENS1_9execution12any_executorIJNS6_12context_as_tIRNS1_17execution_contextEEENS6_6detail8blocking7never_tILi0EEENS6_11prefer_onlyINSD_10possibly_tILi0EEEEENSG_INSC_16outstanding_work9tracked_tILi0EEEEENSG_INSK_11untracked_tILi0EEEEENSG_INSC_12relationship6fork_tILi0EEEEENSG_INSR_14continuation_tILi0EEEEEEEEEEPT_m(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, i64 noundef) local_unnamed_addr #6

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z15ReceiveOnSocketIiEbRPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEEPT_m(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, i64 noundef) local_unnamed_addr #6

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN18SharedMemoryBuffer10StreamPair22CreateSharedBufferPairERS0_(ptr noundef nonnull align 8 dereferenceable(16)) local_unnamed_addr #6 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z12SendOnSocketIPKN18SharedMemoryBuffer12SecondStreamEEbRPN5boost4asio19basic_stream_socketINS5_2ip3tcpENS5_9execution12any_executorIJNS9_12context_as_tIRNS5_17execution_contextEEENS9_6detail8blocking7never_tILi0EEENS9_11prefer_onlyINSG_10possibly_tILi0EEEEENSJ_INSF_16outstanding_work9tracked_tILi0EEEEENSJ_INSN_11untracked_tILi0EEEEENSJ_INSF_12relationship6fork_tILi0EEEEENSJ_INSU_14continuation_tILi0EEEEEEEEEEPKT_m(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, i64 noundef) local_unnamed_addr #6

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_Z15ReceiveOnSocketIPN18SharedMemoryBuffer12SecondStreamEEbRPN5boost4asio19basic_stream_socketINS4_2ip3tcpENS4_9execution12any_executorIJNS8_12context_as_tIRNS4_17execution_contextEEENS8_6detail8blocking7never_tILi0EEENS8_11prefer_onlyINSF_10possibly_tILi0EEEEENSI_INSE_16outstanding_work9tracked_tILi0EEEEENSI_INSM_11untracked_tILi0EEEEENSI_INSE_12relationship6fork_tILi0EEEEENSI_INST_14continuation_tILi0EEEEEEEEEEPT_m(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef, i64 noundef) local_unnamed_addr #6

declare void @_ZN12SocketStreamC1EPN5boost4asio19basic_stream_socketINS1_2ip3tcpENS1_9execution12any_executorIJNS5_12context_as_tIRNS1_17execution_contextEEENS5_6detail8blocking7never_tILi0EEENS5_11prefer_onlyINSC_10possibly_tILi0EEEEENSF_INSB_16outstanding_work9tracked_tILi0EEEEENSF_INSJ_11untracked_tILi0EEEEENSF_INSB_12relationship6fork_tILi0EEEEENSF_INSQ_14continuation_tILi0EEEEEEEEEE(ptr, ptr) local_unnamed_addr

declare void @_ZN18SharedMemoryBuffer10StreamPairC1Ev(ptr) local_unnamed_addr

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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 #4 = { nobuiltin allocsize(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 = { nobuiltin nounwind "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 = { 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 #7 = { nounwind }
attributes #8 = { builtin allocsize(0) }
attributes #9 = { builtin 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, !10, i64 8}
!6 = !{!"_ZTS21DataStreamConstructor", !7, i64 0, !10, i64 8, !10, i64 9, !7, i64 16, !11, i64 24, !15, i64 56}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"bool", !8, i64 0}
!11 = !{!"_ZTSN5boost4asio2ip7addressE", !12, i64 0, !13, i64 4, !16, i64 8}
!12 = !{!"_ZTSN5boost4asio2ip7addressUt_E", !8, i64 0}
!13 = !{!"_ZTSN5boost4asio2ip10address_v4E", !14, i64 0}
!14 = !{!"_ZTS7in_addr", !15, i64 0}
!15 = !{!"int", !8, i64 0}
!16 = !{!"_ZTSN5boost4asio2ip10address_v6E", !17, i64 0, !18, i64 16}
!17 = !{!"_ZTS8in6_addr", !8, i64 0}
!18 = !{!"long", !8, i64 0}
!19 = !{i8 0, i8 2}
!20 = !{}
!21 = !{!6, !15, i64 56}
!22 = !{!15, !15, i64 0}
!23 = !{!24, !7, i64 0}
!24 = !{!"_ZTSN18SharedMemoryBuffer10StreamPairE", !7, i64 0, !7, i64 8}
!25 = !{!6, !7, i64 16}
!26 = !{!6, !10, i64 9}
!27 = !{!7, !7, i64 0}
!28 = !{!6, !7, i64 0}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,SROAPass,SimplifyCFGPass,TailCallElimPass