	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mips_elf64_final_gp
_mips_elf64_final_gp:                   ## @mips_elf64_final_gp
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r8, %r12
	movq	%rcx, %r14
	movq	%rdx, %rbx
	movq	%rsi, %r13
	movq	%rdi, %r15
	movq	8(%rsi), %rdi
	callq	_bfd_is_und_section
	testq	%rbx, %rbx
	jne	LBB0_3
## %bb.1:
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	movq	$0, (%r12)
	movq	_bfd_reloc_undefined@GOTPCREL(%rip), %r14
	jmp	LBB0_9
LBB0_3:
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movq	%r15, %rdi
	callq	__bfd_get_gp_value
	movq	%rax, (%r12)
	movq	_bfd_reloc_ok@GOTPCREL(%rip), %r14
	testq	%rax, %rax
	je	LBB0_4
LBB0_9:
	movl	(%r14), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	testq	%rbx, %rbx
	je	LBB0_7
## %bb.5:
	movq	_BSF_SECTION_SYM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r13)
	je	LBB0_9
## %bb.6:
	movq	8(%r13), %rax
	movq	(%rax), %rax
	movq	(%rax), %rsi
	movq	%rsi, (%r12)
	movq	%r15, %rdi
	callq	__bfd_set_gp_value
	jmp	LBB0_9
LBB0_7:
	movq	%r15, %rdi
	movq	%r12, %rsi
	callq	_mips_elf64_assign_gp
	testl	%eax, %eax
	jne	LBB0_9
## %bb.8:
	leaq	L_.str(%rip), %rdi
	callq	__
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
	movq	_bfd_reloc_dangerous@GOTPCREL(%rip), %r14
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.comm	_bfd_reloc_undefined,4,2        ## @bfd_reloc_undefined
	.comm	_BSF_SECTION_SYM,4,2            ## @BSF_SECTION_SYM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"GP relative relocation when _gp not defined"

	.comm	_bfd_reloc_dangerous,4,2        ## @bfd_reloc_dangerous
	.comm	_bfd_reloc_ok,4,2               ## @bfd_reloc_ok
	.no_dead_strip	_mips_elf64_final_gp
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mips_elf64_final_gp
_mips_elf64_final_gp:                   ; @mips_elf64_final_gp
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x4
	mov	x20, x3
	mov	x23, x2
	mov	x22, x1
	mov	x21, x0
	ldr	x0, [x1, #8]
	bl	_bfd_is_und_section
	cbnz	x23, LBB0_3
; %bb.1:
	cbz	x0, LBB0_3
; %bb.2:
	str	xzr, [x19]
Lloh0:
	adrp	x8, _bfd_reloc_undefined@GOTPAGE
Lloh1:
	ldr	x8, [x8, _bfd_reloc_undefined@GOTPAGEOFF]
	b	LBB0_5
LBB0_3:
	mov	x0, x21
	bl	__bfd_get_gp_value
	str	x0, [x19]
	cbz	x0, LBB0_6
LBB0_4:
Lloh2:
	adrp	x8, _bfd_reloc_ok@GOTPAGE
Lloh3:
	ldr	x8, [x8, _bfd_reloc_ok@GOTPAGEOFF]
LBB0_5:
	ldr	w0, [x8]
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_6:
	cbz	x23, LBB0_9
; %bb.7:
	ldr	w8, [x22]
Lloh4:
	adrp	x9, _BSF_SECTION_SYM@GOTPAGE
Lloh5:
	ldr	x9, [x9, _BSF_SECTION_SYM@GOTPAGEOFF]
Lloh6:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_4
; %bb.8:
	ldr	x8, [x22, #8]
	ldr	x8, [x8]
	ldr	x1, [x8]
	str	x1, [x19]
	mov	x0, x21
	bl	__bfd_set_gp_value
	b	LBB0_4
LBB0_9:
	mov	x0, x21
	mov	x1, x19
	bl	_mips_elf64_assign_gp
	cbnz	w0, LBB0_4
; %bb.10:
Lloh7:
	adrp	x0, l_.str@PAGE
Lloh8:
	add	x0, x0, l_.str@PAGEOFF
	bl	__
	str	x0, [x20]
Lloh9:
	adrp	x8, _bfd_reloc_dangerous@GOTPAGE
Lloh10:
	ldr	x8, [x8, _bfd_reloc_dangerous@GOTPAGEOFF]
	b	LBB0_5
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_bfd_reloc_undefined,4,2        ; @bfd_reloc_undefined
	.comm	_BSF_SECTION_SYM,4,2            ; @BSF_SECTION_SYM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"GP relative relocation when _gp not defined"

	.comm	_bfd_reloc_dangerous,4,2        ; @bfd_reloc_dangerous
	.comm	_bfd_reloc_ok,4,2               ; @bfd_reloc_ok
	.no_dead_strip	_mips_elf64_final_gp
.subsections_via_symbols
