	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function joy_create_interface
_joy_create_interface:                  ## @joy_create_interface
	.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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movl	$0, -36(%rbp)
	movq	_kIOHIDDeviceUserClientTypeID@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_kIOCFPlugInInterfaceID@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	-48(%rbp), %rcx
	leaq	-36(%rbp), %r8
	callq	_IOCreatePlugInInterfaceForService
	movq	_kIOReturnSuccess@GOTPCREL(%rip), %rcx
	xorl	%r15d, %r15d
	cmpq	(%rcx), %rax
	jne	LBB0_3
## %bb.1:
	movq	-48(%rbp), %rbx
	movq	(%rbx), %rax
	movq	(%rax), %r12
	movq	_kIOHIDDeviceInterfaceID@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_CFUUIDGetUUIDBytes
	movq	%rbx, %rdi
	movl	%eax, %esi
	movl	%r14d, %edx
	callq	*%r12
	movq	_S_OK@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_3
## %bb.2:
	movq	-48(%rbp), %rdi
	movq	(%rdi), %rax
	callq	*8(%rax)
	movl	$1, %r15d
LBB0_3:
	movl	%r15d, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_kIOHIDDeviceUserClientTypeID,4,2 ## @kIOHIDDeviceUserClientTypeID
	.comm	_kIOCFPlugInInterfaceID,4,2     ## @kIOCFPlugInInterfaceID
	.comm	_kIOReturnSuccess,8,3           ## @kIOReturnSuccess
	.comm	_kIOHIDDeviceInterfaceID,4,2    ## @kIOHIDDeviceInterfaceID
	.comm	_S_OK,8,3                       ## @S_OK
	.no_dead_strip	_joy_create_interface
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function joy_create_interface
_joy_create_interface:                  ; @joy_create_interface
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x1
	str	wzr, [sp, #4]
Lloh0:
	adrp	x8, _kIOHIDDeviceUserClientTypeID@GOTPAGE
Lloh1:
	ldr	x8, [x8, _kIOHIDDeviceUserClientTypeID@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x8, _kIOCFPlugInInterfaceID@GOTPAGE
Lloh4:
	ldr	x8, [x8, _kIOCFPlugInInterfaceID@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	add	x3, sp, #8
	add	x4, sp, #4
	bl	_IOCreatePlugInInterfaceForService
	mov	x8, x0
	mov	w0, #0
Lloh6:
	adrp	x9, _kIOReturnSuccess@GOTPAGE
Lloh7:
	ldr	x9, [x9, _kIOReturnSuccess@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.1:
	ldr	x20, [sp, #8]
	ldr	x8, [x20]
	ldr	x21, [x8]
Lloh9:
	adrp	x8, _kIOHIDDeviceInterfaceID@GOTPAGE
Lloh10:
	ldr	x8, [x8, _kIOHIDDeviceInterfaceID@GOTPAGEOFF]
Lloh11:
	ldr	w0, [x8]
	bl	_CFUUIDGetUUIDBytes
	mov	x1, x0
	mov	x0, x20
	mov	x2, x19
	blr	x21
Lloh12:
	adrp	x8, _S_OK@GOTPAGE
Lloh13:
	ldr	x8, [x8, _S_OK@GOTPAGEOFF]
Lloh14:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_3
; %bb.2:
	ldr	x0, [sp, #8]
	ldr	x8, [x0]
	ldr	x8, [x8, #8]
	blr	x8
	mov	w0, #1
	b	LBB0_4
LBB0_3:
	mov	w0, #0
LBB0_4:
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_kIOHIDDeviceUserClientTypeID,4,2 ; @kIOHIDDeviceUserClientTypeID
	.comm	_kIOCFPlugInInterfaceID,4,2     ; @kIOCFPlugInInterfaceID
	.comm	_kIOReturnSuccess,8,3           ; @kIOReturnSuccess
	.comm	_kIOHIDDeviceInterfaceID,4,2    ; @kIOHIDDeviceInterfaceID
	.comm	_S_OK,8,3                       ; @S_OK
	.no_dead_strip	_joy_create_interface
.subsections_via_symbols
