// File: /workspace/github_cpp_makefile_star2_O1/istellartech[P]OpenTsiolkovsky/src/../lib/csv.h
// Function: io::detail::AsynchronousReader::init(std::unique_ptr<io::ByteSourceBase, std::default_delete<io::ByteSourceBase>>)
void init(std::unique_ptr<ByteSourceBase>arg_byte_source){
                                std::unique_lock<std::mutex>guard(lock);
                                byte_source = std::move(arg_byte_source);
                                desired_byte_count = -1;
                                termination_requested = false;
                                worker = std::thread(
                                        [&]{
                                                std::unique_lock<std::mutex>guard(lock);
                                                try{
                                                        for(;;){
                                                                read_requested_condition.wait(
                                                                        guard, 
                                                                        [&]{
                                                                                return desired_byte_count != -1 || termination_requested;
                                                                        }
                                                                );
                                                                if(termination_requested)
                                                                        return;

                                                                read_byte_count = byte_source->read(buffer, desired_byte_count);
                                                                desired_byte_count = -1;
                                                                if(read_byte_count == 0)
                                                                        break;
                                                                read_finished_condition.notify_one();
                                                        }
                                                }catch(...){
                                                        read_error = std::current_exception();
                                                }
                                                read_finished_condition.notify_one();
                                        }
                                );
                        }

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x30(%rdi), %rax
leaq 0x8(%rsp), %r15
movq %rax, (%r15)
movb $0x0, 0x8(%r15)
movq %r15, %rdi
callq 0x1ed5e
movb $0x1, 0x8(%r15)
movq (%r14), %rax
movq $0x0, (%r14)
movq (%rbx), %rdi
movq %rax, (%rbx)
testq %rdi, %rdi
je 0x1f150
movq (%rdi), %rax
callq *0x10(%rax)
movl $0xffffffff, 0x28(%rbx) # imm = 0xFFFFFFFF
movb $0x0, 0x10(%rbx)
leaq 0x18(%rsp), %rsi
movq %rbx, (%rsi)
movq %rsp, %rdi
callq 0x1f210
cmpq $0x0, 0x8(%rbx)
jne 0x1f18e
movq (%rsp), %rax
movq %rax, 0x8(%rbx)
leaq 0x8(%rsp), %rdi
callq 0x1ed48
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
callq 0x5110
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x1ed48
movq %rbx, %rdi
callq 0x5650