	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function mip4_report_touch
LCPI0_0:
	.long	3840                            ## 0xf00
	.long	3840                            ## 0xf00
	.space	4
	.space	4
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_mip4_report_touch:                     ## @mip4_report_touch
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	cmpl	$1, (%rdi)
	movl	(%rsi), %r14d
	movq	%rdi, -72(%rbp)                 ## 8-byte Spill
	ja	LBB0_5
## %bb.1:
	movq	%rdi, %r15
	movl	$7, %edi
	callq	_BIT
	andl	%r14d, %eax
	movl	%eax, %r12d
	movl	$5, %edi
	callq	_BIT
	movl	$4, %edi
	callq	_BIT
	movl	(%rbx), %r14d
	movl	16(%rbx), %edx
	movd	4(%rbx), %xmm0                  ## xmm0 = mem[0],zero,zero,zero
	pshufd	$80, %xmm0, %xmm1               ## xmm1 = xmm0[0,0,1,1]
	pslld	$8, %xmm0
	pslld	$4, %xmm1
	pblendw	$243, %xmm0, %xmm1              ## xmm1 = xmm0[0,1],xmm1[2,3],xmm0[4,5,6,7]
	pand	LCPI0_0(%rip), %xmm1
	movq	8(%rbx), %xmm0                  ## xmm0 = mem[0],zero
	por	%xmm1, %xmm0
	cmpl	$0, (%r15)
	je	LBB0_2
## %bb.4:
	movl	24(%rbx), %eax
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	movl	28(%rbx), %eax
	jmp	LBB0_3
LBB0_5:
	movl	$2, %edi
	callq	_BIT
	movl	$1, %edi
	callq	_BIT
	movl	4(%rbx), %r12d
	xorl	%edi, %edi
	callq	_BIT
	movl	%eax, %ecx
	andl	%r12d, %ecx
	movd	8(%rbx), %xmm0                  ## xmm0 = mem[0],zero,zero,zero
	pshufd	$80, %xmm0, %xmm1               ## xmm1 = xmm0[0,0,1,1]
	pslld	$8, %xmm0
	pslld	$4, %xmm1
	pblendw	$243, %xmm0, %xmm1              ## xmm1 = xmm0[0,1],xmm1[2,3],xmm0[4,5,6,7]
	pand	LCPI0_0(%rip), %xmm1
	movq	12(%rbx), %xmm0                 ## xmm0 = mem[0],zero
	por	%xmm1, %xmm0
	movl	28(%rbx), %edx
	movl	36(%rbx), %eax
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	andl	$15, %edx
	shll	$8, %edx
	orl	32(%rbx), %edx
	movl	40(%rbx), %eax
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	jmp	LBB0_6
LBB0_2:
	movl	20(%rbx), %eax
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
LBB0_3:
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movl	%r12d, %ecx
LBB0_6:
	movl	%edx, -56(%rbp)                 ## 4-byte Spill
	movl	%ecx, -60(%rbp)                 ## 4-byte Spill
	andl	$15, %r14d
	movl	%r14d, %ebx
	subl	$1, %ebx
	setb	-41(%rbp)                       ## 1-byte Folded Spill
	movq	-72(%rbp), %r12                 ## 8-byte Reload
	movq	8(%r12), %rdi
	movd	%xmm0, %r13d
	pextrd	$1, %xmm0, %r15d
	movl	%edx, (%rsp)
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edx
	movl	%r13d, %r8d
	movl	%r15d, %r9d
	callq	_dev_dbg
	movq	_MIP4_MAX_FINGERS@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r14d
	setg	%al
	orb	-41(%rbp), %al                  ## 1-byte Folded Reload
	movzbl	%al, %edi
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_8
## %bb.7:
	movq	8(%r12), %rdi
	leaq	L_.str.1(%rip), %rsi
	movl	%ebx, %edx
	callq	_dev_err
	jmp	LBB0_11
