	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function magicmouse_raw_event
LCPI0_0:
	.long	3221225472                      ## 0xc0000000
	.long	3221225472                      ## 0xc0000000
	.space	4
	.space	4
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_magicmouse_raw_event:                  ## @magicmouse_raw_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	%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
	movl	%ecx, %ebx
	movq	%rdx, %r12
	movq	%rsi, %r15
	movq	%rdi, %r14
	callq	_hid_get_drvdata
	movq	%rax, %rdi
	movl	(%r12), %eax
	xorl	%r13d, %r13d
	addl	$-128, %eax
	cmpl	$4, %eax
	ja	LBB0_33
## %bb.1:
	movq	8(%rdi), %rcx
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_2:
	cmpl	$4, %ebx
	jl	LBB0_33
## %bb.3:
	leal	-4(%rbx), %eax
	imull	$954437177, %eax, %ecx          ## imm = 0x38E38E39
	cmpl	$477218588, %ecx                ## imm = 0x1C71C71C
	ja	LBB0_33
## %bb.4:
	cmpl	$148, %ebx
	jb	LBB0_7
## %bb.5:
	leaq	L_.str(%rip), %rsi
	jmp	LBB0_6
LBB0_11:
	cmpl	$12, %ebx
	jl	LBB0_33
## %bb.12:
	leal	-12(%rbx), %eax
	imull	$954437177, %eax, %ecx          ## imm = 0x38E38E39
	cmpl	$477218588, %ecx                ## imm = 0x1C71C71C
	ja	LBB0_33
## %bb.13:
	cmpl	$156, %ebx
	jb	LBB0_15
## %bb.14:
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_6
LBB0_18:
	cmpl	$6, %ebx
	jl	LBB0_33
## %bb.19:
	leal	-6(%rbx), %eax
	testb	$7, %al
	jne	LBB0_33
## %bb.20:
	cmpl	$134, %ebx
	jb	LBB0_22
## %bb.21:
	leaq	L_.str.2(%rip), %rsi
LBB0_6:
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_hid_warn
	jmp	LBB0_33
LBB0_26:
	leaq	8(%r12), %rdx
	movl	4(%r12), %ecx
	movq	%rdi, %r13
	movq	%r14, %rdi
	movq	%r15, %rsi
	callq	_magicmouse_raw_event
	movslq	4(%r12), %rax
	leaq	(%r12,%rax,4), %rdx
	addq	$8, %rdx
	subl	%eax, %ebx
	addl	$-2, %ebx
	movq	%r14, %rdi
	movq	%r15, %rsi
	movl	%ebx, %ecx
	callq	_magicmouse_raw_event
	movq	%r13, %rdi
	pxor	%xmm0, %xmm0
	xorl	%r14d, %r14d
	jmp	LBB0_27
LBB0_7:
	movl	$0, (%rdi)
	cmpl	$9, %eax
	jb	LBB0_10
## %bb.8:
	imulq	$954437177, %rax, %rax          ## imm = 0x38E38E39
	shrq	$33, %rax
	movl	%eax, %r15d
	leaq	16(%r12), %r14
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rdi, %r13
	movl	%ebx, %esi
	movq	%r14, %rdx
	callq	_magicmouse_emit_touch
	movq	%r13, %rdi
	incq	%rbx
	addq	$36, %r14
	cmpq	%rbx, %r15
	jne	LBB0_9
	jmp	LBB0_10
LBB0_15:
	movl	$0, (%rdi)
	cmpl	$9, %eax
	jb	LBB0_10
## %bb.16:
	imulq	$954437177, %rax, %rax          ## imm = 0x38E38E39
	shrq	$33, %rax
	movl	%eax, %r15d
	leaq	48(%r12), %r14
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_17:                                ## =>This Inner Loop Header: Depth=1
	movq	%rdi, %r13
	movl	%ebx, %esi
	movq	%r14, %rdx
	callq	_magicmouse_emit_touch
	movq	%r13, %rdi
	incq	%rbx
	addq	$36, %r14
	cmpq	%rbx, %r15
	jne	LBB0_17
LBB0_10:
	movl	4(%r12), %r14d
	pxor	%xmm0, %xmm0
	jmp	LBB0_27
LBB0_22:
	movl	$0, (%rdi)
	cmpl	$8, %eax
	jb	LBB0_25
