	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_dnscrypt_pad                   ## -- Begin function dnscrypt_pad
	.p2align	4, 0x90
_dnscrypt_pad:                          ## @dnscrypt_pad
	.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
	movq	%rsi, %r12
	movq	_DNSCRYPT_MIN_PAD_LEN@GOTPCREL(%rip), %r15
	movq	(%r15), %rax
	addq	%rsi, %rax
	cmpq	%rdx, %rax
	ja	LBB0_8
## %bb.1:
	movq	%r8, %r13
	movq	%rcx, %rbx
	movq	%rdx, %r14
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	movq	_crypto_box_HALF_NONCEBYTES@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rcx,%rax,8), %rax
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	sete	%dil
	callq	_assert
	leaq	-56(%rbp), %rdi
	movl	$8, %esi
	movq	%rbx, %rdx
	movq	%r13, %rcx
	callq	_crypto_stream
	movq	(%r15), %rcx
	addq	%r12, %rcx
	movq	-56(%rbp), %rax
	movq	%r14, %rsi
	subq	%rcx, %rsi
	incq	%rsi
	movq	%rax, %rdx
	orq	%rsi, %rdx
	shrq	$32, %rdx
	je	LBB0_2
## %bb.3:
	xorl	%edx, %edx
	divq	%rsi
	movq	%rdx, %rbx
	jmp	LBB0_4
LBB0_2:
                                        ## kill: def $eax killed $eax killed $rax
	xorl	%edx, %edx
	divl	%esi
	movl	%edx, %ebx
LBB0_4:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	leaq	(%rax,%r12,8), %r15
	addq	%rcx, %rbx
	movq	_DNSCRYPT_BLOCK_SIZE@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	%rbx, %rax
	orq	%rcx, %rax
	shrq	$32, %rax
	je	LBB0_5
## %bb.6:
	movq	%rbx, %rax
	xorl	%edx, %edx
	divq	%rcx
	jmp	LBB0_7
LBB0_5:
	movl	%ebx, %eax
	xorl	%edx, %edx
	divl	%ecx
                                        ## kill: def $edx killed $edx def $rdx
LBB0_7:
	addq	%rcx, %rbx
	subq	%rdx, %rbx
	cmpq	%r14, %rbx
	cmovaeq	%r14, %rbx
	movq	%rbx, %rdx
	subq	%r12, %rdx
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_memset
	movq	$128, (%r15)
	movq	%rbx, %r12
LBB0_8:
	movq	%r12, %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_DNSCRYPT_MIN_PAD_LEN,8,3       ## @DNSCRYPT_MIN_PAD_LEN
	.comm	_crypto_box_HALF_NONCEBYTES,8,3 ## @crypto_box_HALF_NONCEBYTES
	.comm	_DNSCRYPT_BLOCK_SIZE,8,3        ## @DNSCRYPT_BLOCK_SIZE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_dnscrypt_pad                   ; -- Begin function dnscrypt_pad
	.p2align	2
_dnscrypt_pad:                          ; @dnscrypt_pad
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x19, x1
Lloh0:
	adrp	x24, _DNSCRYPT_MIN_PAD_LEN@GOTPAGE
Lloh1:
	ldr	x24, [x24, _DNSCRYPT_MIN_PAD_LEN@GOTPAGEOFF]
	ldr	x8, [x24]
	add	x8, x8, x1
	cmp	x8, x2
	b.hi	LBB0_2
; %bb.1:
	mov	x21, x4
	mov	x22, x3
	mov	x20, x2
	add	x23, x0, x19, lsl #3
Lloh2:
	adrp	x8, _crypto_box_HALF_NONCEBYTES@GOTPAGE
Lloh3:
	ldr	x8, [x8, _crypto_box_HALF_NONCEBYTES@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	ldr	x8, [x3, x8, lsl #3]
	ldr	x9, [x3]
	cmp	x8, x9
	cset	w0, eq
	bl	_assert
	add	x0, sp, #8
	mov	w1, #8
	mov	x2, x22
	mov	x3, x21
	bl	_crypto_stream
	ldr	x8, [x24]
	ldr	x9, [sp, #8]
	add	x8, x8, x19
	sub	x10, x20, x8
	add	x10, x10, #1
	udiv	x11, x9, x10
	msub	x9, x11, x10, x9
Lloh5:
	adrp	x10, _DNSCRYPT_BLOCK_SIZE@GOTPAGE
Lloh6:
	ldr	x10, [x10, _DNSCRYPT_BLOCK_SIZE@GOTPAGEOFF]
Lloh7:
	ldr	x10, [x10]
	add	x8, x9, x8
	add	x9, x8, x10
	udiv	x11, x8, x10
	neg	x8, x8
	madd	x8, x11, x10, x8
	add	x8, x9, x8
	cmp	x8, x20
	csel	x20, x8, x20, lo
	sub	x2, x20, x19
	mov	x0, x23
	mov	w1, #0
	bl	_memset
	mov	w8, #128
	str	x8, [x23]
	mov	x19, x20
LBB0_2:
	mov	x0, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_DNSCRYPT_MIN_PAD_LEN,8,3       ; @DNSCRYPT_MIN_PAD_LEN
	.comm	_crypto_box_HALF_NONCEBYTES,8,3 ; @crypto_box_HALF_NONCEBYTES
	.comm	_DNSCRYPT_BLOCK_SIZE,8,3        ; @DNSCRYPT_BLOCK_SIZE
.subsections_via_symbols
