	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function read_file
_read_file:                             ## @read_file
	.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
	movq	%rdi, %r13
	movl	(%rdi), %edi
	leaq	-44(%rbp), %rsi
	movl	$4, %edx
	callq	_read
	cmpl	$4, %eax
	jne	LBB0_9
## %bb.1:
	movq	_uf_minor@GOTPCREL(%rip), %r12
	leaq	-44(%rbp), %r15
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	%r14, %rdi
	movl	%ebx, %esi
	callq	_print_packets
	movq	%r14, %rdi
	callq	_free
	movl	(%r13), %edi
	movq	%r15, %rsi
	movl	$4, %edx
	callq	_read
	cmpl	$4, %eax
	jne	LBB0_9
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	-44(%rbp), %edi
	callq	_le32toh
	movl	%eax, %ebx
	movl	%eax, -44(%rbp)
	movl	%eax, %edi
	callq	_malloc
	movq	%rax, %r14
	testq	%rax, %rax
	jne	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_EX_SOFTWARE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_errx
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	(%r13), %edi
	movq	%r14, %rsi
	movl	%ebx, %edx
	callq	_read
	cmpl	%ebx, %eax
	je	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_err
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$2, (%r12)
	jne	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%r14, %rdi
	movl	%ebx, %esi
	callq	_fix_packets
	jmp	LBB0_8
LBB0_9:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EX_SOFTWARE,4,2                ## @EX_SOFTWARE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Out of memory."

	.comm	_EXIT_FAILURE,4,2               ## @EXIT_FAILURE
L_.str.1:                               ## @.str.1
	.asciz	"Could not read complete USB data payload"

	.comm	_uf_minor,4,2                   ## @uf_minor
	.no_dead_strip	_read_file
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function read_file
_read_file:                             ; @read_file
	.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	x19, x0
	ldr	w0, [x0]
	add	x1, sp, #12
	mov	w2, #4
	bl	_read
	cmp	w0, #4
	b.ne	LBB0_9
; %bb.1:
Lloh0:
	adrp	x24, _EX_SOFTWARE@GOTPAGE
Lloh1:
	ldr	x24, [x24, _EX_SOFTWARE@GOTPAGEOFF]
Lloh2:
	adrp	x20, l_.str@PAGE
Lloh3:
	add	x20, x20, l_.str@PAGEOFF
Lloh4:
	adrp	x25, _uf_minor@GOTPAGE
Lloh5:
	ldr	x25, [x25, _uf_minor@GOTPAGEOFF]
Lloh6:
	adrp	x26, _EXIT_FAILURE@GOTPAGE
Lloh7:
	ldr	x26, [x26, _EXIT_FAILURE@GOTPAGEOFF]
Lloh8:
	adrp	x21, l_.str.1@PAGE
Lloh9:
	add	x21, x21, l_.str.1@PAGEOFF
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x23
	mov	x1, x22
	bl	_print_packets
	mov	x0, x23
	bl	_free
	ldr	w0, [x19]
	add	x1, sp, #12
	mov	w2, #4
	bl	_read
	cmp	w0, #4
	b.ne	LBB0_9
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [sp, #12]
	bl	_le32toh
	mov	x22, x0
	str	w0, [sp, #12]
	bl	_malloc
	mov	x23, x0
	cbnz	x0, LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w0, [x24]
	mov	x1, x20
	bl	_errx
LBB0_5:                                 ;   in Loop: Header=BB0_3 Depth=1
	ldr	w0, [x19]
	mov	x1, x23
	mov	x2, x22
	bl	_read
	cmp	w0, w22
	b.eq	LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w0, [x26]
	mov	x1, x21
	bl	_err
LBB0_7:                                 ;   in Loop: Header=BB0_3 Depth=1
	ldr	w8, [x25]
	cmp	w8, #2
	b.ne	LBB0_2
; %bb.8:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x23
	mov	x1, x22
	bl	_fix_packets
	b	LBB0_2
LBB0_9:
	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	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_EX_SOFTWARE,4,2                ; @EX_SOFTWARE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Out of memory."

	.comm	_EXIT_FAILURE,4,2               ; @EXIT_FAILURE
l_.str.1:                               ; @.str.1
	.asciz	"Could not read complete USB data payload"

	.comm	_uf_minor,4,2                   ; @uf_minor
	.no_dead_strip	_read_file
.subsections_via_symbols
