; LLVM IR from dynexcoin/Dynex :: src/Platform/Linux/System/TcpConnection.ll (ZN6System13TcpConnection5writeEPKhm)

; 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.0 }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon.0 = type { i64, [8 x i8] }
%struct.epoll_event = type <{ i32, %union.epoll_data }>
%union.epoll_data = type { ptr }
%"struct.System::OperationContext" = type { ptr, i8, i32 }
%class.anon.10 = type { ptr }
%"class.System::TcpConnection" = type { ptr, i32, %"struct.System::ContextPair" }
%"struct.System::ContextPair" = type { ptr, ptr }
%"struct.System::NativeContext" = type { ptr, ptr, i8, i8, ptr, ptr, ptr, ptr, %"class.std::function", %"class.std::function" }
%"class.std::function" = 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 } }

@.str.1 = external hidden unnamed_addr constant [93 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [36 x i8], align 1
@_ZTISt13runtime_error = external constant ptr
@.str.7 = external hidden unnamed_addr constant [22 x i8], align 1
@_ZTIN6System20InterruptedExceptionE = external dso_local constant { ptr, ptr, ptr }, align 8
@.str.9 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [60 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [42 x i8], align 1
@__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm = external hidden unnamed_addr constant [66 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [40 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [46 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [58 x i8], align 1

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #0

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

declare i32 @__gxx_personality_v0(...)

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

declare ptr @__cxa_allocate_exception(i64)

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

declare void @_ZN6System16lastErrorMessageB5cxx11Ev(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8) #3

declare void @_ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #3

; Function Attrs: nounwind
declare void @_ZNSt13runtime_errorD1Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #4

declare void @__cxa_throw(ptr, ptr, ptr)

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

declare void @__cxa_free_exception(ptr)

declare noundef zeroext i1 @_ZN6System10Dispatcher11interruptedEv(ptr noundef nonnull align 8 dereferenceable(424)) #3

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #6

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

; Function Attrs: nounwind
declare void @_ZNSt9exceptionD2Ev(ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #4

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

; Function Attrs: nounwind willreturn memory(none)
declare ptr @__errno_location() #8

; Function Attrs: mustprogress nounwind uwtable
declare noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 8 dereferenceable(32)) #5 align 2

declare noundef ptr @_ZNK6System10Dispatcher17getCurrentContextEv(ptr noundef nonnull align 8 dereferenceable(424)) #3

; Function Attrs: nounwind
declare i32 @epoll_ctl(i32 noundef, i32 noundef, i32 noundef, ptr noundef) #4

declare noundef i32 @_ZNK6System10Dispatcher8getEpollEv(ptr noundef nonnull align 8 dereferenceable(424)) #3

declare void @_ZN6System10Dispatcher8dispatchEv(ptr noundef nonnull align 8 dereferenceable(424)) #3

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

declare void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #3

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i64 @_ZN6System13TcpConnection5writeEPKhm(ptr noundef nonnull align 8 dereferenceable(32) %0, ptr noundef %1, i64 noundef %2) #9 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca i64, align 8
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i64, align 8
  %8 = alloca %"class.std::__cxx11::basic_string", align 8
  %9 = alloca %"class.std::__cxx11::basic_string", align 8
  %10 = alloca %"class.std::__cxx11::basic_string", align 8
  %11 = alloca ptr, align 8
  %12 = alloca i32, align 4
  %13 = alloca i1, align 1
  %14 = alloca i32, align 4
  %15 = alloca i64, align 8
  %16 = alloca %"class.std::__cxx11::basic_string", align 8
  %17 = alloca %"class.std::__cxx11::basic_string", align 8
  %18 = alloca %struct.epoll_event, align 1
  %19 = alloca %"struct.System::OperationContext", align 8
  %20 = alloca %"class.std::__cxx11::basic_string", align 8
  %21 = alloca %"class.std::__cxx11::basic_string", align 8
  %22 = alloca %class.anon.10, align 8
  %23 = alloca %struct.epoll_event, align 1
  %24 = alloca %"class.std::__cxx11::basic_string", align 8
  %25 = alloca %"class.std::__cxx11::basic_string", align 8
  %26 = alloca %"class.std::__cxx11::basic_string", align 8
  %27 = alloca i1, align 1
  %28 = alloca i64, align 8
  %29 = alloca %"class.std::__cxx11::basic_string", align 8
  %30 = alloca %"class.std::__cxx11::basic_string", align 8
  %31 = alloca %"class.std::__cxx11::basic_string", align 8
  %32 = alloca i1, align 1
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store i64 %2, ptr %7, align 8, !tbaa !9
  %33 = load ptr, ptr %5, align 8
  %34 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 0
  %35 = load ptr, ptr %34, align 8, !tbaa !11
  %36 = icmp ne ptr %35, null
  br i1 %36, label %37, label %38

37:                                               ; preds = %3
  br label %40

38:                                               ; preds = %3
  call void @__assert_fail(ptr noundef @.str.7, ptr noundef @.str.1, i32 noundef 164, ptr noundef @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #10
  unreachable

39:                                               ; No predecessors!
  br label %40

40:                                               ; preds = %39, %37
  %41 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 2
  %42 = getelementptr inbounds %"struct.System::ContextPair", ptr %41, i32 0, i32 1
  %43 = load ptr, ptr %42, align 8, !tbaa !15
  %44 = icmp eq ptr %43, null
  br i1 %44, label %45, label %46

45:                                               ; preds = %40
  br label %48

46:                                               ; preds = %40
  call void @__assert_fail(ptr noundef @.str.4, ptr noundef @.str.1, i32 noundef 165, ptr noundef @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #10
  unreachable

47:                                               ; No predecessors!
  br label %48

48:                                               ; preds = %47, %45
  %49 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 0
  %50 = load ptr, ptr %49, align 8, !tbaa !11
  %51 = call noundef zeroext i1 @_ZN6System10Dispatcher11interruptedEv(ptr noundef nonnull align 8 dereferenceable(424) %50)
  br i1 %51, label %52, label %54

52:                                               ; preds = %48
  %53 = call ptr @__cxa_allocate_exception(i64 8) #11
  call void @llvm.memset.p0.i64(ptr align 16 %53, i8 0, i64 8, i1 false)
  call void @_ZN6System20InterruptedExceptionC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %53) #11
  call void @__cxa_throw(ptr %53, ptr @_ZTIN6System20InterruptedExceptionE, ptr @_ZNSt9exceptionD2Ev) #12
  unreachable

54:                                               ; preds = %48
  call void @llvm.lifetime.start.p0(i64 32, ptr %8) #11
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #11
  %55 = load i64, ptr %7, align 8, !tbaa !9
  %56 = icmp eq i64 %55, 0
  br i1 %56, label %57, label %85

57:                                               ; preds = %54
  %58 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 1
  %59 = load i32, ptr %58, align 8, !tbaa !16
  %60 = call i32 @shutdown(i32 noundef %59, i32 noundef 1) #11
  %61 = icmp eq i32 %60, -1
  br i1 %61, label %62, label %84

62:                                               ; preds = %57
  store i1 true, ptr %13, align 1
  %63 = call ptr @__cxa_allocate_exception(i64 16) #11
  call void @llvm.lifetime.start.p0(i64 32, ptr %9) #11
  call void @llvm.lifetime.start.p0(i64 32, ptr %10) #11
  invoke void @_ZN6System16lastErrorMessageB5cxx11Ev(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %10)
          to label %64 unwind label %67

64:                                               ; preds = %62
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %9, ptr noundef @.str.15, ptr noundef nonnull align 8 dereferenceable(32) %10)
          to label %65 unwind label %71

65:                                               ; preds = %64
  invoke void @_ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(16) %63, ptr noundef nonnull align 8 dereferenceable(32) %9)
          to label %66 unwind label %75

66:                                               ; preds = %65
  store i1 false, ptr %13, align 1
  invoke void @__cxa_throw(ptr %63, ptr @_ZTISt13runtime_error, ptr @_ZNSt13runtime_errorD1Ev) #12
          to label %359 unwind label %75

67:                                               ; preds = %62
  %68 = landingpad { ptr, i32 }
          cleanup
  %69 = extractvalue { ptr, i32 } %68, 0
  store ptr %69, ptr %11, align 8
  %70 = extractvalue { ptr, i32 } %68, 1
  store i32 %70, ptr %12, align 4
  br label %80

71:                                               ; preds = %64
  %72 = landingpad { ptr, i32 }
          cleanup
  %73 = extractvalue { ptr, i32 } %72, 0
  store ptr %73, ptr %11, align 8
  %74 = extractvalue { ptr, i32 } %72, 1
  store i32 %74, ptr %12, align 4
  br label %79

75:                                               ; preds = %66, %65
  %76 = landingpad { ptr, i32 }
          cleanup
  %77 = extractvalue { ptr, i32 } %76, 0
  store ptr %77, ptr %11, align 8
  %78 = extractvalue { ptr, i32 } %76, 1
  store i32 %78, ptr %12, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %9) #11
  br label %79

79:                                               ; preds = %75, %71
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %10) #11
  br label %80

80:                                               ; preds = %79, %67
  call void @llvm.lifetime.end.p0(i64 32, ptr %10) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %9) #11
  %81 = load i1, ptr %13, align 1
  br i1 %81, label %82, label %83

82:                                               ; preds = %80
  call void @__cxa_free_exception(ptr %63) #11
  br label %83

83:                                               ; preds = %82, %80
  br label %353

84:                                               ; preds = %57
  store i64 0, ptr %4, align 8
  store i32 1, ptr %14, align 4
  br label %351

85:                                               ; preds = %54
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #11
  %86 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 1
  %87 = load i32, ptr %86, align 8, !tbaa !16
  %88 = load ptr, ptr %6, align 8, !tbaa !5
  %89 = load i64, ptr %7, align 8, !tbaa !9
  %90 = invoke i64 @send(i32 noundef %87, ptr noundef %88, i64 noundef %89, i32 noundef 16384)
          to label %91 unwind label %102

91:                                               ; preds = %85
  store i64 %90, ptr %15, align 8, !tbaa !9
  %92 = load i64, ptr %15, align 8, !tbaa !9
  %93 = icmp eq i64 %92, -1
  br i1 %93, label %94, label %340

94:                                               ; preds = %91
  %95 = call ptr @__errno_location() #13
  %96 = load i32, ptr %95, align 4, !tbaa !17
  %97 = icmp ne i32 %96, 11
  br i1 %97, label %98, label %115

98:                                               ; preds = %94
  call void @llvm.lifetime.start.p0(i64 32, ptr %16) #11
  call void @llvm.lifetime.start.p0(i64 32, ptr %17) #11
  invoke void @_ZN6System16lastErrorMessageB5cxx11Ev(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %17)
          to label %99 unwind label %106

99:                                               ; preds = %98
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %16, ptr noundef @.str.16, ptr noundef nonnull align 8 dereferenceable(32) %17)
          to label %100 unwind label %110

