	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mceusb_process_ir_data
_mceusb_process_ir_data:                ## @mceusb_process_ir_data
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r12d
	movq	%rdi, %r15
	movq	_rawir@GOTPCREL(%rip), %rax
	movq	(%rax), %rdi
	callq	_DEFINE_IR_RAW_EVENT
	xorl	%eax, %eax
	cmpq	$0, 32(%r15)
	setne	%al
	addl	%eax, %eax
	cmpl	%r12d, %eax
	jge	LBB0_17
## %bb.1:
	movl	%eax, %ebx
	movl	%r12d, %r12d
	movl	(%r15), %eax
	leaq	LJTI0_0(%rip), %r14
	movq	%r12, -48(%rbp)                 ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_2 Depth=1
	movl	%eax, (%r15)
LBB0_15:                                ##   in Loop: Header=BB0_2 Depth=1
	incq	%rbx
	cmpq	%rbx, %r12
	je	LBB0_16
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	leal	-128(%rax), %edx
	movl	%eax, %ecx
	cmpl	$3, %edx
	ja	LBB0_12
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movslq	(%r14,%rdx,4), %rax
	addq	%r14, %rax
	jmpq	*%rax
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	8(%r15), %edi
	movq	16(%r15), %rax
	movl	(%rax,%rbx,4), %esi
	callq	_mceusb_cmdsize
                                        ## kill: def $eax killed $eax def $rax
	movl	%eax, 4(%r15)
	movq	16(%r15), %rsi
	leal	2(%rax), %ecx
	leal	-1(%rbx), %edx
	movq	%r15, %rdi
	xorl	%r8d, %r8d
	callq	_mceusb_dev_printdata
	movq	%r15, %rdi
	movl	%ebx, %esi
	callq	_mceusb_handle_command
	movl	$131, (%r15)
	movl	$131, %ecx
	jmp	LBB0_12
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	decl	4(%r15)
	movq	%r14, %r12
	movq	_rawir@GOTPCREL(%rip), %r14
	movq	%r14, %rdi
	callq	_init_ir_raw_event
	movq	16(%r15), %rax
	movq	_MCE_PULSE_BIT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	xorl	%edx, %edx
	andl	(%rax,%rbx,4), %ecx
	setne	%dl
	movl	%edx, (%r14)
	movq	_MCE_PULSE_MASK@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r13d
	andl	(%rax,%rbx,4), %r13d
	movq	_MCE_TIME_UNIT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_US_TO_NS
	imull	%eax, %r13d
	movl	%r13d, 4(%r14)
	movl	28(%r15), %edi
	cmpl	$0, (%r14)
	leaq	L_.str.1(%rip), %rdx
	leaq	L_.str.2(%rip), %rax
	cmoveq	%rax, %rdx
	leaq	L_.str(%rip), %rsi
	movl	%r13d, %ecx
	xorl	%eax, %eax
	callq	_dev_dbg
	movl	24(%r15), %edi
	movq	%r14, %rsi
	movq	%r12, %r14
	movq	-48(%rbp), %r12                 ## 8-byte Reload
	callq	_ir_raw_event_store_with_filter
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	16(%r15), %rsi
	movl	(%rsi,%rbx,4), %ecx
	movl	%ecx, 8(%r15)
	movl	$128, %eax
	movq	_MCE_COMMAND_HEADER@GOTPCREL(%rip), %rdx
	cmpl	(%rdx), %ecx
	je	LBB0_14
## %bb.8:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_MCE_COMMAND_MASK@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	andl	%ecx, %edx
	movq	_MCE_COMMAND_IRDATA@GOTPCREL(%rip), %rdi
	cmpl	(%rdi), %edx
	jne	LBB0_14
## %bb.9:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_MCE_PACKET_LENGTH_MASK@GOTPCREL(%rip), %rax
	andl	(%rax), %ecx
	movl	%ecx, 4(%r15)
	incl	%ecx
	movq	%r15, %rdi
	movl	%ebx, %edx
	xorl	%r8d, %r8d
	callq	_mceusb_dev_printdata
	movl	$129, %eax
	cmpl	$0, 4(%r15)
	jne	LBB0_14
## %bb.10:                              ##   in Loop: Header=BB0_2 Depth=1
	movl	24(%r15), %edi
	callq	_ir_raw_event_reset
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	decl	4(%r15)
LBB0_11:                                ##   in Loop: Header=BB0_2 Depth=1
	movl	(%r15), %ecx
	movl	$130, %eax
	cmpl	$130, %ecx
	je	LBB0_15
LBB0_12:                                ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$0, 4(%r15)
	movl	%ecx, %eax
	jne	LBB0_15
## %bb.13:                              ##   in Loop: Header=BB0_2 Depth=1
	movl	$130, %eax
	jmp	LBB0_14
