	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sha512_done                    ## -- Begin function sha512_done
	.p2align	4, 0x90
_sha512_done:                           ## @sha512_done
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	(%rdi), %r15d
	movl	$-1, %eax
	cmpl	$7, %r15d
	ja	LBB0_7
## %bb.1:
	movq	%rsi, %r14
	movq	%rdi, %rbx
	movl	$8, %edi
	callq	_CONST64
	imull	%r15d, %eax
	addl	%eax, 4(%rbx)
	movq	8(%rbx), %rax
	movslq	(%rbx), %rcx
	leal	1(%rcx), %edx
	movl	%edx, (%rbx)
	movb	$-128, (%rax,%rcx)
	movl	(%rbx), %eax
	cmpl	$113, %eax
	jl	LBB0_5
## %bb.2:
	cmpl	$127, %eax
	ja	LBB0_4
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%rbx), %rcx
	leal	1(%rax), %edx
	movl	%edx, (%rbx)
	cltq
	movb	$0, (%rcx,%rax)
	movl	(%rbx), %eax
	cmpl	$128, %eax
	jl	LBB0_3
LBB0_4:
	movq	8(%rbx), %rsi
	movq	%rbx, %rdi
	callq	_sha512_compress
	xorl	%eax, %eax
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%rbx), %rcx
	leal	1(%rax), %edx
	movl	%edx, (%rbx)
	cltq
	movb	$0, (%rcx,%rax)
	movl	(%rbx), %eax
	cmpl	$120, %eax
	jl	LBB0_5
## %bb.6:
	movq	8(%rbx), %rdi
	addq	$120, %rdi
	movl	4(%rbx), %esi
	callq	_WPA_PUT_BE64
	movq	8(%rbx), %rsi
	movq	%rbx, %rdi
	callq	_sha512_compress
	movq	16(%rbx), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_WPA_PUT_BE64
	leaq	8(%r14), %rdi
	movq	16(%rbx), %rax
	movl	4(%rax), %esi
	callq	_WPA_PUT_BE64
	leaq	16(%r14), %rdi
	movq	16(%rbx), %rax
	movl	8(%rax), %esi
	callq	_WPA_PUT_BE64
	leaq	24(%r14), %rdi
	movq	16(%rbx), %rax
	movl	12(%rax), %esi
	callq	_WPA_PUT_BE64
	leaq	32(%r14), %rdi
	movq	16(%rbx), %rax
	movl	16(%rax), %esi
	callq	_WPA_PUT_BE64
	leaq	40(%r14), %rdi
	movq	16(%rbx), %rax
	movl	20(%rax), %esi
	callq	_WPA_PUT_BE64
	leaq	48(%r14), %rdi
	movq	16(%rbx), %rax
	movl	24(%rax), %esi
	callq	_WPA_PUT_BE64
	addq	$56, %r14
	movq	16(%rbx), %rax
	movl	28(%rax), %esi
	movq	%r14, %rdi
	callq	_WPA_PUT_BE64
	xorl	%eax, %eax
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sha512_done                    ; -- Begin function sha512_done
	.p2align	2
_sha512_done:                           ; @sha512_done
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	ldr	w21, [x0]
	cmp	w21, #7
	b.ls	LBB0_2
; %bb.1:
	mov	w0, #-1
	b	LBB0_8
LBB0_2:
	mov	x20, x1
	mov	x19, x0
	mov	w0, #8
	bl	_CONST64
	ldp	w9, w8, [x19]
                                        ; kill: def $w9 killed $w9 def $x9
	sxtw	x9, w9
	madd	w8, w0, w21, w8
	ldr	x10, [x19, #8]
	add	w11, w9, #1
	stp	w11, w8, [x19]
	mov	w8, #128
	strb	w8, [x10, x9]
	ldr	w8, [x19]
	cmp	w8, #113
	b.lt	LBB0_6
; %bb.3:
	cmp	w8, #127
	b.hi	LBB0_5
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x19, #8]
	add	w10, w8, #1
	str	w10, [x19]
	strb	wzr, [x9, w8, sxtw]
	ldr	w8, [x19]
	cmp	w8, #128
	b.lt	LBB0_4
LBB0_5:
	ldr	x1, [x19, #8]
	mov	x0, x19
	bl	_sha512_compress
	mov	w8, #0
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x19, #8]
	add	w10, w8, #1
	str	w10, [x19]
	strb	wzr, [x9, w8, sxtw]
	ldr	w8, [x19]
	cmp	w8, #120
	b.lt	LBB0_6
; %bb.7:
	ldr	x8, [x19, #8]
	add	x0, x8, #120
	ldr	w1, [x19, #4]
	bl	_WPA_PUT_BE64
	ldr	x1, [x19, #8]
	mov	x0, x19
	bl	_sha512_compress
	ldr	x8, [x19, #16]
	ldr	w1, [x8]
	mov	x0, x20
	bl	_WPA_PUT_BE64
	add	x0, x20, #8
	ldr	x8, [x19, #16]
	ldr	w1, [x8, #4]
	bl	_WPA_PUT_BE64
	add	x0, x20, #16
	ldr	x8, [x19, #16]
	ldr	w1, [x8, #8]
	bl	_WPA_PUT_BE64
	add	x0, x20, #24
	ldr	x8, [x19, #16]
	ldr	w1, [x8, #12]
	bl	_WPA_PUT_BE64
	add	x0, x20, #32
	ldr	x8, [x19, #16]
	ldr	w1, [x8, #16]
	bl	_WPA_PUT_BE64
	add	x0, x20, #40
	ldr	x8, [x19, #16]
	ldr	w1, [x8, #20]
	bl	_WPA_PUT_BE64
	add	x0, x20, #48
	ldr	x8, [x19, #16]
	ldr	w1, [x8, #24]
	bl	_WPA_PUT_BE64
	add	x0, x20, #56
	ldr	x8, [x19, #16]
	ldr	w1, [x8, #28]
	bl	_WPA_PUT_BE64
	mov	w0, #0
LBB0_8:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
