	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function coff_apply_checksum
_coff_apply_checksum:                   ## @coff_apply_checksum
	.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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	_SEEK_SET@GOTPCREL(%rip), %r12
	movl	(%r12), %edx
	movl	$60, %esi
	callq	_bfd_seek
	movq	_FALSE@GOTPCREL(%rip), %r15
	testq	%rax, %rax
	je	LBB0_1
LBB0_6:
	movl	(%r15), %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	_peheader@GOTPCREL(%rip), %r14
	movq	%rbx, %rdi
	movq	%r14, %rsi
	callq	_coff_read_word
	testl	%eax, %eax
	je	LBB0_6
## %bb.2:
	movl	(%r14), %esi
	addl	$88, %esi
	movl	(%r12), %edx
	movq	%rbx, %rdi
	callq	_bfd_seek
	testq	%rax, %rax
	jne	LBB0_6
## %bb.3:
	movl	$0, -36(%rbp)
	leaq	-36(%rbp), %rdi
	movl	$4, %esi
	movq	%rbx, %rdx
	callq	_bfd_bwrite
	movl	(%r14), %esi
	movl	(%r12), %edx
	movq	%rbx, %rdi
	callq	_bfd_seek
	testq	%rax, %rax
	jne	LBB0_6
## %bb.4:
	movq	%rbx, %rdi
	callq	_coff_compute_checksum
	movq	_pelength@GOTPCREL(%rip), %rcx
	addl	(%rcx), %eax
	movl	%eax, -36(%rbp)
	movl	(%r14), %esi
	addl	$88, %esi
	movl	(%r12), %edx
	movq	%rbx, %rdi
	callq	_bfd_seek
	testq	%rax, %rax
	jne	LBB0_6
## %bb.5:
	leaq	-36(%rbp), %rdi
	movl	$4, %esi
	movq	%rbx, %rdx
	callq	_bfd_bwrite
	movq	_TRUE@GOTPCREL(%rip), %r15
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.comm	_SEEK_SET,4,2                   ## @SEEK_SET
	.comm	_FALSE,4,2                      ## @FALSE
	.comm	_peheader,4,2                   ## @peheader
	.comm	_pelength,4,2                   ## @pelength
	.comm	_TRUE,4,2                       ## @TRUE
	.no_dead_strip	_coff_apply_checksum
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function coff_apply_checksum
_coff_apply_checksum:                   ; @coff_apply_checksum
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x0
Lloh0:
	adrp	x21, _SEEK_SET@GOTPAGE
Lloh1:
	ldr	x21, [x21, _SEEK_SET@GOTPAGEOFF]
	ldr	w2, [x21]
	mov	w1, #60
	bl	_bfd_seek
	cbz	x0, LBB0_3
LBB0_1:
Lloh2:
	adrp	x8, _FALSE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
LBB0_2:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
LBB0_3:
Lloh4:
	adrp	x20, _peheader@GOTPAGE
Lloh5:
	ldr	x20, [x20, _peheader@GOTPAGEOFF]
	mov	x0, x19
	mov	x1, x20
	bl	_coff_read_word
	cbz	w0, LBB0_1
; %bb.4:
	ldr	w8, [x20]
	add	w1, w8, #88
	ldr	w2, [x21]
	mov	x0, x19
	bl	_bfd_seek
	cbnz	x0, LBB0_1
; %bb.5:
	str	wzr, [sp, #12]
	add	x0, sp, #12
	mov	w1, #4
	mov	x2, x19
	bl	_bfd_bwrite
	ldr	w1, [x20]
	ldr	w2, [x21]
	mov	x0, x19
	bl	_bfd_seek
	cbnz	x0, LBB0_1
; %bb.6:
	mov	x0, x19
	bl	_coff_compute_checksum
Lloh6:
	adrp	x8, _pelength@GOTPAGE
Lloh7:
	ldr	x8, [x8, _pelength@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	add	w8, w8, w0
	str	w8, [sp, #12]
	ldr	w8, [x20]
	add	w1, w8, #88
	ldr	w2, [x21]
	mov	x0, x19
	bl	_bfd_seek
	cbnz	x0, LBB0_1
; %bb.7:
	add	x0, sp, #12
	mov	w1, #4
	mov	x2, x19
	bl	_bfd_bwrite
Lloh9:
	adrp	x8, _TRUE@GOTPAGE
Lloh10:
	ldr	x8, [x8, _TRUE@GOTPAGEOFF]
	b	LBB0_2
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_SEEK_SET,4,2                   ; @SEEK_SET
	.comm	_FALSE,4,2                      ; @FALSE
	.comm	_peheader,4,2                   ; @peheader
	.comm	_pelength,4,2                   ; @pelength
	.comm	_TRUE,4,2                       ; @TRUE
	.no_dead_strip	_coff_apply_checksum
.subsections_via_symbols
