	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sha512_final
_sha512_final:                          ## @sha512_final
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r15
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	callq	_shash_desc_ctx
	movq	%rax, %rbx
	movq	(%rax), %rax
	movl	(%rax), %edi
	shll	$3, %edi
	callq	_cpu_to_be64
	movl	%eax, -36(%rbp)
	callq	_cpu_to_be64
	movl	%eax, -40(%rbp)
	movq	(%rbx), %rax
	movl	(%rax), %eax
	andl	$127, %eax
	xorl	%edx, %edx
	cmpl	$112, %eax
	setae	%dl
	shll	$7, %edx
	subl	%eax, %edx
	addl	$112, %edx
	leaq	_sha512_final.padding(%rip), %rsi
	movq	%r15, %rdi
	callq	_sha512_update
	leaq	-40(%rbp), %rsi
	movq	%r15, %rdi
	movl	$8, %edx
	callq	_sha512_update
	movq	8(%rbx), %rax
	movl	(%rax), %edi
	callq	_cpu_to_be64
	movl	%eax, (%r14)
	movq	8(%rbx), %rax
	movl	4(%rax), %edi
	callq	_cpu_to_be64
	movl	%eax, 4(%r14)
	movq	8(%rbx), %rax
	movl	8(%rax), %edi
	callq	_cpu_to_be64
	movl	%eax, 8(%r14)
	movq	8(%rbx), %rax
	movl	12(%rax), %edi
	callq	_cpu_to_be64
	movl	%eax, 12(%r14)
	movq	8(%rbx), %rax
	movl	16(%rax), %edi
	callq	_cpu_to_be64
	movl	%eax, 16(%r14)
	movq	8(%rbx), %rax
	movl	20(%rax), %edi
	callq	_cpu_to_be64
	movl	%eax, 20(%r14)
	movq	8(%rbx), %rax
	movl	24(%rax), %edi
	callq	_cpu_to_be64
	movl	%eax, 24(%r14)
	movq	8(%rbx), %rax
	movl	28(%rax), %edi
	callq	_cpu_to_be64
	movl	%eax, 28(%r14)
	movq	%rbx, %rdi
	xorl	%esi, %esi
	movl	$16, %edx
	callq	_memset
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-32(%rbp), %rax
	jne	LBB0_2
## %bb.1:
	xorl	%eax, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__DATA,__data
	.p2align	4                               ## @sha512_final.padding
_sha512_final.padding:
	.long	128                             ## 0x80
	.space	508

	.no_dead_strip	_sha512_final
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sha512_final
_sha512_final:                          ; @sha512_final
	.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, x1
	mov	x21, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #8]
	bl	_shash_desc_ctx
	mov	x20, x0
	ldr	x8, [x0]
	ldr	w8, [x8]
	lsl	w0, w8, #3
	bl	_cpu_to_be64
	str	w0, [sp, #4]
	bl	_cpu_to_be64
	str	w0, [sp]
	ldr	x8, [x20]
	ldr	w8, [x8]
	and	w8, w8, #0x7f
	mov	w9, #240
	mov	w10, #112
	cmp	w8, #112
	csel	w9, w10, w9, lo
	sub	w2, w9, w8
Lloh3:
	adrp	x1, _sha512_final.padding@PAGE
Lloh4:
	add	x1, x1, _sha512_final.padding@PAGEOFF
	mov	x0, x21
	bl	_sha512_update
	mov	x1, sp
	mov	x0, x21
	mov	w2, #8
	bl	_sha512_update
	ldr	x8, [x20, #8]
	ldr	w0, [x8]
	bl	_cpu_to_be64
	str	w0, [x19]
	ldr	x8, [x20, #8]
	ldr	w0, [x8, #4]
	bl	_cpu_to_be64
	str	w0, [x19, #4]
	ldr	x8, [x20, #8]
	ldr	w0, [x8, #8]
	bl	_cpu_to_be64
	str	w0, [x19, #8]
	ldr	x8, [x20, #8]
	ldr	w0, [x8, #12]
	bl	_cpu_to_be64
	str	w0, [x19, #12]
	ldr	x8, [x20, #8]
	ldr	w0, [x8, #16]
	bl	_cpu_to_be64
	str	w0, [x19, #16]
	ldr	x8, [x20, #8]
	ldr	w0, [x8, #20]
	bl	_cpu_to_be64
	str	w0, [x19, #20]
	ldr	x8, [x20, #8]
	ldr	w0, [x8, #24]
	bl	_cpu_to_be64
	str	w0, [x19, #24]
	ldr	x8, [x20, #8]
	ldr	w0, [x8, #28]
	bl	_cpu_to_be64
	str	w0, [x19, #28]
	mov	x0, x20
	mov	w1, #0
	mov	w2, #16
	bl	_memset
	ldr	x8, [sp, #8]
Lloh5:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh6:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_2
; %bb.1:
	mov	w0, #0
	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_2:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.section	__DATA,__data
	.p2align	2                               ; @sha512_final.padding
_sha512_final.padding:
	.long	128                             ; 0x80
	.space	508

	.no_dead_strip	_sha512_final
.subsections_via_symbols
