	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_find_usb_endpoints             ## -- Begin function find_usb_endpoints
	.p2align	4, 0x90
_find_usb_endpoints:                    ## @find_usb_endpoints
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r9, %r14
	movq	%rcx, %r15
	movq	%rdx, %r12
	movq	%rsi, %rbx
	movq	%rdi, %r13
	movq	32(%rbp), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	24(%rbp), %rax
	movq	16(%rbp), %rcx
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	movq	$0, (%rcx)
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	$0, (%rax)
	movq	$0, (%r9)
	callq	_libusb20_dev_get_config_index
	movq	%r13, %rdi
	movl	%eax, %esi
	callq	_libusb20_dev_alloc_config
	testq	%rax, %rax
	je	LBB0_18
## %bb.1:
	movq	(%rax), %rsi
	testq	%rsi, %rsi
	je	LBB0_17
## %bb.2:
	movq	8(%rax), %rcx
	leaq	32(%rcx), %rdi
	xorl	%edx, %edx
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_16:                                ##   in Loop: Header=BB0_3 Depth=1
	incq	%rdx
	addq	$40, %rdi
	cmpq	%rdx, %rsi
	je	LBB0_17
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	%rbx, -16(%rdi)
	jne	LBB0_16
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	cmpq	$255, %r12
	je	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_3 Depth=1
	cmpq	%r12, -8(%rdi)
	jne	LBB0_16
LBB0_6:                                 ##   in Loop: Header=BB0_3 Depth=1
	cmpq	$255, %r15
	je	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_3 Depth=1
	cmpq	%r15, (%rdi)
	jne	LBB0_16
LBB0_8:
	cmpq	$0, -48(%rbp)                   ## 8-byte Folded Reload
	je	LBB0_11
## %bb.9:
	decq	%rsi
	cmpq	%rdx, %rsi
	je	LBB0_17
## %bb.10:
	incq	%rdx
LBB0_11:
	movq	%rdx, (%r14)
	leaq	(%rdx,%rdx,4), %rsi
	cmpq	$0, (%rcx,%rsi,8)
	je	LBB0_17
## %bb.12:
	leaq	(%rcx,%rsi,8), %rdx
	movq	8(%rcx,%rsi,8), %rcx
	xorl	%esi, %esi
	jmp	LBB0_13
	.p2align	4, 0x90
LBB0_15:                                ##   in Loop: Header=BB0_13 Depth=1
	incq	%rsi
	cmpq	(%rdx), %rsi
	je	LBB0_17
LBB0_13:                                ## =>This Inner Loop Header: Depth=1
	movl	(%rcx,%rsi,8), %edi
	andl	$3, %edi
	cmpl	$2, %edi
	jne	LBB0_15
## %bb.14:                              ##   in Loop: Header=BB0_13 Depth=1
	movslq	4(%rcx,%rsi,8), %rdi
	testb	$-128, %dil
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	cmoveq	-64(%rbp), %rbx                 ## 8-byte Folded Reload
	movq	%rdi, (%rbx)
	jmp	LBB0_15
LBB0_17:
	movq	%rax, %rdi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_free                           ## TAILCALL
LBB0_18:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_find_usb_endpoints             ; -- Begin function find_usb_endpoints
	.p2align	2
_find_usb_endpoints:                    ; @find_usb_endpoints
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x7
	mov	x20, x6
	mov	x21, x5
	mov	x22, x3
	mov	x23, x2
	mov	x24, x1
	mov	x25, x0
	ldr	x26, [x29, #16]
	str	xzr, [x6]
	str	xzr, [x7]
	str	xzr, [x5]
	bl	_libusb20_dev_get_config_index
	mov	x1, x0
	mov	x0, x25
	bl	_libusb20_dev_alloc_config
	cbz	x0, LBB0_18
; %bb.1:
	ldr	x10, [x0]
	cbz	x10, LBB0_17
; %bb.2:
	mov	x8, #0
	ldr	x9, [x0, #8]
	add	x11, x9, #32
	b	LBB0_4
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	add	x8, x8, #1
	add	x11, x11, #40
	cmp	x10, x8
	b.eq	LBB0_17
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldur	x12, [x11, #-16]
	cmp	x12, x24
	b.ne	LBB0_3
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	cmp	x23, #255
	b.eq	LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldur	x12, [x11, #-8]
	cmp	x12, x23
	b.ne	LBB0_3
LBB0_7:                                 ;   in Loop: Header=BB0_4 Depth=1
	cmp	x22, #255
	b.eq	LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x12, [x11]
	cmp	x12, x22
	b.ne	LBB0_3
LBB0_9:
	cbz	x26, LBB0_12
; %bb.10:
	sub	x10, x10, #1
	cmp	x10, x8
	b.eq	LBB0_17
; %bb.11:
	add	x8, x8, #1
LBB0_12:
	str	x8, [x21]
	mov	w10, #40
	madd	x10, x8, x10, x9
	ldr	x11, [x10]
	cbz	x11, LBB0_17
; %bb.13:
	mov	x11, #0
	mov	w12, #40
	madd	x8, x8, x12, x9
	ldr	x8, [x8, #8]
	add	x8, x8, #4
	b	LBB0_15
LBB0_14:                                ;   in Loop: Header=BB0_15 Depth=1
	add	x11, x11, #1
	ldr	x9, [x10]
	add	x8, x8, #8
	cmp	x11, x9
	b.eq	LBB0_17
LBB0_15:                                ; =>This Inner Loop Header: Depth=1
	ldur	w9, [x8, #-4]
	and	w9, w9, #0x3
	cmp	w9, #2
	b.ne	LBB0_14
; %bb.16:                               ;   in Loop: Header=BB0_15 Depth=1
	ldrsw	x9, [x8]
	tst	w9, #0x80
	csel	x12, x19, x20, eq
	str	x9, [x12]
	b	LBB0_14
LBB0_17:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_free
LBB0_18:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