100:                                              ; preds = %99
  %101 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_(ptr noundef nonnull align 8 dereferenceable(32) %8, ptr noundef nonnull align 8 dereferenceable(32) %16) #11
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %16) #11
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %17) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %17) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %16) #11
  br label %324

102:                                              ; preds = %85
  %103 = landingpad { ptr, i32 }
          cleanup
  %104 = extractvalue { ptr, i32 } %103, 0
  store ptr %104, ptr %11, align 8
  %105 = extractvalue { ptr, i32 } %103, 1
  store i32 %105, ptr %12, align 4
  br label %350

106:                                              ; preds = %98
  %107 = landingpad { ptr, i32 }
          cleanup
  %108 = extractvalue { ptr, i32 } %107, 0
  store ptr %108, ptr %11, align 8
  %109 = extractvalue { ptr, i32 } %107, 1
  store i32 %109, ptr %12, align 4
  br label %114

110:                                              ; preds = %99
  %111 = landingpad { ptr, i32 }
          cleanup
  %112 = extractvalue { ptr, i32 } %111, 0
  store ptr %112, ptr %11, align 8
  %113 = extractvalue { ptr, i32 } %111, 1
  store i32 %113, ptr %12, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %17) #11
  br label %114

114:                                              ; preds = %110, %106
  call void @llvm.lifetime.end.p0(i64 32, ptr %17) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %16) #11
  br label %350

115:                                              ; preds = %94
  call void @llvm.lifetime.start.p0(i64 12, ptr %18) #11
  call void @llvm.lifetime.start.p0(i64 16, ptr %19) #11
  %116 = getelementptr inbounds %"struct.System::OperationContext", ptr %19, i32 0, i32 1
  store i8 0, ptr %116, align 8, !tbaa !18
  %117 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 0
  %118 = load ptr, ptr %117, align 8, !tbaa !11
  %119 = invoke noundef ptr @_ZNK6System10Dispatcher17getCurrentContextEv(ptr noundef nonnull align 8 dereferenceable(424) %118)
          to label %120 unwind label %132

120:                                              ; preds = %115
  %121 = getelementptr inbounds %"struct.System::OperationContext", ptr %19, i32 0, i32 0
  store ptr %119, ptr %121, align 8, !tbaa !21
  %122 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 2
  %123 = getelementptr inbounds %"struct.System::ContextPair", ptr %122, i32 0, i32 1
  store ptr %19, ptr %123, align 8, !tbaa !15
  %124 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 2
  %125 = getelementptr inbounds %struct.epoll_event, ptr %18, i32 0, i32 1
  store ptr %124, ptr %125, align 1, !tbaa !22
  %126 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 2
  %127 = getelementptr inbounds %"struct.System::ContextPair", ptr %126, i32 0, i32 0
  %128 = load ptr, ptr %127, align 8, !tbaa !23
  %129 = icmp ne ptr %128, null
  br i1 %129, label %130, label %136

130:                                              ; preds = %120
  %131 = getelementptr inbounds %struct.epoll_event, ptr %18, i32 0, i32 0
  store i32 1073741829, ptr %131, align 1, !tbaa !24
  br label %138

132:                                              ; preds = %274, %210, %187, %170, %165, %138, %115
  %133 = landingpad { ptr, i32 }
          cleanup
  %134 = extractvalue { ptr, i32 } %133, 0
  store ptr %134, ptr %11, align 8
  %135 = extractvalue { ptr, i32 } %133, 1
  store i32 %135, ptr %12, align 4
  br label %323

136:                                              ; preds = %120
  %137 = getelementptr inbounds %struct.epoll_event, ptr %18, i32 0, i32 0
  store i32 1073741828, ptr %137, align 1, !tbaa !24
  br label %138

138:                                              ; preds = %136, %130
  %139 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 0
  %140 = load ptr, ptr %139, align 8, !tbaa !11
  %141 = invoke noundef i32 @_ZNK6System10Dispatcher8getEpollEv(ptr noundef nonnull align 8 dereferenceable(424) %140)
          to label %142 unwind label %132

142:                                              ; preds = %138
  %143 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 1
  %144 = load i32, ptr %143, align 8, !tbaa !16
  %145 = call i32 @epoll_ctl(i32 noundef %141, i32 noundef 3, i32 noundef %144, ptr noundef %18) #11
  %146 = icmp eq i32 %145, -1
  br i1 %146, label %147, label %160

147:                                              ; preds = %142
  call void @llvm.lifetime.start.p0(i64 32, ptr %20) #11
  call void @llvm.lifetime.start.p0(i64 32, ptr %21) #11
  invoke void @_ZN6System16lastErrorMessageB5cxx11Ev(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %21)
          to label %148 unwind label %151

148:                                              ; preds = %147
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %20, ptr noundef @.str.9, ptr noundef nonnull align 8 dereferenceable(32) %21)
          to label %149 unwind label %155

149:                                              ; preds = %148
  %150 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_(ptr noundef nonnull align 8 dereferenceable(32) %8, ptr noundef nonnull align 8 dereferenceable(32) %20) #11
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %20) #11
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %21) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %21) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %20) #11
  br label %319

151:                                              ; preds = %147
  %152 = landingpad { ptr, i32 }
          cleanup
  %153 = extractvalue { ptr, i32 } %152, 0
  store ptr %153, ptr %11, align 8
  %154 = extractvalue { ptr, i32 } %152, 1
  store i32 %154, ptr %12, align 4
  br label %159

155:                                              ; preds = %148
  %156 = landingpad { ptr, i32 }
          cleanup
  %157 = extractvalue { ptr, i32 } %156, 0
  store ptr %157, ptr %11, align 8
  %158 = extractvalue { ptr, i32 } %156, 1
  store i32 %158, ptr %12, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %21) #11
  br label %159

159:                                              ; preds = %155, %151
  call void @llvm.lifetime.end.p0(i64 32, ptr %21) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %20) #11
  br label %323

