	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_libusb_get_ss_usb_device_capability_descriptor ## -- Begin function libusb_get_ss_usb_device_capability_descriptor
	.p2align	4, 0x90
_libusb_get_ss_usb_device_capability_descriptor: ## @libusb_get_ss_usb_device_capability_descriptor
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	testq	%rsi, %rsi
	je	LBB0_5
## %bb.1:
	movq	%rdx, %r14
	testq	%rdx, %rdx
	je	LBB0_5
## %bb.2:
	movq	%rsi, %rbx
	movq	(%rsi), %rax
	movq	_LIBUSB_BT_SS_USB_DEVICE_CAPABILITY@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_5
## %bb.3:
	movq	8(%rbx), %rax
	movq	_LIBUSB_BT_SS_USB_DEVICE_CAPABILITY_SIZE@GOTPCREL(%rip), %r15
	cmpq	(%r15), %rax
	jge	LBB0_8
## %bb.4:
	movq	_LIBUSB_ERROR_IO@GOTPCREL(%rip), %rax
	jmp	LBB0_6
LBB0_5:
	movq	_LIBUSB_ERROR_INVALID_PARAM@GOTPCREL(%rip), %rax
LBB0_6:
	movl	(%rax), %eax
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_8:
	movl	$40, %edi
	callq	_malloc
	testq	%rax, %rax
	je	LBB0_10
## %bb.9:
	movq	(%r15), %rcx
	movq	%rcx, 32(%rax)
	movl	24(%rbx), %ecx
	movl	%ecx, 28(%rax)
	movq	(%rbx), %rcx
	movq	%rcx, (%rax)
	movq	16(%rbx), %rcx
	movl	(%rcx), %edx
	movl	%edx, 8(%rax)
	movl	8(%rcx), %edx
	shll	$8, %edx
	orl	4(%rcx), %edx
	movl	%edx, 12(%rax)
	movl	12(%rcx), %edx
	movl	%edx, 16(%rax)
	movl	16(%rcx), %edx
	movl	%edx, 20(%rax)
	movl	24(%rcx), %edx
	shll	$8, %edx
	orl	20(%rcx), %edx
	movl	%edx, 24(%rax)
	movq	%rax, (%r14)
	xorl	%eax, %eax
	jmp	LBB0_7
LBB0_10:
	movq	_LIBUSB_ERROR_NO_MEM@GOTPCREL(%rip), %rax
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.comm	_LIBUSB_BT_SS_USB_DEVICE_CAPABILITY,8,3 ## @LIBUSB_BT_SS_USB_DEVICE_CAPABILITY
	.comm	_LIBUSB_ERROR_INVALID_PARAM,4,2 ## @LIBUSB_ERROR_INVALID_PARAM
	.comm	_LIBUSB_BT_SS_USB_DEVICE_CAPABILITY_SIZE,8,3 ## @LIBUSB_BT_SS_USB_DEVICE_CAPABILITY_SIZE
	.comm	_LIBUSB_ERROR_IO,4,2            ## @LIBUSB_ERROR_IO
	.comm	_LIBUSB_ERROR_NO_MEM,4,2        ## @LIBUSB_ERROR_NO_MEM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_libusb_get_ss_usb_device_capability_descriptor ; -- Begin function libusb_get_ss_usb_device_capability_descriptor
	.p2align	2
_libusb_get_ss_usb_device_capability_descriptor: ; @libusb_get_ss_usb_device_capability_descriptor
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	cbz	x1, LBB0_5
; %bb.1:
	mov	x19, x2
	cbz	x2, LBB0_5
; %bb.2:
	mov	x20, x1
	ldr	x8, [x1]
Lloh0:
	adrp	x9, _LIBUSB_BT_SS_USB_DEVICE_CAPABILITY@GOTPAGE
Lloh1:
	ldr	x9, [x9, _LIBUSB_BT_SS_USB_DEVICE_CAPABILITY@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_5
; %bb.3:
	ldr	x8, [x20, #8]
Lloh3:
	adrp	x21, _LIBUSB_BT_SS_USB_DEVICE_CAPABILITY_SIZE@GOTPAGE
Lloh4:
	ldr	x21, [x21, _LIBUSB_BT_SS_USB_DEVICE_CAPABILITY_SIZE@GOTPAGEOFF]
	ldr	x9, [x21]
	cmp	x8, x9
	b.ge	LBB0_8
; %bb.4:
Lloh5:
	adrp	x8, _LIBUSB_ERROR_IO@GOTPAGE
Lloh6:
	ldr	x8, [x8, _LIBUSB_ERROR_IO@GOTPAGEOFF]
	b	LBB0_6
LBB0_5:
Lloh7:
	adrp	x8, _LIBUSB_ERROR_INVALID_PARAM@GOTPAGE
Lloh8:
	ldr	x8, [x8, _LIBUSB_ERROR_INVALID_PARAM@GOTPAGEOFF]
LBB0_6:
	ldr	w0, [x8]
LBB0_7:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_8:
	mov	w0, #40
	bl	_malloc
	cbz	x0, LBB0_10
; %bb.9:
	mov	x8, x0
	mov	w0, #0
	ldr	x9, [x21]
	str	x9, [x8, #32]
	ldr	w9, [x20, #24]
	str	w9, [x8, #28]
	ldr	x9, [x20]
	str	x9, [x8]
	ldr	x9, [x20, #16]
	ldr	w10, [x9]
	str	w10, [x8, #8]
	ldp	w10, w11, [x9, #4]
	orr	w10, w10, w11, lsl #8
	str	w10, [x8, #12]
	ldr	w10, [x9, #12]
	str	w10, [x8, #16]
	ldr	w10, [x9, #16]
	str	w10, [x8, #20]
	ldp	w10, w9, [x9, #20]
	orr	w9, w10, w9, lsl #8
	str	w9, [x8, #24]
	str	x8, [x19]
	b	LBB0_7
LBB0_10:
Lloh9:
	adrp	x8, _LIBUSB_ERROR_NO_MEM@GOTPAGE
Lloh10:
	ldr	x8, [x8, _LIBUSB_ERROR_NO_MEM@GOTPAGEOFF]
	b	LBB0_6
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_LIBUSB_BT_SS_USB_DEVICE_CAPABILITY,8,3 ; @LIBUSB_BT_SS_USB_DEVICE_CAPABILITY
	.comm	_LIBUSB_ERROR_INVALID_PARAM,4,2 ; @LIBUSB_ERROR_INVALID_PARAM
	.comm	_LIBUSB_BT_SS_USB_DEVICE_CAPABILITY_SIZE,8,3 ; @LIBUSB_BT_SS_USB_DEVICE_CAPABILITY_SIZE
	.comm	_LIBUSB_ERROR_IO,4,2            ; @LIBUSB_ERROR_IO
	.comm	_LIBUSB_ERROR_NO_MEM,4,2        ; @LIBUSB_ERROR_NO_MEM
.subsections_via_symbols