LBB0_8:
	movl	4(%r12), %edi
	movl	%ebx, %esi
	callq	_input_mt_slot
	movl	4(%r12), %edi
	movq	_MT_TOOL_FINGER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	cmpl	$0, -60(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_10
## %bb.9:
	movl	$1, %edx
	callq	_input_mt_report_slot_state
	movl	4(%r12), %edi
	movq	_ABS_MT_POSITION_X@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r13d, %edx
	callq	_input_report_abs
	movl	4(%r12), %edi
	movq	_ABS_MT_POSITION_Y@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r15d, %edx
	callq	_input_report_abs
	movl	4(%r12), %edi
	movq	_ABS_MT_PRESSURE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-56(%rbp), %edx                 ## 4-byte Reload
	callq	_input_report_abs
	movl	4(%r12), %edi
	movq	_ABS_MT_TOUCH_MAJOR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-52(%rbp), %edx                 ## 4-byte Reload
	callq	_input_report_abs
	movl	4(%r12), %edi
	movq	_ABS_MT_TOUCH_MINOR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	-48(%rbp), %edx                 ## 4-byte Reload
	callq	_input_report_abs
	jmp	LBB0_11
LBB0_10:
	xorl	%edx, %edx
	callq	_input_mt_report_slot_state
LBB0_11:
	movl	4(%r12), %edi
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_input_mt_sync_frame            ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Screen - Slot: %d State: %d X: %04d Y: %04d Z: %d\n"

	.comm	_MIP4_MAX_FINGERS,4,2           ## @MIP4_MAX_FINGERS
L_.str.1:                               ## @.str.1
	.asciz	"Screen - invalid slot ID: %d\n"

	.comm	_MT_TOOL_FINGER,4,2             ## @MT_TOOL_FINGER
	.comm	_ABS_MT_POSITION_X,4,2          ## @ABS_MT_POSITION_X
	.comm	_ABS_MT_POSITION_Y,4,2          ## @ABS_MT_POSITION_Y
	.comm	_ABS_MT_PRESSURE,4,2            ## @ABS_MT_PRESSURE
	.comm	_ABS_MT_TOUCH_MAJOR,4,2         ## @ABS_MT_TOUCH_MAJOR
	.comm	_ABS_MT_TOUCH_MINOR,4,2         ## @ABS_MT_TOUCH_MINOR
	.no_dead_strip	_mip4_report_touch
.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 mip4_report_touch
lCPI0_0:
	.long	8                               ; 0x8
	.long	4                               ; 0x4
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	2
_mip4_report_touch:                     ; @mip4_report_touch
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x23, x1
	mov	x19, x0
	ldr	w8, [x0]
	ldr	w24, [x1]
	cmp	w8, #1
	b.hi	LBB0_3
; %bb.1:
	mov	w0, #7
	bl	_BIT
	and	w20, w0, w24
	mov	w0, #5
	bl	_BIT
	mov	w0, #4
	bl	_BIT
	ldr	w24, [x23]
	add	x8, x23, #4
	ld1r.2s	{ v0 }, [x8]
Lloh0:
	adrp	x8, lCPI0_0@PAGE
Lloh1:
	ldr	d1, [x8, lCPI0_0@PAGEOFF]
	ushl.2s	v0, v0, v1
	movi.2s	v1, #15, lsl #8
	and.8b	v0, v0, v1
	ldr	d1, [x23, #8]
	orr.8b	v0, v0, v1
	ldr	w21, [x23, #16]
	ldr	w8, [x19]
	cbz	w8, LBB0_4
; %bb.2:
	ldp	w22, w23, [x23, #24]
	b	LBB0_5
LBB0_3:
	mov	w0, #2
	bl	_BIT
	mov	w0, #1
	bl	_BIT
	ldr	w20, [x23, #4]
	mov	w0, #0
	bl	_BIT
	and	w20, w0, w20
	add	x8, x23, #8
	ld1r.2s	{ v0 }, [x8]
Lloh2:
	adrp	x8, lCPI0_0@PAGE
Lloh3:
	ldr	d1, [x8, lCPI0_0@PAGEOFF]
	ushl.2s	v0, v0, v1
	movi.2s	v1, #15, lsl #8
	and.8b	v0, v0, v1
	ldur	d1, [x23, #12]
	orr.8b	v0, v0, v1
	ldp	w8, w9, [x23, #28]
	ubfiz	w8, w8, #8, #4
	orr	w21, w8, w9
	ldp	w22, w23, [x23, #36]
	b	LBB0_5
LBB0_4:
	ldr	w22, [x23, #20]
	mov	x23, x22
LBB0_5:
	ands	w27, w24, #0xf
	cset	w28, eq
	sub	w26, w27, #1
	ldr	x0, [x19, #8]
	fmov	w25, s0
	mov.s	w24, v0[1]
Lloh4:
	adrp	x1, l_.str@PAGE
Lloh5:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x26
	mov	x3, x20
	mov	x4, x25
	mov	x5, x24
	mov	x6, x21
	bl	_dev_dbg
Lloh6:
	adrp	x8, _MIP4_MAX_FINGERS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _MIP4_MAX_FINGERS@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	cmp	w27, w8
	cset	w8, gt
	orr	w0, w28, w8
	bl	_unlikely
	cbz	x0, LBB0_7
; %bb.6:
	ldr	x0, [x19, #8]
Lloh9:
	adrp	x1, l_.str.1@PAGE
Lloh10:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x26
	bl	_dev_err
	b	LBB0_10
LBB0_7:
	ldr	w0, [x19, #4]
	mov	x1, x26
	bl	_input_mt_slot
	ldr	w0, [x19, #4]
Lloh11:
	adrp	x8, _MT_TOOL_FINGER@GOTPAGE
Lloh12:
	ldr	x8, [x8, _MT_TOOL_FINGER@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	cbz	w20, LBB0_9
; %bb.8:
	mov	w2, #1
	bl	_input_mt_report_slot_state
	ldr	w0, [x19, #4]
Lloh14:
	adrp	x8, _ABS_MT_POSITION_X@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ABS_MT_POSITION_X@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	mov	x2, x25
	bl	_input_report_abs
	ldr	w0, [x19, #4]
Lloh17:
	adrp	x8, _ABS_MT_POSITION_Y@GOTPAGE
Lloh18:
	ldr	x8, [x8, _ABS_MT_POSITION_Y@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	mov	x2, x24
	bl	_input_report_abs
	ldr	w0, [x19, #4]
Lloh20:
	adrp	x8, _ABS_MT_PRESSURE@GOTPAGE
Lloh21:
	ldr	x8, [x8, _ABS_MT_PRESSURE@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
	mov	x2, x21
	bl	_input_report_abs
	ldr	w0, [x19, #4]
Lloh23:
	adrp	x8, _ABS_MT_TOUCH_MAJOR@GOTPAGE
Lloh24:
	ldr	x8, [x8, _ABS_MT_TOUCH_MAJOR@GOTPAGEOFF]
Lloh25:
	ldr	w1, [x8]
	mov	x2, x22
	bl	_input_report_abs
	ldr	w0, [x19, #4]
Lloh26:
	adrp	x8, _ABS_MT_TOUCH_MINOR@GOTPAGE
Lloh27:
	ldr	x8, [x8, _ABS_MT_TOUCH_MINOR@GOTPAGEOFF]
Lloh28:
	ldr	w1, [x8]
	mov	x2, x23
	bl	_input_report_abs
	b	LBB0_10
LBB0_9:
	mov	w2, #0
	bl	_input_mt_report_slot_state
LBB0_10:
	ldr	w0, [x19, #4]
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_input_mt_sync_frame
	.loh AdrpLdr	Lloh0, Lloh1
	.loh AdrpLdr	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Screen - Slot: %d State: %d X: %04d Y: %04d Z: %d\n"

	.comm	_MIP4_MAX_FINGERS,4,2           ; @MIP4_MAX_FINGERS
l_.str.1:                               ; @.str.1
	.asciz	"Screen - invalid slot ID: %d\n"

	.comm	_MT_TOOL_FINGER,4,2             ; @MT_TOOL_FINGER
	.comm	_ABS_MT_POSITION_X,4,2          ; @ABS_MT_POSITION_X
	.comm	_ABS_MT_POSITION_Y,4,2          ; @ABS_MT_POSITION_Y
	.comm	_ABS_MT_PRESSURE,4,2            ; @ABS_MT_PRESSURE
	.comm	_ABS_MT_TOUCH_MAJOR,4,2         ; @ABS_MT_TOUCH_MAJOR
	.comm	_ABS_MT_TOUCH_MINOR,4,2         ; @ABS_MT_TOUCH_MINOR
	.no_dead_strip	_mip4_report_touch
.subsections_via_symbols