160:                                              ; preds = %142
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #11
  %161 = getelementptr inbounds %class.anon.10, ptr %22, i32 0, i32 0
  store ptr %33, ptr %161, align 8, !tbaa !26
  %162 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 0
  %163 = load ptr, ptr %162, align 8, !tbaa !11
  %164 = invoke noundef ptr @_ZNK6System10Dispatcher17getCurrentContextEv(ptr noundef nonnull align 8 dereferenceable(424) %163)
          to label %165 unwind label %182

165:                                              ; preds = %160
  %166 = getelementptr inbounds %"struct.System::NativeContext", ptr %164, i32 0, i32 9
  %167 = call noundef nonnull align 8 dereferenceable(32) ptr @"_ZNSt8functionIFvvEEaSIZN6System13TcpConnection5writeEPKhmE3$_0EENSt9enable_ifIXsrNS1_9_CallableIT_NS8_IXntsr7is_sameINSt9remove_cvINSt16remove_referenceISA_E4typeEE4typeES1_EE5valueESt5decayISA_EE4type4typeESt15__invoke_resultIRSL_JEEEE5valueERS1_E4typeEOSA_"(ptr noundef nonnull align 8 dereferenceable(32) %166, ptr noundef nonnull align 8 dereferenceable(8) %22) #11
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #11
  %168 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 0
  %169 = load ptr, ptr %168, align 8, !tbaa !11
  invoke void @_ZN6System10Dispatcher8dispatchEv(ptr noundef nonnull align 8 dereferenceable(424) %169)
          to label %170 unwind label %132

170:                                              ; preds = %165
  %171 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 0
  %172 = load ptr, ptr %171, align 8, !tbaa !11
  %173 = invoke noundef ptr @_ZNK6System10Dispatcher17getCurrentContextEv(ptr noundef nonnull align 8 dereferenceable(424) %172)
          to label %174 unwind label %132

174:                                              ; preds = %170
  %175 = getelementptr inbounds %"struct.System::NativeContext", ptr %173, i32 0, i32 9
  %176 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt8functionIFvvEEaSEDn(ptr noundef nonnull align 8 dereferenceable(32) %175, ptr null) #11
  %177 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 0
  %178 = load ptr, ptr %177, align 8, !tbaa !11
  %179 = icmp ne ptr %178, null
  br i1 %179, label %180, label %181

180:                                              ; preds = %174
  br label %187

181:                                              ; preds = %174
  call void @__assert_fail(ptr noundef @.str.7, ptr noundef @.str.1, i32 noundef 217, ptr noundef @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #10
  unreachable

182:                                              ; preds = %160
  %183 = landingpad { ptr, i32 }
          cleanup
  %184 = extractvalue { ptr, i32 } %183, 0
  store ptr %184, ptr %11, align 8
  %185 = extractvalue { ptr, i32 } %183, 1
  store i32 %185, ptr %12, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #11
  br label %323

186:                                              ; No predecessors!
  br label %187

187:                                              ; preds = %186, %180
  %188 = getelementptr inbounds %"struct.System::OperationContext", ptr %19, i32 0, i32 0
  %189 = load ptr, ptr %188, align 8, !tbaa !21
  %190 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 0
  %191 = load ptr, ptr %190, align 8, !tbaa !11
  %192 = invoke noundef ptr @_ZNK6System10Dispatcher17getCurrentContextEv(ptr noundef nonnull align 8 dereferenceable(424) %191)
          to label %193 unwind label %132

193:                                              ; preds = %187
  %194 = icmp eq ptr %189, %192
  br i1 %194, label %195, label %196

195:                                              ; preds = %193
  br label %198

196:                                              ; preds = %193
  call void @__assert_fail(ptr noundef @.str.10, ptr noundef @.str.1, i32 noundef 218, ptr noundef @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #10
  unreachable

197:                                              ; No predecessors!
  br label %198

198:                                              ; preds = %197, %195
  %199 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 2
  %200 = getelementptr inbounds %"struct.System::ContextPair", ptr %199, i32 0, i32 1
  %201 = load ptr, ptr %200, align 8, !tbaa !15
  %202 = icmp eq ptr %201, %19
  br i1 %202, label %203, label %204

203:                                              ; preds = %198
  br label %206

204:                                              ; preds = %198
  call void @__assert_fail(ptr noundef @.str.17, ptr noundef @.str.1, i32 noundef 219, ptr noundef @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #10
  unreachable

205:                                              ; No predecessors!
  br label %206

206:                                              ; preds = %205, %203
  %207 = getelementptr inbounds %"struct.System::OperationContext", ptr %19, i32 0, i32 1
  %208 = load i8, ptr %207, align 8, !tbaa !18, !range !28, !noundef !29
  %209 = trunc i8 %208 to i1
  br i1 %209, label %210, label %214

210:                                              ; preds = %206
  %211 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 2
  %212 = getelementptr inbounds %"struct.System::ContextPair", ptr %211, i32 0, i32 1
  store ptr null, ptr %212, align 8, !tbaa !15
  %213 = call ptr @__cxa_allocate_exception(i64 8) #11
  call void @llvm.memset.p0.i64(ptr align 16 %213, i8 0, i64 8, i1 false)
  call void @_ZN6System20InterruptedExceptionC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %213) #11
  invoke void @__cxa_throw(ptr %213, ptr @_ZTIN6System20InterruptedExceptionE, ptr @_ZNSt9exceptionD2Ev) #12
          to label %359 unwind label %132

214:                                              ; preds = %206
  %215 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 2
  %216 = getelementptr inbounds %"struct.System::ContextPair", ptr %215, i32 0, i32 1
  store ptr null, ptr %216, align 8, !tbaa !15
  %217 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 2
  %218 = getelementptr inbounds %"struct.System::ContextPair", ptr %217, i32 0, i32 0
  %219 = load ptr, ptr %218, align 8, !tbaa !23
  %220 = icmp ne ptr %219, null
  br i1 %220, label %221, label %267

221:                                              ; preds = %214
  call void @llvm.lifetime.start.p0(i64 12, ptr %23) #11
  %222 = getelementptr inbounds %struct.epoll_event, ptr %23, i32 0, i32 0
  store i32 1073741825, ptr %222, align 1, !tbaa !24
  %223 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 2
  %224 = getelementptr inbounds %struct.epoll_event, ptr %23, i32 0, i32 1
  store ptr %223, ptr %224, align 1, !tbaa !22
  %225 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 0
  %226 = load ptr, ptr %225, align 8, !tbaa !11
  %227 = invoke noundef i32 @_ZNK6System10Dispatcher8getEpollEv(ptr noundef nonnull align 8 dereferenceable(424) %226)
          to label %228 unwind label %240

228:                                              ; preds = %221
  %229 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 1
  %230 = load i32, ptr %229, align 8, !tbaa !16
  %231 = call i32 @epoll_ctl(i32 noundef %227, i32 noundef 3, i32 noundef %230, ptr noundef %23) #11
  %232 = icmp eq i32 %231, -1
  br i1 %232, label %233, label %265

233:                                              ; preds = %228
  call void @llvm.lifetime.start.p0(i64 32, ptr %24) #11
  call void @llvm.lifetime.start.p0(i64 32, ptr %25) #11
  invoke void @_ZN6System16lastErrorMessageB5cxx11Ev(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %25)
          to label %234 unwind label %244

234:                                              ; preds = %233
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %24, ptr noundef @.str.9, ptr noundef nonnull align 8 dereferenceable(32) %25)
          to label %235 unwind label %248

235:                                              ; preds = %234
  %236 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_(ptr noundef nonnull align 8 dereferenceable(32) %8, ptr noundef nonnull align 8 dereferenceable(32) %24) #11
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %24) #11
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %25) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %25) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %24) #11
  store i1 true, ptr %27, align 1
  %237 = call ptr @__cxa_allocate_exception(i64 16) #11
  call void @llvm.lifetime.start.p0(i64 32, ptr %26) #11
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %26, ptr noundef @.str.18, ptr noundef nonnull align 8 dereferenceable(32) %8)
          to label %238 unwind label %253

238:                                              ; preds = %235
  invoke void @_ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(16) %237, ptr noundef nonnull align 8 dereferenceable(32) %26)
          to label %239 unwind label %257

239:                                              ; preds = %238
  store i1 false, ptr %27, align 1
  invoke void @__cxa_throw(ptr %237, ptr @_ZTISt13runtime_error, ptr @_ZNSt13runtime_errorD1Ev) #12
          to label %359 unwind label %257

