	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function DoTextdumpFile
_DoTextdumpFile:                        ## @DoTextdumpFile
	.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
	testl	$511, %esi                      ## imm = 0x1FF
	je	LBB0_1
## %bb.7:
	movq	_LOG_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	movq	%r8, %rdx
LBB0_8:
	xorl	%eax, %eax
	callq	_logmsg
LBB0_9:
	movq	_nerr@GOTPCREL(%rip), %rax
	incl	(%rax)
	movl	$-1, %eax
LBB0_17:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movl	%esi, %ebx
	testl	%esi, %esi
	jle	LBB0_16
## %bb.2:
	movq	%rcx, %r12
	movl	%edx, %r13d
	movl	%edi, %r14d
	movq	%r9, -48(%rbp)                  ## 8-byte Spill
	movq	%r8, -56(%rbp)                  ## 8-byte Spill
	addl	$512, %ebx                      ## imm = 0x200
	addl	$-512, %r13d                    ## imm = 0xFE00
	xorl	%r15d, %r15d
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_15:                                ##   in Loop: Header=BB0_3 Depth=1
	addl	$-512, %ebx                     ## imm = 0xFE00
	addl	$-512, %r13d                    ## imm = 0xFE00
	cmpl	$512, %ebx                      ## imm = 0x200
	jle	LBB0_16
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movl	%r14d, %edi
	movq	%r12, %rsi
	movl	$512, %edx                      ## imm = 0x200
	movl	%r13d, %ecx
	callq	_pread
	cmpl	$512, %eax                      ## imm = 0x200
	jne	LBB0_4
## %bb.11:                              ##   in Loop: Header=BB0_3 Depth=1
	movq	%r12, %rdi
	movl	$1, %esi
	movl	$512, %edx                      ## imm = 0x200
	movq	16(%rbp), %rcx
	callq	_fwrite
	cmpl	$512, %eax                      ## imm = 0x200
	jne	LBB0_12
## %bb.13:                              ##   in Loop: Header=BB0_3 Depth=1
	movq	_verbose@GOTPCREL(%rip), %rax
	cmpq	$0, (%rax)
	je	LBB0_15
## %bb.14:                              ##   in Loop: Header=BB0_3 Depth=1
	addl	$512, %r15d                     ## imm = 0x200
	movslq	%r15d, %rsi
	leaq	L_.str.5(%rip), %rdi
	callq	_printf
	movq	_stdout@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_fflush
	jmp	LBB0_15
LBB0_16:
	xorl	%eax, %eax
	jmp	LBB0_17
LBB0_4:
	testl	%eax, %eax
	jne	LBB0_10
## %bb.5:
	movq	_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_6
LBB0_12:
	movq	_LOG_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.3(%rip), %rsi
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	xorl	%eax, %eax
	callq	_logmsg
	movq	_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.4(%rip), %rsi
LBB0_6:
	xorl	%eax, %eax
	callq	_logmsg
	jmp	LBB0_9
LBB0_10:
	movq	_LOG_ERR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	jmp	LBB0_8
	.cfi_endproc
                                        ## -- End function
	.comm	_LOG_ERR,4,2                    ## @LOG_ERR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"textdump uneven multiple of 512 on %s"

	.comm	_nerr,4,2                       ## @nerr
	.comm	_LOG_WARNING,4,2                ## @LOG_WARNING
L_.str.1:                               ## @.str.1
	.asciz	"WARNING: EOF on dump device"

L_.str.2:                               ## @.str.2
	.asciz	"read error on %s: %m"

L_.str.3:                               ## @.str.3
	.asciz	"write error on %s file: %m"

L_.str.4:                               ## @.str.4
	.asciz	"WARNING: textdump may be incomplete"

	.comm	_verbose,8,3                    ## @verbose
L_.str.5:                               ## @.str.5
	.asciz	"%llu\r"

	.comm	_stdout,4,2                     ## @stdout
	.no_dead_strip	_DoTextdumpFile
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function DoTextdumpFile
_DoTextdumpFile:                        ; @DoTextdumpFile
	.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	x19, x4
	tst	w1, #0x1ff
	b.eq	LBB0_4
; %bb.1:
Lloh0:
	adrp	x8, _LOG_ERR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _LOG_ERR@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	str	x19, [sp]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
LBB0_2:
	bl	_logmsg
Lloh5:
	adrp	x8, _nerr@GOTPAGE
