	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cocoa_input_find_any_axis      ## -- Begin function cocoa_input_find_any_axis
	.p2align	4, 0x90
_cocoa_input_find_any_axis:             ## @cocoa_input_find_any_axis
	.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
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edi, %r14d
	xorl	%eax, %eax
	callq	_input_driver_get_data
	movq	%rax, %r15
	testq	%rax, %rax
	je	LBB0_5
## %bb.1:
	movq	8(%r15), %rcx
	testq	%rcx, %rcx
	je	LBB0_3
## %bb.2:
	xorl	%eax, %eax
	callq	*8(%rcx)
LBB0_3:
	movq	(%r15), %rcx
	testq	%rcx, %rcx
	je	LBB0_5
## %bb.4:
	xorl	%eax, %eax
	callq	*8(%rcx)
LBB0_5:
	movq	8(%r15), %rcx
	xorl	%ebx, %ebx
	testq	%rcx, %rcx
	je	LBB0_6
## %bb.7:
	movl	%r14d, %edi
	xorl	%esi, %esi
	callq	*(%rcx)
	movq	%rax, %r12
	jmp	LBB0_8
LBB0_6:
	xorl	%r12d, %r12d
LBB0_8:
	movq	%r12, %rdi
	callq	_abs
	cmpl	$16385, %eax                    ## imm = 0x4001
	jl	LBB0_10
LBB0_9:
	leal	1(%rbx), %eax
	testq	%r12, %r12
	notl	%ebx
	cmovnsl	%eax, %ebx
	jmp	LBB0_49
LBB0_10:
	movq	(%r15), %rax
	testq	%rax, %rax
	je	LBB0_12
## %bb.11:
	movl	%r14d, %edi
	xorl	%esi, %esi
	callq	*(%rax)
	movq	%rax, %r12
LBB0_12:
	movq	%r12, %rdi
	callq	_abs
	xorl	%ecx, %ecx
	cmpl	$16385, %eax                    ## imm = 0x4001
	jge	LBB0_13
## %bb.14:
	movq	8(%r15), %rcx
	testq	%rcx, %rcx
	je	LBB0_15
## %bb.16:
	movl	%r14d, %edi
	movl	$1, %esi
	callq	*(%rcx)
	movq	%rax, %r12
	jmp	LBB0_17
LBB0_15:
	xorl	%r12d, %r12d
LBB0_17:
	movq	%r12, %rdi
	callq	_abs
	movl	$1, %ebx
	cmpl	$16384, %eax                    ## imm = 0x4000
	jg	LBB0_9
## %bb.18:
	movq	(%r15), %rax
	testq	%rax, %rax
	je	LBB0_20
## %bb.19:
	movl	%r14d, %edi
	movl	$1, %esi
	callq	*(%rax)
	movq	%rax, %r12
LBB0_20:
	movq	%r12, %rdi
	callq	_abs
	movl	$1, %ecx
	cmpl	$16384, %eax                    ## imm = 0x4000
	jg	LBB0_13
## %bb.21:
	movq	8(%r15), %rcx
	testq	%rcx, %rcx
	je	LBB0_22
## %bb.23:
	movl	%r14d, %edi
	movl	$2, %esi
	callq	*(%rcx)
	movq	%rax, %r12
	jmp	LBB0_24
LBB0_22:
	xorl	%r12d, %r12d
LBB0_24:
	movq	%r12, %rdi
	callq	_abs
	movl	$2, %ebx
	cmpl	$16384, %eax                    ## imm = 0x4000
	jg	LBB0_9
## %bb.25:
	movq	(%r15), %rax
	testq	%rax, %rax
	je	LBB0_27
## %bb.26:
	movl	%r14d, %edi
	movl	$2, %esi
	callq	*(%rax)
	movq	%rax, %r12
LBB0_27:
	movq	%r12, %rdi
	callq	_abs
	movl	$2, %ecx
	cmpl	$16384, %eax                    ## imm = 0x4000
	jg	LBB0_13
## %bb.28:
	movq	8(%r15), %rcx
	testq	%rcx, %rcx
	je	LBB0_29
## %bb.30:
	movl	%r14d, %edi
	movl	$3, %esi
	callq	*(%rcx)
	movq	%rax, %r12
	jmp	LBB0_31
LBB0_29:
	xorl	%r12d, %r12d
