	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function libusb10_ctrl_proxy
_libusb10_ctrl_proxy:                   ## @libusb10_ctrl_proxy
	.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	%rdi, %r13
	callq	_libusb20_tr_get_status
	movl	%eax, %ebx
	movq	%r13, %rdi
	callq	_libusb20_tr_get_priv_sc1
	movq	%rax, %r14
	movq	%r13, %rdi
	callq	_libusb20_tr_get_max_total_length
	movl	%eax, %r12d
	movq	%r13, %rdi
	callq	_libusb20_tr_get_actual_length
	testq	%r14, %r14
	je	LBB0_18
## %bb.1:
	cmpl	$128, %ebx
	je	LBB0_11
## %bb.2:
	cmpl	$129, %ebx
	jne	LBB0_17
## %bb.3:
	movl	%eax, %r15d
	movl	48(%r14), %ebx
	addl	%eax, 52(%r14)
	movq	%r13, %rdi
	xorl	%esi, %esi
	callq	_libusb20_tr_get_length
	subl	%eax, %r15d
	cmpl	%r15d, (%r14)
	jne	LBB0_4
## %bb.8:
	movl	4(%r14), %r15d
	testl	%r15d, %r15d
	je	LBB0_9
## %bb.10:
	cmpl	%r15d, %r12d
	cmovll	%r12d, %r15d
	movq	%r13, %rdi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_libusb20_tr_set_length
	testl	%r15d, %r15d
	jne	LBB0_14
LBB0_13:
	movl	$1, %esi
	jmp	LBB0_15
LBB0_11:
	movl	4(%r14), %r15d
	cmpl	%r15d, %r12d
	cmovll	%r12d, %r15d
	movq	%r13, %rdi
	movl	$8, %esi
	xorl	%edx, %edx
	callq	_libusb20_tr_set_length
	movl	56(%r14), %esi
	movq	%r13, %rdi
	xorl	%edx, %edx
	callq	_libusb20_tr_set_buffer
	testl	%r15d, %r15d
	je	LBB0_13
LBB0_14:
	movq	%r13, %rdi
	movl	%r15d, %esi
	movl	$1, %edx
	callq	_libusb20_tr_set_length
	movl	8(%r14), %esi
	movq	%r13, %rdi
	movl	$1, %edx
	callq	_libusb20_tr_set_buffer
	movl	$2, %esi
LBB0_15:
	movq	%r13, %rdi
	callq	_libusb20_tr_set_total_frames
	movl	%r15d, (%r14)
	addl	%r15d, 8(%r14)
	subl	%r15d, 4(%r14)
	movq	%r13, %rdi
	callq	_libusb20_tr_submit
	cmpl	$0, 4(%r14)
	je	LBB0_16
LBB0_18:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_17:
	movl	%ebx, %edi
	callq	_libusb10_convert_error
	movq	%r13, %rdi
	movq	%r14, %rsi
	movl	%eax, %edx
	jmp	LBB0_7
LBB0_4:
	movq	_LIBUSB_TRANSFER_SHORT_NOT_OK@GOTPCREL(%rip), %rax
	testl	%ebx, (%rax)
	je	LBB0_9
## %bb.5:
	movq	_LIBUSB_TRANSFER_ERROR@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_16:
	movq	%r13, %rdi
	callq	_libusb20_tr_get_priv_sc0
	movl	60(%r14), %esi
	movl	%eax, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_libusb10_submit_transfer_sub   ## TAILCALL
LBB0_9:
	movq	_LIBUSB_TRANSFER_COMPLETED@GOTPCREL(%rip), %rax
LBB0_6:
	movl	(%rax), %edx
	movq	%r13, %rdi
	movq	%r14, %rsi
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_libusb10_complete_transfer     ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_LIBUSB_TRANSFER_SHORT_NOT_OK,4,2 ## @LIBUSB_TRANSFER_SHORT_NOT_OK
	.comm	_LIBUSB_TRANSFER_ERROR,4,2      ## @LIBUSB_TRANSFER_ERROR
	.comm	_LIBUSB_TRANSFER_COMPLETED,4,2  ## @LIBUSB_TRANSFER_COMPLETED
	.no_dead_strip	_libusb10_ctrl_proxy
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function libusb10_ctrl_proxy
_libusb10_ctrl_proxy:                   ; @libusb10_ctrl_proxy
	.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	x19, x0
	bl	_libusb20_tr_get_status
	mov	x22, x0
	mov	x0, x19
	bl	_libusb20_tr_get_priv_sc1
	mov	x20, x0
	mov	x0, x19
	bl	_libusb20_tr_get_max_total_length
	mov	x21, x0
	mov	x0, x19
	bl	_libusb20_tr_get_actual_length
	cbz	x20, LBB0_10