Lloh6:
	ldr	x8, [x8, _nerr@GOTPAGEOFF]
	ldr	w9, [x8]
	add	w9, w9, #1
	str	w9, [x8]
	mov	w0, #-1
LBB0_3:
	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_4:
	cmp	w1, #1
	b.lt	LBB0_11
; %bb.5:
	mov	x21, x6
	mov	x20, x5
	mov	x22, x3
	mov	x23, x0
	mov	w26, #0
	add	w27, w1, #512
	sub	w24, w2, #512
Lloh7:
	adrp	x28, _verbose@GOTPAGE
Lloh8:
	ldr	x28, [x28, _verbose@GOTPAGEOFF]
Lloh9:
	adrp	x25, l_.str.5@PAGE
Lloh10:
	add	x25, x25, l_.str.5@PAGEOFF
	b	LBB0_7
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	sub	w27, w27, #512
	sub	w24, w24, #512
	cmp	w27, #512
	b.le	LBB0_11
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x23
	mov	x1, x22
	mov	w2, #512
	mov	x3, x24
	bl	_pread
	cmp	w0, #512
	b.ne	LBB0_12
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	x0, x22
	mov	w1, #1
	mov	w2, #512
	mov	x3, x21
	bl	_fwrite
	cmp	w0, #512
	b.ne	LBB0_14
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	x8, [x28]
	cbz	x8, LBB0_6
; %bb.10:                               ;   in Loop: Header=BB0_7 Depth=1
	add	w26, w26, #512
	sxtw	x1, w26
	mov	x0, x25
	bl	_printf
Lloh11:
	adrp	x8, _stdout@GOTPAGE
Lloh12:
	ldr	x8, [x8, _stdout@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	bl	_fflush
	b	LBB0_6
LBB0_11:
	mov	w0, #0
	b	LBB0_3
LBB0_12:
	cbnz	w0, LBB0_15
; %bb.13:
Lloh14:
	adrp	x8, _LOG_WARNING@GOTPAGE
Lloh15:
	ldr	x8, [x8, _LOG_WARNING@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
Lloh17:
	adrp	x1, l_.str.1@PAGE
Lloh18:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_2
LBB0_14:
Lloh19:
	adrp	x8, _LOG_ERR@GOTPAGE
Lloh20:
	ldr	x8, [x8, _LOG_ERR@GOTPAGEOFF]
Lloh21:
	ldr	w0, [x8]
	str	x20, [sp]
Lloh22:
	adrp	x1, l_.str.3@PAGE
Lloh23:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_logmsg
Lloh24:
	adrp	x8, _LOG_WARNING@GOTPAGE
Lloh25:
	ldr	x8, [x8, _LOG_WARNING@GOTPAGEOFF]
Lloh26:
	ldr	w0, [x8]
Lloh27:
	adrp	x1, l_.str.4@PAGE
Lloh28:
	add	x1, x1, l_.str.4@PAGEOFF
	b	LBB0_2
LBB0_15:
Lloh29:
	adrp	x8, _LOG_ERR@GOTPAGE
Lloh30:
	ldr	x8, [x8, _LOG_ERR@GOTPAGEOFF]
Lloh31:
	ldr	w0, [x8]
	str	x19, [sp]
Lloh32:
	adrp	x1, l_.str.2@PAGE
Lloh33:
	add	x1, x1, l_.str.2@PAGEOFF
	b	LBB0_2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpAdd	Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.cfi_endproc
                                        ; -- End function
	.comm	_LOG_ERR,4,2                    ; @LOG_ERR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"textdump uneven multiple of 512 on %s"

	.comm	_nerr,4,2                       ; @nerr
	.comm	_LOG_WARNING,4,2                ; @LOG_WARNING
l_.str.1:                               ; @.str.1
	.asciz	"WARNING: EOF on dump device"

l_.str.2:                               ; @.str.2
	.asciz	"read error on %s: %m"

l_.str.3:                               ; @.str.3
	.asciz	"write error on %s file: %m"

l_.str.4:                               ; @.str.4
	.asciz	"WARNING: textdump may be incomplete"

	.comm	_verbose,8,3                    ; @verbose
l_.str.5:                               ; @.str.5
	.asciz	"%llu\r"

	.comm	_stdout,4,2                     ; @stdout
	.no_dead_strip	_DoTextdumpFile
.subsections_via_symbols