240:                                              ; preds = %221
  %241 = landingpad { ptr, i32 }
          cleanup
  %242 = extractvalue { ptr, i32 } %241, 0
  store ptr %242, ptr %11, align 8
  %243 = extractvalue { ptr, i32 } %241, 1
  store i32 %243, ptr %12, align 4
  br label %266

244:                                              ; preds = %233
  %245 = landingpad { ptr, i32 }
          cleanup
  %246 = extractvalue { ptr, i32 } %245, 0
  store ptr %246, ptr %11, align 8
  %247 = extractvalue { ptr, i32 } %245, 1
  store i32 %247, ptr %12, align 4
  br label %252

248:                                              ; preds = %234
  %249 = landingpad { ptr, i32 }
          cleanup
  %250 = extractvalue { ptr, i32 } %249, 0
  store ptr %250, ptr %11, align 8
  %251 = extractvalue { ptr, i32 } %249, 1
  store i32 %251, ptr %12, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %25) #11
  br label %252

252:                                              ; preds = %248, %244
  call void @llvm.lifetime.end.p0(i64 32, ptr %25) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %24) #11
  br label %266

253:                                              ; preds = %235
  %254 = landingpad { ptr, i32 }
          cleanup
  %255 = extractvalue { ptr, i32 } %254, 0
  store ptr %255, ptr %11, align 8
  %256 = extractvalue { ptr, i32 } %254, 1
  store i32 %256, ptr %12, align 4
  br label %261

257:                                              ; preds = %239, %238
  %258 = landingpad { ptr, i32 }
          cleanup
  %259 = extractvalue { ptr, i32 } %258, 0
  store ptr %259, ptr %11, align 8
  %260 = extractvalue { ptr, i32 } %258, 1
  store i32 %260, ptr %12, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %26) #11
  br label %261

261:                                              ; preds = %257, %253
  call void @llvm.lifetime.end.p0(i64 32, ptr %26) #11
  %262 = load i1, ptr %27, align 1
  br i1 %262, label %263, label %264

263:                                              ; preds = %261
  call void @__cxa_free_exception(ptr %237) #11
  br label %264

264:                                              ; preds = %263, %261
  br label %266

265:                                              ; preds = %228
  call void @llvm.lifetime.end.p0(i64 12, ptr %23) #11
  br label %267

266:                                              ; preds = %264, %252, %240
  call void @llvm.lifetime.end.p0(i64 12, ptr %23) #11
  br label %323

267:                                              ; preds = %265, %214
  %268 = getelementptr inbounds %"struct.System::OperationContext", ptr %19, i32 0, i32 2
  %269 = load i32, ptr %268, align 4, !tbaa !30
  %270 = and i32 %269, 24
  %271 = icmp ne i32 %270, 0
  br i1 %271, label %272, label %279

272:                                              ; preds = %267
  %273 = call ptr @__cxa_allocate_exception(i64 16) #11
  invoke void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16) %273, ptr noundef @.str.19)
          to label %274 unwind label %275

274:                                              ; preds = %272
  invoke void @__cxa_throw(ptr %273, ptr @_ZTISt13runtime_error, ptr @_ZNSt13runtime_errorD1Ev) #12
          to label %359 unwind label %132

275:                                              ; preds = %272
  %276 = landingpad { ptr, i32 }
          cleanup
  %277 = extractvalue { ptr, i32 } %276, 0
  store ptr %277, ptr %11, align 8
  %278 = extractvalue { ptr, i32 } %276, 1
  store i32 %278, ptr %12, align 4
  call void @__cxa_free_exception(ptr %273) #11
  br label %323

279:                                              ; preds = %267
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #11
  %280 = getelementptr inbounds %"class.System::TcpConnection", ptr %33, i32 0, i32 1
  %281 = load i32, ptr %280, align 8, !tbaa !16
  %282 = load ptr, ptr %6, align 8, !tbaa !5
  %283 = load i64, ptr %7, align 8, !tbaa !9
  %284 = invoke i64 @send(i32 noundef %281, ptr noundef %282, i64 noundef %283, i32 noundef 0)
          to label %285 unwind label %292

285:                                              ; preds = %279
  store i64 %284, ptr %28, align 8, !tbaa !9
  %286 = load i64, ptr %28, align 8, !tbaa !9
  %287 = icmp eq i64 %286, -1
  br i1 %287, label %288, label %305

288:                                              ; preds = %285
  call void @llvm.lifetime.start.p0(i64 32, ptr %29) #11
  call void @llvm.lifetime.start.p0(i64 32, ptr %30) #11
  invoke void @_ZN6System16lastErrorMessageB5cxx11Ev(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %30)
          to label %289 unwind label %296

289:                                              ; preds = %288
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %29, ptr noundef @.str.16, ptr noundef nonnull align 8 dereferenceable(32) %30)
          to label %290 unwind label %300

290:                                              ; preds = %289
  %291 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_(ptr noundef nonnull align 8 dereferenceable(32) %8, ptr noundef nonnull align 8 dereferenceable(32) %29) #11
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %29) #11
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %30) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %30) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %29) #11
  br label %314

292:                                              ; preds = %279
  %293 = landingpad { ptr, i32 }
          cleanup
  %294 = extractvalue { ptr, i32 } %293, 0
  store ptr %294, ptr %11, align 8
  %295 = extractvalue { ptr, i32 } %293, 1
  store i32 %295, ptr %12, align 4
  br label %318

296:                                              ; preds = %288
  %297 = landingpad { ptr, i32 }
          cleanup
  %298 = extractvalue { ptr, i32 } %297, 0
  store ptr %298, ptr %11, align 8
  %299 = extractvalue { ptr, i32 } %297, 1
  store i32 %299, ptr %12, align 4
  br label %304

300:                                              ; preds = %289
  %301 = landingpad { ptr, i32 }
          cleanup
  %302 = extractvalue { ptr, i32 } %301, 0
  store ptr %302, ptr %11, align 8
  %303 = extractvalue { ptr, i32 } %301, 1
  store i32 %303, ptr %12, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %30) #11
  br label %304

304:                                              ; preds = %300, %296
  call void @llvm.lifetime.end.p0(i64 32, ptr %30) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %29) #11
  br label %318

305:                                              ; preds = %285
  %306 = load i64, ptr %28, align 8, !tbaa !9
  %307 = load i64, ptr %7, align 8, !tbaa !9
  %308 = icmp sle i64 %306, %307
  br i1 %308, label %309, label %310

309:                                              ; preds = %305
  br label %312

310:                                              ; preds = %305
  call void @__assert_fail(ptr noundef @.str.13, ptr noundef @.str.1, i32 noundef 246, ptr noundef @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #10
  unreachable

311:                                              ; No predecessors!
  br label %312

312:                                              ; preds = %311, %309
  %313 = load i64, ptr %28, align 8, !tbaa !9
  store i64 %313, ptr %4, align 8
  store i32 1, ptr %14, align 4
  br label %315

314:                                              ; preds = %290
  store i32 0, ptr %14, align 4
  br label %315

315:                                              ; preds = %314, %312
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #11
  %316 = load i32, ptr %14, align 4
  switch i32 %316, label %320 [
    i32 0, label %317
  ]

317:                                              ; preds = %315
  br label %319

318:                                              ; preds = %304, %292
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #11
  br label %323

319:                                              ; preds = %317, %149
  store i32 0, ptr %14, align 4
  br label %320

320:                                              ; preds = %319, %315
  call void @llvm.lifetime.end.p0(i64 16, ptr %19) #11
  call void @llvm.lifetime.end.p0(i64 12, ptr %18) #11
  %321 = load i32, ptr %14, align 4
  switch i32 %321, label %349 [
    i32 0, label %322
  ]

322:                                              ; preds = %320
  br label %324

323:                                              ; preds = %318, %275, %266, %182, %159, %132
  call void @llvm.lifetime.end.p0(i64 16, ptr %19) #11
  call void @llvm.lifetime.end.p0(i64 12, ptr %18) #11
  br label %350

324:                                              ; preds = %322, %100
  store i1 true, ptr %32, align 1
  %325 = call ptr @__cxa_allocate_exception(i64 16) #11
  call void @llvm.lifetime.start.p0(i64 32, ptr %31) #11
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %31, ptr noundef @.str.18, ptr noundef nonnull align 8 dereferenceable(32) %8)
          to label %326 unwind label %328