LBB0_31:
	movq	%r12, %rdi
	callq	_abs
	movl	$3, %ebx
	cmpl	$16384, %eax                    ## imm = 0x4000
	jg	LBB0_9
## %bb.32:
	movq	(%r15), %rax
	testq	%rax, %rax
	je	LBB0_34
## %bb.33:
	movl	%r14d, %edi
	movl	$3, %esi
	callq	*(%rax)
	movq	%rax, %r12
LBB0_34:
	movq	%r12, %rdi
	callq	_abs
	movl	$3, %ecx
	cmpl	$16384, %eax                    ## imm = 0x4000
	jle	LBB0_35
LBB0_13:
	leal	1(%rcx), %eax
	testq	%r12, %r12
	notl	%ecx
	cmovnsl	%eax, %ecx
	movl	%ecx, %ebx
LBB0_49:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_35:
	movq	8(%r15), %rcx
	testq	%rcx, %rcx
	je	LBB0_36
## %bb.37:
	movl	%r14d, %edi
	movl	$4, %esi
	callq	*(%rcx)
	movq	%rax, %r12
	jmp	LBB0_38
LBB0_36:
	xorl	%r12d, %r12d
LBB0_38:
	movq	%r12, %rdi
	callq	_abs
	movl	$4, %ebx
	cmpl	$16384, %eax                    ## imm = 0x4000
	jg	LBB0_9
## %bb.39:
	movq	(%r15), %rax
	testq	%rax, %rax
	je	LBB0_41
## %bb.40:
	movl	%r14d, %edi
	movl	$4, %esi
	callq	*(%rax)
	movq	%rax, %r12
LBB0_41:
	movq	%r12, %rdi
	callq	_abs
	movl	$4, %ecx
	cmpl	$16384, %eax                    ## imm = 0x4000
	jg	LBB0_13
## %bb.42:
	movq	8(%r15), %rcx
	testq	%rcx, %rcx
	je	LBB0_43
## %bb.44:
	movl	%r14d, %edi
	movl	$5, %esi
	callq	*(%rcx)
	movq	%rax, %r12
	jmp	LBB0_45
LBB0_43:
	xorl	%r12d, %r12d
LBB0_45:
	movq	%r12, %rdi
	callq	_abs
	movl	$5, %ebx
	cmpl	$16384, %eax                    ## imm = 0x4000
	jg	LBB0_9
## %bb.46:
	movq	(%r15), %rax
	testq	%rax, %rax
	je	LBB0_48
## %bb.47:
	movl	%r14d, %edi
	movl	$5, %esi
	callq	*(%rax)
	movq	%rax, %r12
LBB0_48:
	movq	%r12, %rdi
	callq	_abs
	xorl	%ebx, %ebx
	movl	$5, %ecx
	cmpl	$16384, %eax                    ## imm = 0x4000
	jg	LBB0_13
	jmp	LBB0_49
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cocoa_input_find_any_axis      ; -- Begin function cocoa_input_find_any_axis
	.p2align	2
_cocoa_input_find_any_axis:             ; @cocoa_input_find_any_axis
	.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
	mov	x19, x0
	bl	_input_driver_get_data
	mov	x20, x0
	cbz	x0, LBB0_5
