	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cp_event
_cp_event:                              ## @cp_event
	.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
	movq	%rcx, %r14
	movq	%rdx, %r15
	movq	%rsi, %r12
	movq	%rdi, %rbx
	callq	_hid_get_drvdata
	movq	%rax, %rcx
	movq	_HID_CLAIMED_INPUT@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	xorl	%eax, %eax
	testl	%edx, (%rbx)
	je	LBB0_10
## %bb.1:
	movq	(%r12), %rdx
	testq	%rdx, %rdx
	je	LBB0_10
## %bb.2:
	movl	16(%r15), %esi
	testl	%esi, %esi
	je	LBB0_10
## %bb.3:
	movq	_CP_2WHEEL_MOUSE_HACK@GOTPCREL(%rip), %rdi
	testq	%rcx, (%rdi)
	je	LBB0_10
## %bb.4:
	cmpl	$589829, (%r15)                 ## imm = 0x90005
	jne	LBB0_6
## %bb.5:
	movq	_CP_2WHEEL_MOUSE_HACK_ON@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	%rsi, %rax
	orq	%rcx, %rax
	notq	%rsi
	andq	%rcx, %rsi
	testq	%r14, %r14
	cmovneq	%rax, %rsi
	movq	%rbx, %rdi
	callq	_hid_set_drvdata
	jmp	LBB0_9
LBB0_6:
	movq	8(%r15), %rdi
	movq	_REL_WHEEL@GOTPCREL(%rip), %rbx
	cmpq	(%rbx), %rdi
	jne	LBB0_10
## %bb.7:
	movq	_CP_2WHEEL_MOUSE_HACK_ON@GOTPCREL(%rip), %rdi
	testq	%rcx, (%rdi)
	je	LBB0_10
## %bb.8:
	movq	(%rdx), %rdi
	movq	_REL_HWHEEL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r14, %rcx
	callq	_input_event
LBB0_9:
	movl	$1, %eax
LBB0_10:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_HID_CLAIMED_INPUT,4,2          ## @HID_CLAIMED_INPUT
	.comm	_CP_2WHEEL_MOUSE_HACK,8,3       ## @CP_2WHEEL_MOUSE_HACK
	.comm	_CP_2WHEEL_MOUSE_HACK_ON,8,3    ## @CP_2WHEEL_MOUSE_HACK_ON
	.comm	_REL_WHEEL,8,3                  ## @REL_WHEEL
	.comm	_REL_HWHEEL,4,2                 ## @REL_HWHEEL
	.no_dead_strip	_cp_event
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cp_event
_cp_event:                              ; @cp_event
	.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, x3
	mov	x21, x2
	mov	x22, x1
	mov	x20, x0
	bl	_hid_get_drvdata
	ldr	w8, [x20]
Lloh0:
	adrp	x9, _HID_CLAIMED_INPUT@GOTPAGE
Lloh1:
	ldr	x9, [x9, _HID_CLAIMED_INPUT@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_10
; %bb.1:
	ldr	x8, [x22]
	cbz	x8, LBB0_10
; %bb.2:
	ldr	w1, [x21, #16]
	cbz	w1, LBB0_10
; %bb.3:
Lloh3:
	adrp	x9, _CP_2WHEEL_MOUSE_HACK@GOTPAGE
Lloh4:
	ldr	x9, [x9, _CP_2WHEEL_MOUSE_HACK@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	tst	x9, x0
	b.eq	LBB0_10
; %bb.4:
	ldr	w9, [x21]
	sub	w9, w9, #144, lsl #12           ; =589824
	cmp	w9, #5
	b.ne	LBB0_6
; %bb.5:
Lloh6:
	adrp	x8, _CP_2WHEEL_MOUSE_HACK_ON@GOTPAGE
Lloh7:
	ldr	x8, [x8, _CP_2WHEEL_MOUSE_HACK_ON@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	orr	x9, x8, x0
	bic	x8, x0, x8
	cmp	x19, #0
	csel	x1, x8, x9, eq
	mov	x0, x20
	bl	_hid_set_drvdata
	b	LBB0_9
LBB0_6:
	ldr	x9, [x21, #8]
Lloh9:
	adrp	x10, _REL_WHEEL@GOTPAGE
Lloh10:
	ldr	x10, [x10, _REL_WHEEL@GOTPAGEOFF]
Lloh11:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_10
; %bb.7:
Lloh12:
	adrp	x9, _CP_2WHEEL_MOUSE_HACK_ON@GOTPAGE
Lloh13:
	ldr	x9, [x9, _CP_2WHEEL_MOUSE_HACK_ON@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	tst	x9, x0
	b.eq	LBB0_10
; %bb.8:
	ldr	x0, [x8]
Lloh15:
	adrp	x8, _REL_HWHEEL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _REL_HWHEEL@GOTPAGEOFF]
Lloh17:
	ldr	w2, [x8]
	mov	x3, x19
	bl	_input_event
LBB0_9:
	mov	w0, #1
	b	LBB0_11
LBB0_10:
	mov	w0, #0
LBB0_11:
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_HID_CLAIMED_INPUT,4,2          ; @HID_CLAIMED_INPUT
	.comm	_CP_2WHEEL_MOUSE_HACK,8,3       ; @CP_2WHEEL_MOUSE_HACK
	.comm	_CP_2WHEEL_MOUSE_HACK_ON,8,3    ; @CP_2WHEEL_MOUSE_HACK_ON
	.comm	_REL_WHEEL,8,3                  ; @REL_WHEEL
	.comm	_REL_HWHEEL,4,2                 ; @REL_HWHEEL
	.no_dead_strip	_cp_event
.subsections_via_symbols