326:                                              ; preds = %324
  invoke void @_ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(16) %325, ptr noundef nonnull align 8 dereferenceable(32) %31)
          to label %327 unwind label %332

327:                                              ; preds = %326
  store i1 false, ptr %32, align 1
  invoke void @__cxa_throw(ptr %325, ptr @_ZTISt13runtime_error, ptr @_ZNSt13runtime_errorD1Ev) #12
          to label %359 unwind label %332

328:                                              ; preds = %324
  %329 = landingpad { ptr, i32 }
          cleanup
  %330 = extractvalue { ptr, i32 } %329, 0
  store ptr %330, ptr %11, align 8
  %331 = extractvalue { ptr, i32 } %329, 1
  store i32 %331, ptr %12, align 4
  br label %336

332:                                              ; preds = %327, %326
  %333 = landingpad { ptr, i32 }
          cleanup
  %334 = extractvalue { ptr, i32 } %333, 0
  store ptr %334, ptr %11, align 8
  %335 = extractvalue { ptr, i32 } %333, 1
  store i32 %335, ptr %12, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %31) #11
  br label %336

336:                                              ; preds = %332, %328
  call void @llvm.lifetime.end.p0(i64 32, ptr %31) #11
  %337 = load i1, ptr %32, align 1
  br i1 %337, label %338, label %339

338:                                              ; preds = %336
  call void @__cxa_free_exception(ptr %325) #11
  br label %339

339:                                              ; preds = %338, %336
  br label %350

340:                                              ; preds = %91
  %341 = load i64, ptr %15, align 8, !tbaa !9
  %342 = load i64, ptr %7, align 8, !tbaa !9
  %343 = icmp sle i64 %341, %342
  br i1 %343, label %344, label %345

344:                                              ; preds = %340
  br label %347

345:                                              ; preds = %340
  call void @__assert_fail(ptr noundef @.str.13, ptr noundef @.str.1, i32 noundef 255, ptr noundef @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #10
  unreachable

346:                                              ; No predecessors!
  br label %347

347:                                              ; preds = %346, %344
  %348 = load i64, ptr %15, align 8, !tbaa !9
  store i64 %348, ptr %4, align 8
  store i32 1, ptr %14, align 4
  br label %349

349:                                              ; preds = %347, %320
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #11
  br label %351

350:                                              ; preds = %339, %323, %114, %102
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #11
  br label %353

351:                                              ; preds = %349, %84
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %8) #11
  %352 = load i64, ptr %4, align 8
  ret i64 %352

353:                                              ; preds = %350, %83
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #11
  call void @llvm.lifetime.end.p0(i64 32, ptr %8) #11
  br label %354

354:                                              ; preds = %353
  %355 = load ptr, ptr %11, align 8
  %356 = load i32, ptr %12, align 4
  %357 = insertvalue { ptr, i32 } poison, ptr %355, 0
  %358 = insertvalue { ptr, i32 } %357, i32 %356, 1
  resume { ptr, i32 } %358

359:                                              ; preds = %327, %274, %239, %210, %66
  unreachable
}

; Function Attrs: nounwind
declare i32 @shutdown(i32 noundef, i32 noundef) #4

declare i64 @send(i32 noundef, ptr noundef, i64 noundef, i32 noundef) #3

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef nonnull align 8 dereferenceable(32) ptr @"_ZNSt8functionIFvvEEaSIZN6System13TcpConnection5writeEPKhmE3$_0EENSt9enable_ifIXsrNS1_9_CallableIT_NS8_IXntsr7is_sameINSt9remove_cvINSt16remove_referenceISA_E4typeEE4typeES1_EE5valueESt5decayISA_EE4type4typeESt15__invoke_resultIRSL_JEEEE5valueERS1_E4typeEOSA_"(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 8 dereferenceable(8)) #5 align 2

attributes #0 = { noreturn 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { "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 "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 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #7 = { 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 #8 = { nounwind willreturn memory(none) "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 #9 = { 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 #10 = { noreturn nounwind }
attributes #11 = { nounwind }
attributes #12 = { noreturn }
attributes #13 = { nounwind willreturn memory(none) }

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !6, i64 0}
!12 = !{!"_ZTSN6System13TcpConnectionE", !6, i64 0, !13, i64 8, !14, i64 16}
!13 = !{!"int", !7, i64 0}
!14 = !{!"_ZTSN6System11ContextPairE", !6, i64 0, !6, i64 8}
!15 = !{!12, !6, i64 24}
!16 = !{!12, !13, i64 8}
!17 = !{!13, !13, i64 0}
!18 = !{!19, !20, i64 8}
!19 = !{!"_ZTSN6System16OperationContextE", !6, i64 0, !20, i64 8, !13, i64 12}
!20 = !{!"bool", !7, i64 0}
!21 = !{!19, !6, i64 0}
!22 = !{!7, !7, i64 0}
!23 = !{!12, !6, i64 16}
!24 = !{!25, !13, i64 0}
!25 = !{!"_ZTS11epoll_event", !13, i64 0, !7, i64 4}
!26 = !{!27, !6, i64 0}
!27 = !{!"_ZTSZN6System13TcpConnection5writeEPKhmE3$_0", !6, i64 0}
!28 = !{i8 0, i8 2}
!29 = !{}
!30 = !{!19, !13, i64 12}


; 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.0 }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon.0 = type { i64, [8 x i8] }
%struct.epoll_event = type <{ i32, %union.epoll_data }>
%union.epoll_data = type { ptr }
%"struct.System::OperationContext" = type { ptr, i8, i32 }
%class.anon.10 = type { ptr }

