	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ws_openfifo_out
_ws_openfifo_out:                       ## @ws_openfifo_out
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	movq	_wsconfig@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	callq	_ws_setfifo
	movl	(%rbx), %edi
	movq	_O_WRONLY@GOTPCREL(%rip), %rax
	movq	_O_NONBLOCK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	orl	(%rax), %esi
	callq	_open
	movl	%eax, %ebx
	cmpl	$-1, %eax
	je	LBB0_1
## %bb.3:
	testl	%ebx, %ebx
	jns	LBB0_6
## %bb.4:
	movq	_errno@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	jmp	LBB0_5
LBB0_1:
	movq	_errno@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	movq	_ENXIO@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rdi
	jne	LBB0_5
## %bb.2:
	callq	_strerror
	movslq	%eax, %rdi
	callq	_LOG
	movl	$-1, (%r14)
	jmp	LBB0_9
LBB0_5:
	callq	_strerror
	leaq	L_.str.1(%rip), %rdi
	movl	%eax, %esi
	callq	_FATAL
LBB0_6:
	movl	%ebx, (%r14)
	cmpl	$-1, %ebx
	je	LBB0_9
## %bb.7:
	movq	_max_file_fd@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jle	LBB0_9
## %bb.8:
	movl	%ebx, (%rax)
LBB0_9:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_wsconfig,4,2                   ## @wsconfig
	.comm	_O_WRONLY,4,2                   ## @O_WRONLY
	.comm	_O_NONBLOCK,4,2                 ## @O_NONBLOCK
	.comm	_errno,8,3                      ## @errno
	.comm	_ENXIO,8,3                      ## @ENXIO
	.section	__TEXT,__cstring,cstring_literals
L_.str.1:                               ## @.str.1
	.asciz	"Unable to open fifo out: %s."

	.comm	_max_file_fd,4,2                ## @max_file_fd
	.no_dead_strip	_ws_openfifo_out
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ws_openfifo_out
_ws_openfifo_out:                       ; @ws_openfifo_out
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
Lloh0:
	adrp	x20, _wsconfig@GOTPAGE
Lloh1:
	ldr	x20, [x20, _wsconfig@GOTPAGEOFF]
	ldr	w0, [x20]
	bl	_ws_setfifo
Lloh2:
	adrp	x8, _O_WRONLY@GOTPAGE
Lloh3:
	ldr	x8, [x8, _O_WRONLY@GOTPAGEOFF]
	ldr	w0, [x20]
Lloh4:
	ldr	w8, [x8]
Lloh5:
	adrp	x9, _O_NONBLOCK@GOTPAGE
Lloh6:
	ldr	x9, [x9, _O_NONBLOCK@GOTPAGEOFF]
Lloh7:
	ldr	w9, [x9]
	orr	w1, w9, w8
	bl	_open
	mov	x20, x0
	cmn	w0, #1
	b.eq	LBB0_3
; %bb.1:
	tbz	w20, #31, LBB0_6
; %bb.2:
Lloh8:
	adrp	x8, _errno@GOTPAGE
Lloh9:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh10:
	ldr	x0, [x8]
	b	LBB0_5
LBB0_3:
Lloh11:
	adrp	x8, _errno@GOTPAGE
Lloh12:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh13:
	ldr	x0, [x8]
Lloh14:
	adrp	x8, _ENXIO@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ENXIO@GOTPAGEOFF]
Lloh16:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_5
; %bb.4:
	bl	_strerror
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x0, w0
	bl	_LOG
	mov	w8, #-1
	str	w8, [x19]
	b	LBB0_8
LBB0_5:
	bl	_strerror
	mov	x1, x0
Lloh17:
	adrp	x0, l_.str.1@PAGE
Lloh18:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_FATAL
LBB0_6:
	str	w20, [x19]
Lloh19:
	adrp	x8, _max_file_fd@GOTPAGE
Lloh20:
	ldr	x8, [x8, _max_file_fd@GOTPAGEOFF]
	ldr	w9, [x8]
	cmn	w20, #1
	ccmp	w20, w9, #4, ne
	b.le	LBB0_8
; %bb.7:
	str	w20, [x8]
LBB0_8:
	mov	x0, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh19, Lloh20
	.cfi_endproc
                                        ; -- End function
	.comm	_wsconfig,4,2                   ; @wsconfig
	.comm	_O_WRONLY,4,2                   ; @O_WRONLY
	.comm	_O_NONBLOCK,4,2                 ; @O_NONBLOCK
	.comm	_errno,8,3                      ; @errno
	.comm	_ENXIO,8,3                      ; @ENXIO
	.section	__TEXT,__cstring,cstring_literals
l_.str.1:                               ; @.str.1
	.asciz	"Unable to open fifo out: %s."

	.comm	_max_file_fd,4,2                ; @max_file_fd
	.no_dead_strip	_ws_openfifo_out
.subsections_via_symbols
