	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ldemul_choose_mode             ## -- Begin function ldemul_choose_mode
	.p2align	4, 0x90
_ldemul_choose_mode:                    ## @ldemul_choose_mode
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	movq	_ld_emulations@GOTPCREL(%rip), %rax
	movq	(%rax), %rbx
	cmpb	$103, (%rdi)
	jne	LBB0_3
## %bb.1:
	cmpb	$108, 1(%r14)
	jne	LBB0_3
## %bb.2:
	xorl	%eax, %eax
	cmpb	$100, 2(%r14)
	sete	%al
	leaq	(%rax,%rax,2), %rax
	addq	%rax, %r14
LBB0_3:
	movq	(%rbx), %rax
	testq	%rax, %rax
	je	LBB0_7
## %bb.4:
	addq	$8, %rbx
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_strcmp
	testq	%rax, %rax
	je	LBB0_8
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	(%rbx), %rax
	addq	$8, %rbx
	testq	%rax, %rax
	jne	LBB0_5
LBB0_7:
	leaq	L_.str(%rip), %rdi
	callq	__
	movq	%rax, %rdi
	movq	%r14, %rsi
	xorl	%eax, %eax
	callq	_einfo
	leaq	L_.str.1(%rip), %rdi
	callq	__
	movq	%rax, %rdi
	xorl	%eax, %eax
	callq	_einfo
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_ldemul_list_emulations
	leaq	L_.str.2(%rip), %rdi
	xorl	%eax, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_einfo                          ## TAILCALL
LBB0_8:
	movq	-8(%rbx), %rax
	movq	_ld_emulation@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ld_emulations,8,3              ## @ld_emulations
	.comm	_ld_emulation,8,3               ## @ld_emulation
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%P: unrecognised emulation mode: %s\n"

L_.str.1:                               ## @.str.1
	.asciz	"Supported emulations: "

	.comm	_stderr,4,2                     ## @stderr
L_.str.2:                               ## @.str.2
	.asciz	"%F\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ldemul_choose_mode             ; -- Begin function ldemul_choose_mode
	.p2align	2
_ldemul_choose_mode:                    ; @ldemul_choose_mode
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x19, x0
Lloh0:
	adrp	x8, _ld_emulations@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ld_emulations@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	ldrb	w9, [x0]
	cmp	w9, #103
	b.ne	LBB0_3
; %bb.1:
	ldrb	w9, [x19, #1]
	cmp	w9, #108
	b.ne	LBB0_3
; %bb.2:
	ldrb	w9, [x19, #2]
	cmp	w9, #100
	mov	w9, #3
	csel	x9, x9, xzr, eq
	add	x19, x19, x9
LBB0_3:
	ldr	x9, [x8]
	cbz	x9, LBB0_7
; %bb.4:
	add	x20, x8, #8
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x9]
	mov	x0, x19
	bl	_strcmp
	cbz	x0, LBB0_8
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	ldr	x9, [x20], #8
	cbnz	x9, LBB0_5
LBB0_7:
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	__
	str	x19, [sp]
	bl	_einfo
Lloh5:
	adrp	x0, l_.str.1@PAGE
Lloh6:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	__
	bl	_einfo
Lloh7:
	adrp	x8, _stderr@GOTPAGE
Lloh8:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
	bl	_ldemul_list_emulations
Lloh10:
	adrp	x0, l_.str.2@PAGE
Lloh11:
	add	x0, x0, l_.str.2@PAGEOFF
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	b	_einfo
LBB0_8:
	ldur	x8, [x20, #-8]
Lloh12:
	adrp	x9, _ld_emulation@GOTPAGE
Lloh13:
	ldr	x9, [x9, _ld_emulation@GOTPAGEOFF]
Lloh14:
	str	x8, [x9]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotStr	Lloh12, Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_ld_emulations,8,3              ; @ld_emulations
	.comm	_ld_emulation,8,3               ; @ld_emulation
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%P: unrecognised emulation mode: %s\n"

l_.str.1:                               ; @.str.1
	.asciz	"Supported emulations: "

	.comm	_stderr,4,2                     ; @stderr
l_.str.2:                               ; @.str.2
	.asciz	"%F\n"

.subsections_via_symbols