@.str.1 = external hidden unnamed_addr constant [93 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [36 x i8], align 1
@_ZTISt13runtime_error = external constant ptr
@.str.7 = external hidden unnamed_addr constant [22 x i8], align 1
@_ZTIN6System20InterruptedExceptionE = external dso_local constant { ptr, ptr, ptr }, align 8
@.str.9 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [60 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [42 x i8], align 1
@__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm = external hidden unnamed_addr constant [66 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [40 x i8], align 1
@.str.16 = external hidden unnamed_addr constant [14 x i8], align 1
@.str.17 = external hidden unnamed_addr constant [46 x i8], align 1
@.str.18 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [58 x i8], align 1

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #0

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

declare i32 @__gxx_personality_v0(...)

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

declare ptr @__cxa_allocate_exception(i64) local_unnamed_addr

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

declare void @_ZN6System16lastErrorMessageB5cxx11Ev(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8) local_unnamed_addr #3

declare void @_ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #3

; Function Attrs: nounwind
declare void @_ZNSt13runtime_errorD1Ev(ptr noundef nonnull align 8 dereferenceable(16)) unnamed_addr #4

declare void @__cxa_throw(ptr, ptr, ptr) local_unnamed_addr

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

declare void @__cxa_free_exception(ptr) local_unnamed_addr

declare noundef zeroext i1 @_ZN6System10Dispatcher11interruptedEv(ptr noundef nonnull align 8 dereferenceable(424)) local_unnamed_addr #3

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

; Function Attrs: nounwind
declare void @_ZNSt9exceptionD2Ev(ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #4

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

; Function Attrs: mustprogress nofree nosync nounwind willreturn memory(none)
declare ptr @__errno_location() local_unnamed_addr #7

; Function Attrs: mustprogress nounwind uwtable
declare noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #5 align 2

declare noundef ptr @_ZNK6System10Dispatcher17getCurrentContextEv(ptr noundef nonnull align 8 dereferenceable(424)) local_unnamed_addr #3

; Function Attrs: nounwind
declare i32 @epoll_ctl(i32 noundef, i32 noundef, i32 noundef, ptr noundef) local_unnamed_addr #4

declare noundef i32 @_ZNK6System10Dispatcher8getEpollEv(ptr noundef nonnull align 8 dereferenceable(424)) local_unnamed_addr #3

declare void @_ZN6System10Dispatcher8dispatchEv(ptr noundef nonnull align 8 dereferenceable(424)) local_unnamed_addr #3

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

declare void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef) unnamed_addr #3

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

; Function Attrs: mustprogress uwtable
define dso_local noundef i64 @_ZN6System13TcpConnection5writeEPKhm(ptr noundef nonnull align 8 dereferenceable(32) %0, ptr noundef %1, i64 noundef %2) local_unnamed_addr #8 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca %"class.std::__cxx11::basic_string", align 8
  %5 = alloca %"class.std::__cxx11::basic_string", align 8
  %6 = alloca %"class.std::__cxx11::basic_string", align 8
  %7 = alloca %"class.std::__cxx11::basic_string", align 8
  %8 = alloca %"class.std::__cxx11::basic_string", align 8
  %9 = alloca %struct.epoll_event, align 4
  %10 = alloca %"struct.System::OperationContext", align 8
  %11 = alloca %"class.std::__cxx11::basic_string", align 8
  %12 = alloca %"class.std::__cxx11::basic_string", align 8
  %13 = alloca %class.anon.10, align 8
  %14 = alloca %struct.epoll_event, align 4
  %15 = alloca %"class.std::__cxx11::basic_string", align 8
  %16 = alloca %"class.std::__cxx11::basic_string", align 8
  %17 = alloca %"class.std::__cxx11::basic_string", align 8
  %18 = alloca %"class.std::__cxx11::basic_string", align 8
  %19 = alloca %"class.std::__cxx11::basic_string", align 8
  %20 = alloca %"class.std::__cxx11::basic_string", align 8
  %21 = load ptr, ptr %0, align 8, !tbaa !5
  %.not = icmp eq ptr %21, null
  br i1 %.not, label %22, label %23

22:                                               ; preds = %3
  tail call void @__assert_fail(ptr noundef nonnull @.str.7, ptr noundef nonnull @.str.1, i32 noundef 164, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #9
  unreachable

23:                                               ; preds = %3
  %24 = getelementptr inbounds i8, ptr %0, i64 16
  %25 = getelementptr inbounds i8, ptr %0, i64 24
  %26 = load ptr, ptr %25, align 8, !tbaa !12
  %27 = icmp eq ptr %26, null
  br i1 %27, label %29, label %28

28:                                               ; preds = %23
  tail call void @__assert_fail(ptr noundef nonnull @.str.4, ptr noundef nonnull @.str.1, i32 noundef 165, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #9
  unreachable

29:                                               ; preds = %23
  %30 = tail call noundef zeroext i1 @_ZN6System10Dispatcher11interruptedEv(ptr noundef nonnull align 8 dereferenceable(424) %21)
  br i1 %30, label %31, label %33

31:                                               ; preds = %29
  %32 = tail call ptr @__cxa_allocate_exception(i64 8) #10
  store i64 0, ptr %32, align 16
  tail call void @_ZN6System20InterruptedExceptionC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %32) #10
  tail call void @__cxa_throw(ptr nonnull %32, ptr nonnull @_ZTIN6System20InterruptedExceptionE, ptr nonnull @_ZNSt9exceptionD2Ev) #11
  unreachable

33:                                               ; preds = %29
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %4) #10
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #10
  %34 = icmp eq i64 %2, 0
  %35 = getelementptr inbounds i8, ptr %0, i64 8
  %36 = load i32, ptr %35, align 8, !tbaa !13
  br i1 %34, label %37, label %50

37:                                               ; preds = %33
  %38 = call i32 @shutdown(i32 noundef %36, i32 noundef 1) #10
  %39 = icmp eq i32 %38, -1
  br i1 %39, label %40, label %197

40:                                               ; preds = %37
  %41 = call ptr @__cxa_allocate_exception(i64 16) #10
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %5) #10
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %6) #10
  invoke void @_ZN6System16lastErrorMessageB5cxx11Ev(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %6)
          to label %42 unwind label %.thread

42:                                               ; preds = %40
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %5, ptr noundef nonnull @.str.15, ptr noundef nonnull align 8 dereferenceable(32) %6)
          to label %43 unwind label %.thread84

43:                                               ; preds = %42
  invoke void @_ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(16) %41, ptr noundef nonnull align 8 dereferenceable(32) %5)
          to label %44 unwind label %47

44:                                               ; preds = %43
  invoke void @__cxa_throw(ptr nonnull %41, ptr nonnull @_ZTISt13runtime_error, ptr nonnull @_ZNSt13runtime_errorD1Ev) #11
          to label %199 unwind label %47

.thread:                                          ; preds = %40
  %45 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #10
  br label %49

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

47:                                               ; preds = %43, %44
  %.033 = phi i1 [ false, %44 ], [ true, %43 ]
  %48 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5) #10
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %6) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %6) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #10
  br i1 %.033, label %49, label %198

49:                                               ; preds = %.thread84, %.thread, %47
  %.pn77.pn83 = phi { ptr, i32 } [ %45, %.thread ], [ %48, %47 ], [ %46, %.thread84 ]
  call void @__cxa_free_exception(ptr %41) #10
  br label %198

50:                                               ; preds = %33
  %51 = invoke i64 @send(i32 noundef %36, ptr noundef %1, i64 noundef %2, i32 noundef 16384)
          to label %52 unwind label %61

52:                                               ; preds = %50
  %53 = icmp eq i64 %51, -1
  br i1 %53, label %54, label %195

54:                                               ; preds = %52
  %55 = tail call ptr @__errno_location() #12
  %56 = load i32, ptr %55, align 4, !tbaa !14
  %.not56 = icmp eq i32 %56, 11
  br i1 %.not56, label %68, label %57

57:                                               ; preds = %54
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %7) #10
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %8) #10
  invoke void @_ZN6System16lastErrorMessageB5cxx11Ev(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %8)
          to label %58 unwind label %63

58:                                               ; preds = %57
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %7, ptr noundef nonnull @.str.16, ptr noundef nonnull align 8 dereferenceable(32) %8)
          to label %59 unwind label %65

59:                                               ; preds = %58
  %60 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_(ptr noundef nonnull align 8 dereferenceable(32) %4, ptr noundef nonnull align 8 dereferenceable(32) %7) #10
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %7) #10
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %8) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %7) #10
  br label %186

61:                                               ; preds = %50
  %62 = landingpad { ptr, i32 }
          cleanup
  br label %198

63:                                               ; preds = %57
  %64 = landingpad { ptr, i32 }
          cleanup
  br label %67

65:                                               ; preds = %58
  %66 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #10
  br label %67

67:                                               ; preds = %65, %63
  %.pn72 = phi { ptr, i32 } [ %66, %65 ], [ %64, %63 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %8) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %7) #10
  br label %198

68:                                               ; preds = %54
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %9) #10
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %10) #10
  %69 = getelementptr inbounds i8, ptr %10, i64 8
  store i8 0, ptr %69, align 8, !tbaa !15
  %70 = load ptr, ptr %0, align 8, !tbaa !5
  %71 = invoke noundef ptr @_ZNK6System10Dispatcher17getCurrentContextEv(ptr noundef nonnull align 8 dereferenceable(424) %70)
          to label %72 unwind label %77

72:                                               ; preds = %68
  store ptr %71, ptr %10, align 8, !tbaa !18
  store ptr %10, ptr %25, align 8, !tbaa !12
  %73 = getelementptr inbounds i8, ptr %9, i64 4
  store ptr %24, ptr %73, align 4, !tbaa !19
  %74 = load ptr, ptr %24, align 8, !tbaa !20
  %.not57 = icmp eq ptr %74, null
  %. = select i1 %.not57, i32 1073741828, i32 1073741829
  store i32 %., ptr %9, align 4, !tbaa !21
  %75 = load ptr, ptr %0, align 8, !tbaa !5
  %76 = invoke noundef i32 @_ZNK6System10Dispatcher8getEpollEv(ptr noundef nonnull align 8 dereferenceable(424) %75)
          to label %79 unwind label %77

77:                                               ; preds = %.invoke, %109, %99, %95, %72, %68
  %78 = landingpad { ptr, i32 }
          cleanup
  br label %185

79:                                               ; preds = %72
  %80 = load i32, ptr %35, align 8, !tbaa !13
  %81 = call i32 @epoll_ctl(i32 noundef %76, i32 noundef 3, i32 noundef %80, ptr noundef nonnull %9) #10
  %82 = icmp eq i32 %81, -1
  br i1 %82, label %83, label %92

83:                                               ; preds = %79
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %11) #10
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %12) #10
  invoke void @_ZN6System16lastErrorMessageB5cxx11Ev(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %12)
          to label %84 unwind label %87

84:                                               ; preds = %83
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %11, ptr noundef nonnull @.str.9, ptr noundef nonnull align 8 dereferenceable(32) %12)
          to label %85 unwind label %89

