	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function shm16write__write_file
_shm16write__write_file:                ## @shm16write__write_file
	.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
	subq	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rsi, %rax
	movq	%rdi, %r14
	leaq	L_.str(%rip), %rsi
	leaq	-32(%rbp), %rdx
	leaq	-28(%rbp), %rcx
	leaq	-24(%rbp), %r8
	leaq	-20(%rbp), %r9
	movq	%rax, %rdi
	callq	_sscanf
	cmpl	$4, %eax
	jne	LBB0_1
## %bb.3:
	movl	-32(%rbp), %esi
	movq	_B43_MAX_SHM_ROUTING@GOTPCREL(%rip), %rax
	cmpl	(%rax), %esi
	ja	LBB0_4
## %bb.5:
	movl	-28(%rbp), %edx
	movq	_B43_MAX_SHM_ADDR@GOTPCREL(%rip), %rax
	cmpl	(%rax), %edx
	ja	LBB0_4
## %bb.6:
	movq	_B43_SHM_SHARED@GOTPCREL(%rip), %rax
	cmpl	(%rax), %esi
	jne	LBB0_8
## %bb.7:
	movl	%edx, %eax
	andl	$1, %eax
	je	LBB0_8
LBB0_4:
	movq	_EADDRNOTAVAIL@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_15:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_8:
	movl	-24(%rbp), %eax
	cmpl	$65535, %eax                    ## imm = 0xFFFF
	ja	LBB0_10
## %bb.9:
	movl	-20(%rbp), %ecx
	cmpl	$65536, %ecx                    ## imm = 0x10000
	jae	LBB0_10
## %bb.11:
	xorl	%ebx, %ebx
	testl	%eax, %eax
	je	LBB0_12
## %bb.13:
	movq	%r14, %rdi
	callq	_b43_shm_read16
	movl	-20(%rbp), %ecx
	movl	-32(%rbp), %esi
	movl	-28(%rbp), %edx
	andl	-24(%rbp), %eax
	jmp	LBB0_14
LBB0_10:
	movq	_E2BIG@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_12:
	xorl	%eax, %eax
LBB0_14:
	orl	%eax, %ecx
	movq	%r14, %rdi
	callq	_b43_shm_write16
	jmp	LBB0_15
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"0x%X 0x%X 0x%X 0x%X"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_B43_MAX_SHM_ROUTING,4,2        ## @B43_MAX_SHM_ROUTING
	.comm	_EADDRNOTAVAIL,4,2              ## @EADDRNOTAVAIL
	.comm	_B43_MAX_SHM_ADDR,4,2           ## @B43_MAX_SHM_ADDR
	.comm	_B43_SHM_SHARED,4,2             ## @B43_SHM_SHARED
	.comm	_E2BIG,4,2                      ## @E2BIG
	.no_dead_strip	_shm16write__write_file
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function shm16write__write_file
_shm16write__write_file:                ; @shm16write__write_file
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x8, x1
	mov	x19, x0
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	add	x2, sp, #12
	add	x3, sp, #8
	add	x4, sp, #4
	mov	x5, sp
	mov	x0, x8
	bl	_sscanf
	cmp	w0, #4
	b.ne	LBB0_9
; %bb.1:
	ldr	w1, [sp, #12]
Lloh2:
	adrp	x8, _B43_MAX_SHM_ROUTING@GOTPAGE
Lloh3:
	ldr	x8, [x8, _B43_MAX_SHM_ROUTING@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	cmp	w1, w8
	b.hi	LBB0_10
; %bb.2:
	ldr	w2, [sp, #8]
Lloh5:
	adrp	x8, _B43_MAX_SHM_ADDR@GOTPAGE
Lloh6:
	ldr	x8, [x8, _B43_MAX_SHM_ADDR@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	cmp	w2, w8
	b.hi	LBB0_10
; %bb.3:
Lloh8:
	adrp	x8, _B43_SHM_SHARED@GOTPAGE
Lloh9:
	ldr	x8, [x8, _B43_SHM_SHARED@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
	and	w9, w2, #0x1
	cmp	w1, w8
	ccmp	w9, #0, #4, eq
	b.ne	LBB0_10
; %bb.4:
	ldr	w9, [sp, #4]
	lsr	w8, w9, #16
	cbnz	w8, LBB0_13
; %bb.5:
	ldr	w8, [sp]
	cmp	w8, #16, lsl #12                ; =65536
	b.hs	LBB0_13
; %bb.6:
	cbz	w9, LBB0_8
; %bb.7:
	mov	x0, x19
	bl	_b43_shm_read16
	ldp	w8, w9, [sp]
	ldp	w2, w1, [sp, #8]
	and	w9, w9, w0
LBB0_8:
	orr	w3, w9, w8
	mov	x0, x19
	bl	_b43_shm_write16
	mov	w0, #0
	b	LBB0_12
LBB0_9:
Lloh11:
	adrp	x8, _EINVAL@GOTPAGE
Lloh12:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_11
LBB0_10:
Lloh13:
	adrp	x8, _EADDRNOTAVAIL@GOTPAGE
Lloh14:
	ldr	x8, [x8, _EADDRNOTAVAIL@GOTPAGEOFF]
LBB0_11:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_12:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_13:
Lloh15:
	adrp	x8, _E2BIG@GOTPAGE
Lloh16:
	ldr	x8, [x8, _E2BIG@GOTPAGEOFF]
	b	LBB0_11
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"0x%X 0x%X 0x%X 0x%X"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_B43_MAX_SHM_ROUTING,4,2        ; @B43_MAX_SHM_ROUTING
	.comm	_EADDRNOTAVAIL,4,2              ; @EADDRNOTAVAIL
	.comm	_B43_MAX_SHM_ADDR,4,2           ; @B43_MAX_SHM_ADDR
	.comm	_B43_SHM_SHARED,4,2             ; @B43_SHM_SHARED
	.comm	_E2BIG,4,2                      ; @E2BIG
	.no_dead_strip	_shm16write__write_file
.subsections_via_symbols