## %bb.23:
	shrl	$3, %eax
	cmpl	$2, %eax
	movl	$1, %r15d
	cmovael	%eax, %r15d
	leaq	24(%r12), %r14
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_24:                                ## =>This Inner Loop Header: Depth=1
	movq	%rdi, %r13
	movl	%ebx, %esi
	movq	%r14, %rdx
	callq	_magicmouse_emit_touch
	movq	%r13, %rdi
	incq	%rbx
	addq	$32, %r14
	cmpq	%rbx, %r15
	jne	LBB0_24
LBB0_25:
	movl	12(%r12), %r14d
	movd	%r14d, %xmm0
	pshufd	$80, %xmm0, %xmm1               ## xmm1 = xmm0[0,0,1,1]
	pslld	$28, %xmm0
	pslld	$26, %xmm1
	pblendw	$243, %xmm0, %xmm1              ## xmm1 = xmm0[0,1],xmm1[2,3],xmm0[4,5,6,7]
	pand	LCPI0_0(%rip), %xmm1
	movq	4(%r12), %xmm0                  ## xmm0 = mem[0],zero
	pslld	$22, %xmm0
	por	%xmm1, %xmm0
	psrad	$22, %xmm0
LBB0_27:
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	movq	(%rbx), %rax
	movq	_USB_DEVICE_ID_APPLE_MAGICMOUSE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_29
## %bb.28:
	andl	$3, %r14d
	movl	%r14d, %esi
	movdqa	%xmm0, -64(%rbp)                ## 16-byte Spill
	callq	_magicmouse_emit_buttons
	movq	_REL_X@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movdqa	-64(%rbp), %xmm0                ## 16-byte Reload
	movd	%xmm0, %edx
	movq	%rbx, %rdi
	callq	_input_report_rel
	movq	_REL_Y@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movdqa	-64(%rbp), %xmm0                ## 16-byte Reload
	pextrd	$1, %xmm0, %edx
	movq	%rbx, %rdi
	callq	_input_report_rel
	jmp	LBB0_32
LBB0_29:
	movq	_USB_DEVICE_ID_APPLE_MAGICTRACKPAD2@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_31
## %bb.30:
	movq	%rbx, %rdi
	callq	_input_mt_sync_frame
	movq	_BTN_MOUSE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	andl	$1, %r14d
	movq	%rbx, %rdi
	movl	%r14d, %edx
	callq	_input_report_key
	jmp	LBB0_32
LBB0_31:
	movq	_BTN_MOUSE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	andl	$1, %r14d
	movq	%rbx, %rdi
	movl	%r14d, %edx
	callq	_input_report_key
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_input_mt_report_pointer_emulation
LBB0_32:
	movq	%rbx, %rdi
	callq	_input_sync
	movl	$1, %r13d
LBB0_33:
	movl	%r13d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_2, LBB0_2-LJTI0_0
.set L0_0_set_11, LBB0_11-LJTI0_0
.set L0_0_set_18, LBB0_18-LJTI0_0
.set L0_0_set_26, LBB0_26-LJTI0_0
LJTI0_0:
	.long	L0_0_set_2
	.long	L0_0_set_11
	.long	L0_0_set_2
	.long	L0_0_set_18
	.long	L0_0_set_26
	.end_data_region
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"invalid size value (%d) for TRACKPAD_REPORT_ID\n"

L_.str.1:                               ## @.str.1
	.asciz	"invalid size value (%d) for TRACKPAD2_USB_REPORT_ID\n"

L_.str.2:                               ## @.str.2
	.asciz	"invalid size value (%d) for MOUSE_REPORT_ID\n"

	.comm	_USB_DEVICE_ID_APPLE_MAGICMOUSE,8,3 ## @USB_DEVICE_ID_APPLE_MAGICMOUSE
	.comm	_REL_X,4,2                      ## @REL_X
	.comm	_REL_Y,4,2                      ## @REL_Y
	.comm	_USB_DEVICE_ID_APPLE_MAGICTRACKPAD2,8,3 ## @USB_DEVICE_ID_APPLE_MAGICTRACKPAD2
	.comm	_BTN_MOUSE,4,2                  ## @BTN_MOUSE
	.no_dead_strip	_magicmouse_raw_event
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function magicmouse_raw_event
lCPI0_0:
	.long	28                              ; 0x1c
	.long	26                              ; 0x1a
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	2
_magicmouse_raw_event:                  ; @magicmouse_raw_event
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x22, x3
	mov	x21, x2
	mov	x24, x1
	mov	x23, x0
	bl	_hid_get_drvdata
	ldr	w8, [x21]
	sub	w8, w8, #128
	cmp	w8, #4
	b.hi	LBB0_12