; %bb.1:
	ldr	x8, [x20, #8]
	cbz	x8, LBB0_3
; %bb.2:
	ldr	x8, [x8, #8]
	blr	x8
LBB0_3:
	ldr	x8, [x20]
	cbz	x8, LBB0_5
; %bb.4:
	ldr	x8, [x8, #8]
	blr	x8
LBB0_5:
	ldr	x8, [x20, #8]
	cbz	x8, LBB0_7
; %bb.6:
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #0
	blr	x8
	mov	x21, x0
	b	LBB0_8
LBB0_7:
	mov	x21, #0
LBB0_8:
	mov	x0, x21
	bl	_abs
	cmp	w0, #4, lsl #12                 ; =16384
	b.gt	LBB0_12
; %bb.9:
	ldr	x8, [x20]
	cbz	x8, LBB0_11
; %bb.10:
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #0
	blr	x8
	mov	x21, x0
LBB0_11:
	mov	x0, x21
	bl	_abs
	cmp	w0, #4, lsl #12                 ; =16384
	b.le	LBB0_13
LBB0_12:
	mov	w8, #0
	b	LBB0_53
LBB0_13:
	ldr	x8, [x20, #8]
	cbz	x8, LBB0_15
; %bb.14:
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #1
	blr	x8
	mov	x21, x0
	b	LBB0_16
LBB0_15:
	mov	x21, #0
LBB0_16:
	mov	x0, x21
	bl	_abs
	cmp	w0, #4, lsl #12                 ; =16384
	b.gt	LBB0_20
; %bb.17:
	ldr	x8, [x20]
	cbz	x8, LBB0_19
; %bb.18:
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #1
	blr	x8
	mov	x21, x0
LBB0_19:
	mov	x0, x21
	bl	_abs
	cmp	w0, #4, lsl #12                 ; =16384
	b.le	LBB0_21
LBB0_20:
	mov	w8, #1
	b	LBB0_53
LBB0_21:
	ldr	x8, [x20, #8]
	cbz	x8, LBB0_23
; %bb.22:
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #2
	blr	x8
	mov	x21, x0
	b	LBB0_24
LBB0_23:
	mov	x21, #0
LBB0_24:
	mov	x0, x21
	bl	_abs
	cmp	w0, #4, lsl #12                 ; =16384
	b.gt	LBB0_28
; %bb.25:
	ldr	x8, [x20]
	cbz	x8, LBB0_27
; %bb.26:
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #2
	blr	x8
	mov	x21, x0
LBB0_27:
	mov	x0, x21
	bl	_abs
	cmp	w0, #4, lsl #12                 ; =16384
	b.le	LBB0_29
LBB0_28:
	mov	w8, #2
	b	LBB0_53
LBB0_29:
	ldr	x8, [x20, #8]
	cbz	x8, LBB0_31
; %bb.30:
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #3
	blr	x8
	mov	x21, x0
	b	LBB0_32
LBB0_31:
	mov	x21, #0
LBB0_32:
	mov	x0, x21
	bl	_abs
	cmp	w0, #4, lsl #12                 ; =16384
	b.gt	LBB0_36
; %bb.33:
	ldr	x8, [x20]
	cbz	x8, LBB0_35
; %bb.34:
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #3
	blr	x8
	mov	x21, x0
LBB0_35:
	mov	x0, x21
	bl	_abs
	cmp	w0, #4, lsl #12                 ; =16384
	b.le	LBB0_37
LBB0_36:
	mov	w8, #3
	b	LBB0_53
LBB0_37:
	ldr	x8, [x20, #8]
	cbz	x8, LBB0_39
; %bb.38:
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #4
	blr	x8
	mov	x21, x0
	b	LBB0_40
LBB0_39:
	mov	x21, #0
LBB0_40:
	mov	x0, x21
	bl	_abs
	cmp	w0, #4, lsl #12                 ; =16384
	b.gt	LBB0_44
; %bb.41:
	ldr	x8, [x20]
	cbz	x8, LBB0_43
; %bb.42:
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #4
	blr	x8
	mov	x21, x0
LBB0_43:
	mov	x0, x21
	bl	_abs
	cmp	w0, #4, lsl #12                 ; =16384
	b.le	LBB0_45
LBB0_44:
	mov	w8, #4
	b	LBB0_53
LBB0_45:
	ldr	x8, [x20, #8]
	cbz	x8, LBB0_47
; %bb.46:
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #5
	blr	x8
	mov	x21, x0
	b	LBB0_48
LBB0_47:
	mov	x21, #0
LBB0_48:
	mov	x0, x21
	bl	_abs
	cmp	w0, #4, lsl #12                 ; =16384
	b.gt	LBB0_52
; %bb.49:
	ldr	x8, [x20]
	cbz	x8, LBB0_51
; %bb.50:
	ldr	x8, [x8]
	mov	x0, x19
	mov	w1, #5
	blr	x8
	mov	x21, x0
LBB0_51:
	mov	x0, x21
	bl	_abs
	cmp	w0, #4, lsl #12                 ; =16384
	b.le	LBB0_55
LBB0_52:
	mov	w8, #5
LBB0_53:
	mvn	w9, w8
	cmp	x21, #0
	csinc	w0, w9, w8, lt
LBB0_54:
	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_55:
	mov	w0, #0
	b	LBB0_54
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