; %bb.1:
	cmp	w22, #128
	b.eq	LBB0_7
; %bb.2:
	cmp	w22, #129
	b.ne	LBB0_11
; %bb.3:
	mov	x23, x0
	ldp	w22, w8, [x20, #48]
	add	w8, w8, w0
	str	w8, [x20, #52]
	mov	x0, x19
	mov	w1, #0
	bl	_libusb20_tr_get_length
	ldr	w8, [x20]
	sub	w9, w23, w0
	cmp	w8, w9
	b.ne	LBB0_12
; %bb.4:
	ldr	w8, [x20, #4]
	cbz	w8, LBB0_15
; %bb.5:
	cmp	w21, w8
	csel	w21, w21, w8, lt
	mov	x0, x19
	mov	w1, #0
	mov	w2, #0
	bl	_libusb20_tr_set_length
	cbnz	w21, LBB0_8
LBB0_6:
	mov	w1, #1
	b	LBB0_9
LBB0_7:
	ldr	w8, [x20, #4]
	cmp	w21, w8
	csel	w21, w21, w8, lt
	mov	x0, x19
	mov	w1, #8
	mov	w2, #0
	bl	_libusb20_tr_set_length
	ldr	w1, [x20, #56]
	mov	x0, x19
	mov	w2, #0
	bl	_libusb20_tr_set_buffer
	cbz	w21, LBB0_6
LBB0_8:
	mov	x0, x19
	mov	x1, x21
	mov	w2, #1
	bl	_libusb20_tr_set_length
	ldr	w1, [x20, #8]
	mov	x0, x19
	mov	w2, #1
	bl	_libusb20_tr_set_buffer
	mov	w1, #2
LBB0_9:
	mov	x0, x19
	bl	_libusb20_tr_set_total_frames
	ldp	w9, w8, [x20, #4]
	add	w8, w8, w21
	str	w8, [x20, #8]
	sub	w8, w9, w21
	stp	w21, w8, [x20]
	mov	x0, x19
	bl	_libusb20_tr_submit
	ldr	w8, [x20, #4]
	cbz	w8, LBB0_14
LBB0_10:
	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
	ret
LBB0_11:
	mov	x0, x22
	bl	_libusb10_convert_error
	mov	x2, x0
	b	LBB0_17
LBB0_12:
Lloh0:
	adrp	x8, _LIBUSB_TRANSFER_SHORT_NOT_OK@GOTPAGE
Lloh1:
	ldr	x8, [x8, _LIBUSB_TRANSFER_SHORT_NOT_OK@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	tst	w8, w22
	b.eq	LBB0_15
; %bb.13:
Lloh3:
	adrp	x8, _LIBUSB_TRANSFER_ERROR@GOTPAGE
Lloh4:
	ldr	x8, [x8, _LIBUSB_TRANSFER_ERROR@GOTPAGEOFF]
	b	LBB0_16
LBB0_14:
	mov	x0, x19
	bl	_libusb20_tr_get_priv_sc0
	ldr	w1, [x20, #60]
	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	_libusb10_submit_transfer_sub
LBB0_15:
Lloh5:
	adrp	x8, _LIBUSB_TRANSFER_COMPLETED@GOTPAGE
Lloh6:
	ldr	x8, [x8, _LIBUSB_TRANSFER_COMPLETED@GOTPAGEOFF]
LBB0_16:
	ldr	w2, [x8]
LBB0_17:
	mov	x0, x19
	mov	x1, x20
	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	_libusb10_complete_transfer
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.cfi_endproc
                                        ; -- End function
	.comm	_LIBUSB_TRANSFER_SHORT_NOT_OK,4,2 ; @LIBUSB_TRANSFER_SHORT_NOT_OK
	.comm	_LIBUSB_TRANSFER_ERROR,4,2      ; @LIBUSB_TRANSFER_ERROR
	.comm	_LIBUSB_TRANSFER_COMPLETED,4,2  ; @LIBUSB_TRANSFER_COMPLETED
	.no_dead_strip	_libusb10_ctrl_proxy
.subsections_via_symbols
