	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__kdc_get_preferred_key         ## -- Begin function _kdc_get_preferred_key
	.p2align	4, 0x90
__kdc_get_preferred_key:                ## @_kdc_get_preferred_key
	.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	%r8, -48(%rbp)                  ## 8-byte Spill
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	movq	%rdx, %r13
	movl	%edi, %r12d
	cmpq	$0, (%rsi)
	je	LBB0_8
## %bb.1:
	movq	%r9, %rbx
	movl	%r12d, %edi
	callq	_krb5_kerberos_enctypes
	movq	(%rax), %rsi
	movq	_ETYPE_NULL@GOTPCREL(%rip), %r15
	cmpq	(%r15), %rsi
	je	LBB0_16
## %bb.2:
	movq	%rax, %r14
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_4 Depth=1
	movq	8(%r14), %rsi
	addq	$8, %r14
	cmpq	(%r15), %rsi
	je	LBB0_16
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movl	%r12d, %edi
	callq	_krb5_enctype_valid
	testq	%rax, %rax
	jne	LBB0_3
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	(%r14), %rdx
	movl	%r12d, %edi
	movq	%r13, %rsi
	movq	%rbx, %rcx
	callq	_hdb_enctype2key
	testq	%rax, %rax
	jne	LBB0_3
## %bb.6:
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	testq	%rcx, %rcx
	je	LBB0_19
## %bb.7:
	movq	(%r14), %rax
	jmp	LBB0_15
LBB0_8:
	movq	$0, (%r9)
	cmpl	$0, (%r13)
	jle	LBB0_16
## %bb.9:
	movq	%r9, %r14
	xorl	%ebx, %ebx
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_10:                                ##   in Loop: Header=BB0_11 Depth=1
	incq	%rbx
	movslq	(%r13), %rax
	cmpq	%rax, %rbx
	jge	LBB0_16
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r13), %rax
	movq	(%rax,%rbx,8), %rsi
	movl	%r12d, %edi
	callq	_krb5_enctype_valid
	testq	%rax, %rax
	jne	LBB0_10
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	8(%r13), %rax
	movq	(%rax,%rbx,8), %rdx
	movl	%r12d, %edi
	movq	%r13, %rsi
	movq	%r14, %rcx
	callq	_hdb_enctype2key
	testq	%rax, %rax
	jne	LBB0_10
## %bb.13:
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	testq	%rcx, %rcx
	je	LBB0_19
## %bb.14:
	movq	(%r14), %rax
	movq	(%rax), %rax
LBB0_15:
	movq	%rax, (%rcx)
	xorl	%eax, %eax
	jmp	LBB0_17
LBB0_16:
	movq	_EINVAL@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rsi
	leaq	L_.str(%rip), %rdx
	movl	%r12d, %edi
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	callq	_krb5_set_error_message
	movq	(%rbx), %rax
LBB0_17:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_19:
	xorl	%eax, %eax
	jmp	LBB0_17
	.cfi_endproc
                                        ## -- End function
	.comm	_ETYPE_NULL,8,3                 ## @ETYPE_NULL
	.comm	_EINVAL,8,3                     ## @EINVAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"No valid kerberos key found for %s"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	__kdc_get_preferred_key         ; -- Begin function _kdc_get_preferred_key
	.p2align	2
__kdc_get_preferred_key:                ; @_kdc_get_preferred_key
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x21, x5
	mov	x19, x4
	mov	x20, x3
	mov	x23, x2
	mov	x22, x0
	ldr	x8, [x1]
	cbz	x8, LBB0_8
; %bb.1:
	mov	x0, x22
	bl	_krb5_kerberos_enctypes
	ldr	x1, [x0]
Lloh0:
	adrp	x25, _ETYPE_NULL@GOTPAGE
Lloh1:
	ldr	x25, [x25, _ETYPE_NULL@GOTPAGEOFF]
	ldr	x8, [x25]
	cmp	x1, x8
	b.eq	LBB0_15
; %bb.2:
	mov	x24, x0
	b	LBB0_4
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	x1, [x24, #8]!
	ldr	x8, [x25]
	cmp	x1, x8
	b.eq	LBB0_15
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x22
	bl	_krb5_enctype_valid
	cbnz	x0, LBB0_3
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x2, [x24]
	mov	x0, x22
	mov	x1, x23
	mov	x3, x21
	bl	_hdb_enctype2key
	cbnz	x0, LBB0_3
; %bb.6:
	mov	x0, #0
	cbz	x19, LBB0_16
; %bb.7:
	ldr	x8, [x24]
	str	x8, [x19]
	b	LBB0_16
LBB0_8:
	str	xzr, [x21]
	ldr	w8, [x23]
	cmp	w8, #1
	b.lt	LBB0_15
; %bb.9:
	mov	x24, #0
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	add	x24, x24, #1
	ldrsw	x8, [x23]
	cmp	x24, x8
	b.ge	LBB0_15
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x23, #8]
	ldr	x1, [x8, x24, lsl #3]
	mov	x0, x22
	bl	_krb5_enctype_valid
	cbnz	x0, LBB0_10
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	ldr	x8, [x23, #8]
	ldr	x2, [x8, x24, lsl #3]
	mov	x0, x22
	mov	x1, x23
	mov	x3, x21
	bl	_hdb_enctype2key
	cbnz	x0, LBB0_10
; %bb.13:
	mov	x0, #0
	cbz	x19, LBB0_16
; %bb.14:
	ldr	x8, [x21]
	ldr	x8, [x8]
	str	x8, [x19]
	b	LBB0_16
LBB0_15:
Lloh2:
	adrp	x19, _EINVAL@GOTPAGE
Lloh3:
	ldr	x19, [x19, _EINVAL@GOTPAGEOFF]
	ldr	x1, [x19]
Lloh4:
	adrp	x2, l_.str@PAGE
Lloh5:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x22
	mov	x3, x20
	bl	_krb5_set_error_message
	ldr	x0, [x19]
LBB0_16:
	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
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.comm	_ETYPE_NULL,8,3                 ; @ETYPE_NULL
	.comm	_EINVAL,8,3                     ; @EINVAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"No valid kerberos key found for %s"

.subsections_via_symbols