LBB0_17:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_16:
	movl	28(%r15), %edi
	leaq	L_.str.3(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_dbg
	movl	24(%r15), %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ir_raw_event_handle            ## TAILCALL
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_4, LBB0_4-LJTI0_0
.set L0_0_set_5, LBB0_5-LJTI0_0
.set L0_0_set_7, LBB0_7-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
LJTI0_0:
	.long	L0_0_set_4
	.long	L0_0_set_5
	.long	L0_0_set_7
	.long	L0_0_set_6
	.end_data_region
                                        ## -- End function
	.comm	_rawir,8,2                      ## @rawir
	.comm	_MCE_PULSE_BIT,4,2              ## @MCE_PULSE_BIT
	.comm	_MCE_PULSE_MASK,4,2             ## @MCE_PULSE_MASK
	.comm	_MCE_TIME_UNIT,4,2              ## @MCE_TIME_UNIT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Storing %s with duration %d\n"

L_.str.1:                               ## @.str.1
	.asciz	"pulse"

L_.str.2:                               ## @.str.2
	.asciz	"space"

	.comm	_MCE_COMMAND_HEADER,4,2         ## @MCE_COMMAND_HEADER
	.comm	_MCE_COMMAND_MASK,4,2           ## @MCE_COMMAND_MASK
	.comm	_MCE_COMMAND_IRDATA,4,2         ## @MCE_COMMAND_IRDATA
	.comm	_MCE_PACKET_LENGTH_MASK,4,2     ## @MCE_PACKET_LENGTH_MASK
L_.str.3:                               ## @.str.3
	.asciz	"processed IR data, calling ir_raw_event_handle\n"

	.no_dead_strip	_mceusb_process_ir_data
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mceusb_process_ir_data
_mceusb_process_ir_data:                ; @mceusb_process_ir_data
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x22, x1
	mov	x19, x0
Lloh0:
	adrp	x20, _rawir@GOTPAGE
Lloh1:
	ldr	x20, [x20, _rawir@GOTPAGEOFF]
	ldr	x0, [x20]
	bl	_DEFINE_IR_RAW_EVENT
	ldr	x8, [x19, #32]
	cmp	x8, #0
	cset	w8, ne
	lsl	w21, w8, #1
	cmp	w21, w22
	b.ge	LBB0_18
; %bb.1:
	mov	w23, w22
	ldr	w8, [x19]
Lloh2:
	adrp	x24, lJTI0_0@PAGE
Lloh3:
	add	x24, x24, lJTI0_0@PAGEOFF
Lloh4:
	adrp	x28, l_.str.1@PAGE
Lloh5:
	add	x28, x28, l_.str.1@PAGEOFF
Lloh6:
	adrp	x25, _MCE_COMMAND_HEADER@GOTPAGE
Lloh7:
	ldr	x25, [x25, _MCE_COMMAND_HEADER@GOTPAGEOFF]
Lloh8:
	adrp	x26, l_.str.2@PAGE
Lloh9:
	add	x26, x26, l_.str.2@PAGEOFF
Lloh10:
	adrp	x22, l_.str@PAGE
Lloh11:
	add	x22, x22, l_.str@PAGEOFF
	b	LBB0_5
LBB0_2:                                 ;   in Loop: Header=BB0_5 Depth=1
	mov	w8, #128
LBB0_3:                                 ;   in Loop: Header=BB0_5 Depth=1
	str	w8, [x19]
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	add	x21, x21, #1
	cmp	x23, x21
	b.eq	LBB0_19
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	sub	w9, w8, #128
	cmp	w9, #3
	b.hi	LBB0_15
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	adr	x8, LBB0_7
	ldrb	w10, [x24, x9]
	add	x8, x8, x10, lsl #2
	br	x8
LBB0_7:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldr	w0, [x19, #8]
	ldr	x8, [x19, #16]
	ldr	w1, [x8, x21, lsl #2]
	bl	_mceusb_cmdsize
	str	w0, [x19, #4]
	ldr	x1, [x19, #16]
	add	w3, w0, #2
	sub	w2, w21, #1
	mov	x0, x19
	mov	w4, #0
	bl	_mceusb_dev_printdata
	mov	x0, x19
	mov	x1, x21
	bl	_mceusb_handle_command
	mov	w8, #131
	str	w8, [x19]
	b	LBB0_15
LBB0_8:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [x19, #4]
	sub	w8, w8, #1
	str	w8, [x19, #4]
	mov	x0, x20
	bl	_init_ir_raw_event
	ldr	x8, [x19, #16]
	lsl	x9, x21, #2
	ldr	w10, [x8, x9]
Lloh12:
	adrp	x11, _MCE_PULSE_BIT@GOTPAGE
Lloh13:
	ldr	x11, [x11, _MCE_PULSE_BIT@GOTPAGEOFF]
Lloh14:
	ldr	w11, [x11]
	tst	w11, w10
	cset	w10, ne
	str	w10, [x20]
	ldr	w8, [x8, x9]
Lloh15:
	adrp	x9, _MCE_PULSE_MASK@GOTPAGE
Lloh16:
	ldr	x9, [x9, _MCE_PULSE_MASK@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	and	w27, w9, w8
Lloh18:
	adrp	x8, _MCE_TIME_UNIT@GOTPAGE
Lloh19:
	ldr	x8, [x8, _MCE_TIME_UNIT@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x8]
	bl	_US_TO_NS
	mul	w8, w0, w27
	str	w8, [x20, #4]
	ldr	w0, [x19, #28]
	ldr	w9, [x20]
	cmp	w9, #0
	csel	x9, x26, x28, eq
	stp	x9, x8, [sp]
	mov	x1, x22
	bl	_dev_dbg
	ldr	w0, [x19, #24]
	mov	x1, x20
	bl	_ir_raw_event_store_with_filter
	b	LBB0_14
LBB0_9:                                 ;   in Loop: Header=BB0_5 Depth=1
	ldr	x1, [x19, #16]
	ldr	w8, [x1, x21, lsl #2]
	str	w8, [x19, #8]
	ldr	w9, [x25]
	cmp	w8, w9
	b.eq	LBB0_2
; %bb.10:                               ;   in Loop: Header=BB0_5 Depth=1
Lloh21:
	adrp	x9, _MCE_COMMAND_MASK@GOTPAGE
Lloh22:
	ldr	x9, [x9, _MCE_COMMAND_MASK@GOTPAGEOFF]
Lloh23:
	ldr	w9, [x9]
	and	w9, w9, w8
Lloh24:
	adrp	x10, _MCE_COMMAND_IRDATA@GOTPAGE
Lloh25:
	ldr	x10, [x10, _MCE_COMMAND_IRDATA@GOTPAGEOFF]
Lloh26:
	ldr	w10, [x10]
	cmp	w9, w10
	b.ne	LBB0_2
; %bb.11:                               ;   in Loop: Header=BB0_5 Depth=1
Lloh27:
	adrp	x9, _MCE_PACKET_LENGTH_MASK@GOTPAGE
Lloh28:
	ldr	x9, [x9, _MCE_PACKET_LENGTH_MASK@GOTPAGEOFF]
Lloh29:
	ldr	w9, [x9]
	and	w8, w9, w8
	str	w8, [x19, #4]
	add	w3, w8, #1
	mov	x0, x19
	mov	x2, x21
	mov	w4, #0
	bl	_mceusb_dev_printdata
	ldr	w8, [x19, #4]
	cbz	w8, LBB0_17
; %bb.12:                               ;   in Loop: Header=BB0_5 Depth=1
	mov	w8, #129
	b	LBB0_3
LBB0_13:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [x19, #4]
	sub	w8, w8, #1
	str	w8, [x19, #4]
LBB0_14:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w8, [x19]
	cmp	w8, #130
	b.eq	LBB0_4
LBB0_15:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w9, [x19, #4]
	cbnz	w9, LBB0_4
; %bb.16:                               ;   in Loop: Header=BB0_5 Depth=1
	mov	w8, #130
	b	LBB0_3
LBB0_17:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	w0, [x19, #24]
	bl	_ir_raw_event_reset
	b	LBB0_14
LBB0_18:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_19:
	ldr	w0, [x19, #28]
Lloh30:
	adrp	x1, l_.str.3@PAGE
Lloh31:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_dev_dbg
	ldr	w0, [x19, #24]
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	b	_ir_raw_event_handle
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh30, Lloh31
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_7-LBB0_7)>>2
	.byte	(LBB0_8-LBB0_7)>>2
	.byte	(LBB0_9-LBB0_7)>>2
	.byte	(LBB0_13-LBB0_7)>>2
                                        ; -- End function
	.comm	_rawir,8,2                      ; @rawir
	.comm	_MCE_PULSE_BIT,4,2              ; @MCE_PULSE_BIT
	.comm	_MCE_PULSE_MASK,4,2             ; @MCE_PULSE_MASK
	.comm	_MCE_TIME_UNIT,4,2              ; @MCE_TIME_UNIT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Storing %s with duration %d\n"

l_.str.1:                               ; @.str.1
	.asciz	"pulse"

l_.str.2:                               ; @.str.2
	.asciz	"space"

	.comm	_MCE_COMMAND_HEADER,4,2         ; @MCE_COMMAND_HEADER
	.comm	_MCE_COMMAND_MASK,4,2           ; @MCE_COMMAND_MASK
	.comm	_MCE_COMMAND_IRDATA,4,2         ; @MCE_COMMAND_IRDATA
	.comm	_MCE_PACKET_LENGTH_MASK,4,2     ; @MCE_PACKET_LENGTH_MASK
l_.str.3:                               ; @.str.3
	.asciz	"processed IR data, calling ir_raw_event_handle\n"

	.no_dead_strip	_mceusb_process_ir_data
.subsections_via_symbols