; %bb.1:
	mov	x20, x0
	ldr	x19, [x0, #8]
Lloh0:
	adrp	x9, lJTI0_0@PAGE
Lloh1:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_2
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_2:
	subs	w8, w22, #4
	b.lt	LBB0_12
; %bb.3:
	mov	w9, #36409
	movk	w9, #14563, lsl #16
	umull	x9, w8, w9
	lsr	x9, x9, #33
	add	w10, w9, w9, lsl #3
	cmp	w8, w10
	b.ne	LBB0_12
; %bb.4:
	cmp	w22, #148
	b.lo	LBB0_17
; %bb.5:
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_16
LBB0_6:
	subs	w8, w22, #12
	b.lt	LBB0_12
; %bb.7:
	mov	w9, #36409
	movk	w9, #14563, lsl #16
	umull	x9, w8, w9
	lsr	x9, x9, #33
	add	w10, w9, w9, lsl #3
	cmp	w8, w10
	b.ne	LBB0_12
; %bb.8:
	cmp	w22, #156
	b.lo	LBB0_20
; %bb.9:
Lloh4:
	adrp	x1, l_.str.1@PAGE
Lloh5:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_16
LBB0_10:
	subs	w8, w22, #6
	b.lt	LBB0_12
; %bb.11:
	tst	w8, #0x7
	b.eq	LBB0_14
LBB0_12:
	mov	w0, #0
	b	LBB0_34
LBB0_13:
	add	x25, x21, #8
	ldr	w3, [x21, #4]
	mov	x0, x23
	mov	x1, x24
	mov	x2, x25
	bl	_magicmouse_raw_event
	ldrsw	x8, [x21, #4]
	add	x2, x25, x8, lsl #2
	sub	w8, w22, w8
	sub	w3, w8, #2
	mov	x0, x23
	mov	x1, x24
	bl	_magicmouse_raw_event
	mov	w22, #0
	movi.2d	v0, #0000000000000000
	b	LBB0_28
LBB0_14:
	cmp	w22, #134
	b.lo	LBB0_24
; %bb.15:
Lloh6:
	adrp	x1, l_.str.2@PAGE
Lloh7:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_16:
	mov	x0, x23
	mov	x2, x22
	bl	_hid_warn
	mov	w0, #0
	b	LBB0_34
LBB0_17:
	str	wzr, [x20]
	cmp	w8, #9
	b.lo	LBB0_23
; %bb.18:
	mov	x22, #0
	mov	w24, w9
	add	x23, x21, #16
LBB0_19:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	mov	x1, x22
	mov	x2, x23
	bl	_magicmouse_emit_touch
	add	x22, x22, #1
	add	x23, x23, #36
	cmp	x24, x22
	b.ne	LBB0_19
	b	LBB0_23
LBB0_20:
	str	wzr, [x20]
	cmp	w8, #9
	b.lo	LBB0_23
; %bb.21:
	mov	x22, #0
	mov	w24, w9
	add	x23, x21, #48
LBB0_22:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	mov	x1, x22
	mov	x2, x23
	bl	_magicmouse_emit_touch
	add	x22, x22, #1
	add	x23, x23, #36
	cmp	x24, x22
	b.ne	LBB0_22
LBB0_23:
	movi.2d	v0, #0000000000000000
	ldr	w22, [x21, #4]
	b	LBB0_28
LBB0_24:
	str	wzr, [x20]
	cmp	w8, #8
	b.lo	LBB0_27
; %bb.25:
	mov	x22, #0
	lsr	w8, w8, #3
	cmp	w8, #1
	csinc	w24, w8, wzr, hi
	add	x23, x21, #24
LBB0_26:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	mov	x1, x22
	mov	x2, x23
	bl	_magicmouse_emit_touch
	add	x22, x22, #1
	add	x23, x23, #32
	cmp	x24, x22
	b.ne	LBB0_26
LBB0_27:
	ldr	w22, [x21, #12]
	dup.2s	v0, w22
Lloh8:
	adrp	x8, lCPI0_0@PAGE
Lloh9:
	ldr	d1, [x8, lCPI0_0@PAGEOFF]
	ushl.2s	v0, v0, v1
	movi.2s	v1, #192, lsl #24
	and.8b	v0, v0, v1
	ldur	d1, [x21, #4]
	shl.2s	v1, v1, #22
	orr.8b	v0, v0, v1
	sshr.2s	v0, v0, #22
LBB0_28:
	ldr	x8, [x19]
Lloh10:
	adrp	x9, _USB_DEVICE_ID_APPLE_MAGICMOUSE@GOTPAGE
Lloh11:
	ldr	x9, [x9, _USB_DEVICE_ID_APPLE_MAGICMOUSE@GOTPAGEOFF]
Lloh12:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_30
; %bb.29:
	and	w1, w22, #0x3
	mov	x0, x20
	str	q0, [sp]                        ; 16-byte Folded Spill
	bl	_magicmouse_emit_buttons
Lloh13:
	adrp	x8, _REL_X@GOTPAGE
Lloh14:
	ldr	x8, [x8, _REL_X@GOTPAGEOFF]
Lloh15:
	ldr	w1, [x8]
	ldr	q0, [sp]                        ; 16-byte Folded Reload
	fmov	w2, s0
	mov	x0, x19
	bl	_input_report_rel
Lloh16:
	adrp	x8, _REL_Y@GOTPAGE
Lloh17:
	ldr	x8, [x8, _REL_Y@GOTPAGEOFF]
Lloh18:
	ldr	w1, [x8]
	ldr	q0, [sp]                        ; 16-byte Folded Reload
	mov.s	w2, v0[1]
	mov	x0, x19
	bl	_input_report_rel
	b	LBB0_33
LBB0_30:
Lloh19:
	adrp	x9, _USB_DEVICE_ID_APPLE_MAGICTRACKPAD2@GOTPAGE
Lloh20:
	ldr	x9, [x9, _USB_DEVICE_ID_APPLE_MAGICTRACKPAD2@GOTPAGEOFF]
Lloh21:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_32
; %bb.31:
	mov	x0, x19
	bl	_input_mt_sync_frame
Lloh22:
	adrp	x8, _BTN_MOUSE@GOTPAGE
Lloh23:
	ldr	x8, [x8, _BTN_MOUSE@GOTPAGEOFF]
Lloh24:
	ldr	w1, [x8]
	and	w2, w22, #0x1
	mov	x0, x19
	bl	_input_report_key
	b	LBB0_33
LBB0_32:
Lloh25:
	adrp	x8, _BTN_MOUSE@GOTPAGE
Lloh26:
	ldr	x8, [x8, _BTN_MOUSE@GOTPAGEOFF]
Lloh27:
	ldr	w1, [x8]
	and	w2, w22, #0x1
	mov	x0, x19
	bl	_input_report_key
	mov	x0, x19
	mov	w1, #1
	bl	_input_mt_report_pointer_emulation
LBB0_33:
	mov	x0, x19
	bl	_input_sync
	mov	w0, #1
LBB0_34:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdr	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_6-LBB0_2)>>2
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_10-LBB0_2)>>2
	.byte	(LBB0_13-LBB0_2)>>2
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"invalid size value (%d) for TRACKPAD_REPORT_ID\n"

l_.str.1:                               ; @.str.1
	.asciz	"invalid size value (%d) for TRACKPAD2_USB_REPORT_ID\n"

l_.str.2:                               ; @.str.2
	.asciz	"invalid size value (%d) for MOUSE_REPORT_ID\n"

	.comm	_USB_DEVICE_ID_APPLE_MAGICMOUSE,8,3 ; @USB_DEVICE_ID_APPLE_MAGICMOUSE
	.comm	_REL_X,4,2                      ; @REL_X
	.comm	_REL_Y,4,2                      ; @REL_Y
	.comm	_USB_DEVICE_ID_APPLE_MAGICTRACKPAD2,8,3 ; @USB_DEVICE_ID_APPLE_MAGICTRACKPAD2
	.comm	_BTN_MOUSE,4,2                  ; @BTN_MOUSE
	.no_dead_strip	_magicmouse_raw_event
.subsections_via_symbols