85:                                               ; preds = %84
  %86 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_(ptr noundef nonnull align 8 dereferenceable(32) %4, ptr noundef nonnull align 8 dereferenceable(32) %11) #10
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %11) #10
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %12) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %12) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %11) #10
  br label %.thread93

87:                                               ; preds = %83
  %88 = landingpad { ptr, i32 }
          cleanup
  br label %91

89:                                               ; preds = %84
  %90 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %12) #10
  br label %91

91:                                               ; preds = %89, %87
  %.pn69 = phi { ptr, i32 } [ %90, %89 ], [ %88, %87 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %12) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %11) #10
  br label %185

92:                                               ; preds = %79
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #10
  store ptr %0, ptr %13, align 8, !tbaa !23
  %93 = load ptr, ptr %0, align 8, !tbaa !5
  %94 = invoke noundef ptr @_ZNK6System10Dispatcher17getCurrentContextEv(ptr noundef nonnull align 8 dereferenceable(424) %93)
          to label %95 unwind label %107

95:                                               ; preds = %92
  %96 = getelementptr inbounds i8, ptr %94, i64 88
  %97 = call noundef nonnull align 8 dereferenceable(32) ptr @"_ZNSt8functionIFvvEEaSIZN6System13TcpConnection5writeEPKhmE3$_0EENSt9enable_ifIXsrNS1_9_CallableIT_NS8_IXntsr7is_sameINSt9remove_cvINSt16remove_referenceISA_E4typeEE4typeES1_EE5valueESt5decayISA_EE4type4typeESt15__invoke_resultIRSL_JEEEE5valueERS1_E4typeEOSA_"(ptr noundef nonnull align 8 dereferenceable(32) %96, ptr noundef nonnull align 8 dereferenceable(8) %13) #10
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #10
  %98 = load ptr, ptr %0, align 8, !tbaa !5
  invoke void @_ZN6System10Dispatcher8dispatchEv(ptr noundef nonnull align 8 dereferenceable(424) %98)
          to label %99 unwind label %77

99:                                               ; preds = %95
  %100 = load ptr, ptr %0, align 8, !tbaa !5
  %101 = invoke noundef ptr @_ZNK6System10Dispatcher17getCurrentContextEv(ptr noundef nonnull align 8 dereferenceable(424) %100)
          to label %102 unwind label %77

102:                                              ; preds = %99
  %103 = getelementptr inbounds i8, ptr %101, i64 88
  %104 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt8functionIFvvEEaSEDn(ptr noundef nonnull align 8 dereferenceable(32) %103, ptr null) #10
  %105 = load ptr, ptr %0, align 8, !tbaa !5
  %.not58 = icmp eq ptr %105, null
  br i1 %.not58, label %106, label %109

106:                                              ; preds = %102
  call void @__assert_fail(ptr noundef nonnull @.str.7, ptr noundef nonnull @.str.1, i32 noundef 217, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #9
  unreachable

107:                                              ; preds = %92
  %108 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #10
  br label %185

109:                                              ; preds = %102
  %110 = load ptr, ptr %10, align 8, !tbaa !18
  %111 = invoke noundef ptr @_ZNK6System10Dispatcher17getCurrentContextEv(ptr noundef nonnull align 8 dereferenceable(424) %105)
          to label %112 unwind label %77

112:                                              ; preds = %109
  %113 = icmp eq ptr %110, %111
  br i1 %113, label %115, label %114

114:                                              ; preds = %112
  call void @__assert_fail(ptr noundef nonnull @.str.10, ptr noundef nonnull @.str.1, i32 noundef 218, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #9
  unreachable

115:                                              ; preds = %112
  %116 = load ptr, ptr %25, align 8, !tbaa !12
  %117 = icmp eq ptr %116, %10
  br i1 %117, label %119, label %118

118:                                              ; preds = %115
  call void @__assert_fail(ptr noundef nonnull @.str.17, ptr noundef nonnull @.str.1, i32 noundef 219, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #9
  unreachable

119:                                              ; preds = %115
  %120 = load i8, ptr %69, align 8, !tbaa !15, !range !25, !noundef !26
  %121 = trunc nuw i8 %120 to i1
  store ptr null, ptr %25, align 8, !tbaa !12
  br i1 %121, label %122, label %124

122:                                              ; preds = %119
  %123 = call ptr @__cxa_allocate_exception(i64 8) #10
  store i64 0, ptr %123, align 16
  call void @_ZN6System20InterruptedExceptionC2Ev(ptr noundef nonnull align 8 dereferenceable(8) %123) #10
  br label %.invoke

124:                                              ; preds = %119
  %125 = load ptr, ptr %24, align 8, !tbaa !20
  %.not59 = icmp eq ptr %125, null
  br i1 %.not59, label %155, label %126

126:                                              ; preds = %124
  call void @llvm.lifetime.start.p0(i64 12, ptr nonnull %14) #10
  store i32 1073741825, ptr %14, align 4, !tbaa !21
  %127 = getelementptr inbounds i8, ptr %14, i64 4
  store ptr %24, ptr %127, align 4, !tbaa !19
  %128 = load ptr, ptr %0, align 8, !tbaa !5
  %129 = invoke noundef i32 @_ZNK6System10Dispatcher8getEpollEv(ptr noundef nonnull align 8 dereferenceable(424) %128)
          to label %130 unwind label %142

130:                                              ; preds = %126
  %131 = load i32, ptr %35, align 8, !tbaa !13
  %132 = call i32 @epoll_ctl(i32 noundef %129, i32 noundef 3, i32 noundef %131, ptr noundef nonnull %14) #10
  %133 = icmp eq i32 %132, -1
  br i1 %133, label %134, label %153

134:                                              ; preds = %130
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %15) #10
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %16) #10
  invoke void @_ZN6System16lastErrorMessageB5cxx11Ev(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %16)
          to label %135 unwind label %144

135:                                              ; preds = %134
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %15, ptr noundef nonnull @.str.9, ptr noundef nonnull align 8 dereferenceable(32) %16)
          to label %136 unwind label %146

136:                                              ; preds = %135
  %137 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_(ptr noundef nonnull align 8 dereferenceable(32) %4, ptr noundef nonnull align 8 dereferenceable(32) %15) #10
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %15) #10
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %16) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %16) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %15) #10
  %138 = call ptr @__cxa_allocate_exception(i64 16) #10
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %17) #10
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %17, ptr noundef nonnull @.str.18, ptr noundef nonnull align 8 dereferenceable(32) %4)
          to label %139 unwind label %.thread87

139:                                              ; preds = %136
  invoke void @_ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(16) %138, ptr noundef nonnull align 8 dereferenceable(32) %17)
          to label %141 unwind label %.thread91

.thread91:                                        ; preds = %139
  %140 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %17) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %17) #10
  br label %152

141:                                              ; preds = %139
  invoke void @__cxa_throw(ptr nonnull %138, ptr nonnull @_ZTISt13runtime_error, ptr nonnull @_ZNSt13runtime_errorD1Ev) #11
          to label %199 unwind label %150

142:                                              ; preds = %126
  %143 = landingpad { ptr, i32 }
          cleanup
  br label %154

144:                                              ; preds = %134
  %145 = landingpad { ptr, i32 }
          cleanup
  br label %148

146:                                              ; preds = %135
  %147 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %16) #10
  br label %148

148:                                              ; preds = %146, %144
  %.pn64 = phi { ptr, i32 } [ %147, %146 ], [ %145, %144 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %16) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %15) #10
  br label %154

.thread87:                                        ; preds = %136
  %149 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %17) #10
  br label %152

150:                                              ; preds = %141
  %151 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %17) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %17) #10
  br label %154

152:                                              ; preds = %.thread91, %.thread87
  %.pn6690 = phi { ptr, i32 } [ %149, %.thread87 ], [ %140, %.thread91 ]
  call void @__cxa_free_exception(ptr %138) #10
  br label %154

153:                                              ; preds = %130
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %14) #10
  br label %155

154:                                              ; preds = %150, %152, %148, %142
  %.pn66.pn = phi { ptr, i32 } [ %.pn6690, %152 ], [ %151, %150 ], [ %.pn64, %148 ], [ %143, %142 ]
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %14) #10
  br label %185

155:                                              ; preds = %153, %124
  %156 = getelementptr inbounds i8, ptr %10, i64 12
  %157 = load i32, ptr %156, align 4, !tbaa !27
  %158 = and i32 %157, 24
  %.not60 = icmp eq i32 %158, 0
  br i1 %.not60, label %166, label %159

