	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ide_tape_create_rw_cmd
_ide_tape_create_rw_cmd:                ## @ide_tape_create_rw_cmd
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r15
	movq	%rdx, %r14
	movq	%rsi, %rbx
	movq	%rdi, %r12
	movq	%rdx, %rdi
	callq	_blk_rq_sectors
	movl	(%r12), %ecx
	sarl	$9, %ecx
	cltd
	idivl	%ecx
	movl	%eax, %r13d
	movq	%rbx, %rdi
	callq	_ide_init_pc
	movl	%r13d, %edi
	callq	_cpu_to_be32
	movq	(%rbx), %rsi
	addq	$4, %rsi
	movl	%eax, %edi
	callq	_put_unaligned
	movq	(%rbx), %rax
	movl	$1, 4(%rax)
	movq	%r14, %rdi
	callq	_blk_rq_bytes
	cmpq	8(%r12), %rax
	jne	LBB0_2
## %bb.1:
	movq	_PC_FLAG_DMA_OK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 8(%rbx)
LBB0_2:
	movq	_READ_6@GOTPCREL(%rip), %rax
	cmpq	%r15, (%rax)
	je	LBB0_3
## %bb.4:
	movq	_WRITE_6@GOTPCREL(%rip), %rax
	cmpq	%r15, (%rax)
	je	LBB0_6
## %bb.5:
	movq	(%rbx), %rsi
	jmp	LBB0_7
LBB0_3:
	movq	(%rbx), %rsi
	movl	%r15d, (%rsi)
	jmp	LBB0_7
LBB0_6:
	movq	(%rbx), %rsi
	movl	%r15d, (%rsi)
	movq	_PC_FLAG_WRITING@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 8(%rbx)
LBB0_7:
	movl	(%r14), %edi
	movl	$12, %edx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_memcpy                         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_PC_FLAG_DMA_OK,4,2             ## @PC_FLAG_DMA_OK
	.comm	_READ_6,8,3                     ## @READ_6
	.comm	_WRITE_6,8,3                    ## @WRITE_6
	.comm	_PC_FLAG_WRITING,4,2            ## @PC_FLAG_WRITING
	.no_dead_strip	_ide_tape_create_rw_cmd
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ide_tape_create_rw_cmd
_ide_tape_create_rw_cmd:                ; @ide_tape_create_rw_cmd
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x21, x3
	mov	x19, x2
	mov	x20, x1
	mov	x22, x0
	mov	x0, x2
	bl	_blk_rq_sectors
	ldr	w8, [x22]
	asr	w8, w8, #9
	sdiv	w23, w0, w8
	mov	x0, x20
	bl	_ide_init_pc
	mov	x0, x23
	bl	_cpu_to_be32
	ldr	x8, [x20]
	add	x1, x8, #4
	bl	_put_unaligned
	ldr	x8, [x20]
	mov	w9, #1
	str	w9, [x8, #4]
	mov	x0, x19
	bl	_blk_rq_bytes
	ldr	x8, [x22, #8]
	cmp	x0, x8
	b.ne	LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _PC_FLAG_DMA_OK@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PC_FLAG_DMA_OK@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	ldr	w9, [x20, #8]
	orr	w8, w9, w8
	str	w8, [x20, #8]
LBB0_2:
Lloh3:
	adrp	x8, _READ_6@GOTPAGE
Lloh4:
	ldr	x8, [x8, _READ_6@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	cmp	x8, x21
	b.eq	LBB0_5
; %bb.3:
Lloh6:
	adrp	x8, _WRITE_6@GOTPAGE
Lloh7:
	ldr	x8, [x8, _WRITE_6@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	cmp	x8, x21
	b.eq	LBB0_6
; %bb.4:
	ldr	x1, [x20]
	b	LBB0_7
LBB0_5:
	ldr	x1, [x20]
	str	w21, [x1]
	b	LBB0_7
LBB0_6:
	ldr	x1, [x20]
	str	w21, [x1]
Lloh9:
	adrp	x8, _PC_FLAG_WRITING@GOTPAGE
Lloh10:
	ldr	x8, [x8, _PC_FLAG_WRITING@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	ldr	w9, [x20, #8]
	orr	w8, w9, w8
	str	w8, [x20, #8]
LBB0_7:
	ldr	w0, [x19]
	mov	w2, #12
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_memcpy
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_PC_FLAG_DMA_OK,4,2             ; @PC_FLAG_DMA_OK
	.comm	_READ_6,8,3                     ; @READ_6
	.comm	_WRITE_6,8,3                    ; @WRITE_6
	.comm	_PC_FLAG_WRITING,4,2            ; @PC_FLAG_WRITING
	.no_dead_strip	_ide_tape_create_rw_cmd
.subsections_via_symbols