159:                                              ; preds = %155
  %160 = call ptr @__cxa_allocate_exception(i64 16) #10
  invoke void @_ZNSt13runtime_errorC1EPKc(ptr noundef nonnull align 8 dereferenceable(16) %160, ptr noundef nonnull @.str.19)
          to label %.invoke unwind label %164

.invoke:                                          ; preds = %159, %122
  %161 = phi ptr [ %123, %122 ], [ %160, %159 ]
  %162 = phi ptr [ @_ZTIN6System20InterruptedExceptionE, %122 ], [ @_ZTISt13runtime_error, %159 ]
  %163 = phi ptr [ @_ZNSt9exceptionD2Ev, %122 ], [ @_ZNSt13runtime_errorD1Ev, %159 ]
  invoke void @__cxa_throw(ptr nonnull %161, ptr nonnull %162, ptr nonnull %163) #11
          to label %.cont unwind label %77

.cont:                                            ; preds = %.invoke
  unreachable

164:                                              ; preds = %159
  %165 = landingpad { ptr, i32 }
          cleanup
  call void @__cxa_free_exception(ptr %160) #10
  br label %185

166:                                              ; preds = %155
  %167 = load i32, ptr %35, align 8, !tbaa !13
  %168 = invoke i64 @send(i32 noundef %167, ptr noundef %1, i64 noundef %2, i32 noundef 0)
          to label %169 unwind label %175

169:                                              ; preds = %166
  %170 = icmp eq i64 %168, -1
  br i1 %170, label %171, label %182

171:                                              ; preds = %169
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %18) #10
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %19) #10
  invoke void @_ZN6System16lastErrorMessageB5cxx11Ev(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %19)
          to label %172 unwind label %177

172:                                              ; preds = %171
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_OS8_(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %18, ptr noundef nonnull @.str.16, ptr noundef nonnull align 8 dereferenceable(32) %19)
          to label %173 unwind label %179

173:                                              ; preds = %172
  %174 = call noundef nonnull align 8 dereferenceable(32) ptr @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEaSEOS4_(ptr noundef nonnull align 8 dereferenceable(32) %4, ptr noundef nonnull align 8 dereferenceable(32) %18) #10
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %18) #10
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %19) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %19) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %18) #10
  br label %.thread93

175:                                              ; preds = %166
  %176 = landingpad { ptr, i32 }
          cleanup
  br label %185

177:                                              ; preds = %171
  %178 = landingpad { ptr, i32 }
          cleanup
  br label %181

179:                                              ; preds = %172
  %180 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %19) #10
  br label %181

181:                                              ; preds = %179, %177
  %.pn = phi { ptr, i32 } [ %180, %179 ], [ %178, %177 ]
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %19) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %18) #10
  br label %185

182:                                              ; preds = %169
  %.not61 = icmp sgt i64 %168, %2
  br i1 %.not61, label %183, label %184

183:                                              ; preds = %182
  call void @__assert_fail(ptr noundef nonnull @.str.13, ptr noundef nonnull @.str.1, i32 noundef 246, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #9
  unreachable

.thread93:                                        ; preds = %85, %173
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #10
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %9) #10
  br label %186

184:                                              ; preds = %182
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #10
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %9) #10
  br label %197

185:                                              ; preds = %175, %181, %164, %154, %107, %91, %77
  %.pn69.pn = phi { ptr, i32 } [ %.pn69, %91 ], [ %78, %77 ], [ %.pn66.pn, %154 ], [ %165, %164 ], [ %108, %107 ], [ %.pn, %181 ], [ %176, %175 ]
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %10) #10
  call void @llvm.lifetime.end.p0(i64 12, ptr nonnull %9) #10
  br label %198

186:                                              ; preds = %.thread93, %59
  %187 = call ptr @__cxa_allocate_exception(i64 16) #10
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %20) #10
  invoke void @_ZStplIcSt11char_traitsIcESaIcEENSt7__cxx1112basic_stringIT_T0_T1_EEPKS5_RKS8_(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %20, ptr noundef nonnull @.str.18, ptr noundef nonnull align 8 dereferenceable(32) %4)
          to label %188 unwind label %.thread96

188:                                              ; preds = %186
  invoke void @_ZNSt13runtime_errorC1ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(16) %187, ptr noundef nonnull align 8 dereferenceable(32) %20)
          to label %190 unwind label %.thread100

.thread100:                                       ; preds = %188
  %189 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %20) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %20) #10
  br label %194

190:                                              ; preds = %188
  invoke void @__cxa_throw(ptr nonnull %187, ptr nonnull @_ZTISt13runtime_error, ptr nonnull @_ZNSt13runtime_errorD1Ev) #11
          to label %199 unwind label %192

.thread96:                                        ; preds = %186
  %191 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %20) #10
  br label %194

192:                                              ; preds = %190
  %193 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %20) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %20) #10
  br label %198

194:                                              ; preds = %.thread100, %.thread96
  %.pn7499 = phi { ptr, i32 } [ %191, %.thread96 ], [ %189, %.thread100 ]
  call void @__cxa_free_exception(ptr %187) #10
  br label %198

195:                                              ; preds = %52
  %.not55 = icmp sgt i64 %51, %2
  br i1 %.not55, label %196, label %197

196:                                              ; preds = %195
  call void @__assert_fail(ptr noundef nonnull @.str.13, ptr noundef nonnull @.str.1, i32 noundef 255, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN6System13TcpConnection5writeEPKhm) #9
  unreachable

197:                                              ; preds = %184, %195, %37
  %.4 = phi i64 [ 0, %37 ], [ %168, %184 ], [ %51, %195 ]
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #10
  ret i64 %.4

198:                                              ; preds = %192, %61, %67, %185, %194, %47, %49
  %.pn77.pn.pn = phi { ptr, i32 } [ %.pn77.pn83, %49 ], [ %48, %47 ], [ %.pn7499, %194 ], [ %193, %192 ], [ %.pn72, %67 ], [ %.pn69.pn, %185 ], [ %62, %61 ]
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #10
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #10
  resume { ptr, i32 } %.pn77.pn.pn

199:                                              ; preds = %190, %141, %44
  unreachable
}

; Function Attrs: nounwind
declare i32 @shutdown(i32 noundef, i32 noundef) local_unnamed_addr #4

declare i64 @send(i32 noundef, ptr noundef, i64 noundef, i32 noundef) local_unnamed_addr #3

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef nonnull align 8 dereferenceable(32) ptr @"_ZNSt8functionIFvvEEaSIZN6System13TcpConnection5writeEPKhmE3$_0EENSt9enable_ifIXsrNS1_9_CallableIT_NS8_IXntsr7is_sameINSt9remove_cvINSt16remove_referenceISA_E4typeEE4typeES1_EE5valueESt5decayISA_EE4type4typeESt15__invoke_resultIRSL_JEEEE5valueERS1_E4typeEOSA_"(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #5 align 2

attributes #0 = { noreturn 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 = { "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 "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 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { 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 #7 = { mustprogress nofree nosync nounwind willreturn memory(none) "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 #8 = { 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 #9 = { noreturn nounwind }
attributes #10 = { nounwind }
attributes #11 = { noreturn }
attributes #12 = { nounwind willreturn memory(none) }

!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, !7, i64 0}
!6 = !{!"_ZTSN6System13TcpConnectionE", !7, i64 0, !10, i64 8, !11, i64 16}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"int", !8, i64 0}
!11 = !{!"_ZTSN6System11ContextPairE", !7, i64 0, !7, i64 8}
!12 = !{!6, !7, i64 24}
!13 = !{!6, !10, i64 8}
!14 = !{!10, !10, i64 0}
!15 = !{!16, !17, i64 8}
!16 = !{!"_ZTSN6System16OperationContextE", !7, i64 0, !17, i64 8, !10, i64 12}
!17 = !{!"bool", !8, i64 0}
!18 = !{!16, !7, i64 0}
!19 = !{!8, !8, i64 0}
!20 = !{!6, !7, i64 16}
!21 = !{!22, !10, i64 0}
!22 = !{!"_ZTS11epoll_event", !10, i64 0, !8, i64 4}
!23 = !{!24, !7, i64 0}
!24 = !{!"_ZTSZN6System13TcpConnection5writeEPKhmE3$_0", !7, i64 0}
!25 = !{i8 0, i8 2}
!26 = !{}
!27 = !{!16, !10, i64 12}


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