	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_create_elf                     ## -- Begin function create_elf
	.p2align	4, 0x90
_create_elf:                            ## @create_elf
	.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	$104, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	movq	_SYMTAB_INTACT@GOTPCREL(%rip), %r13
	movl	(%rdi), %eax
	movl	104(%rdi), %edi
	orl	(%r13), %eax
	movl	%eax, (%r15)
	movq	_SYMTAB_EXIST@GOTPCREL(%rip), %r12
	movl	(%r12), %ecx
	notl	%ecx
	andl	%eax, %ecx
	movl	%ecx, (%r15)
	leaq	-144(%rbp), %rsi
	callq	_gelf_getehdr
	testq	%rax, %rax
	jne	LBB0_2
## %bb.1:
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	$-1, %edi
	callq	_elf_errmsg
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_2:
	movl	104(%r15), %edi
	callq	_gelf_getclass
	movq	%rax, 8(%r15)
	movq	_ELFCLASSNONE@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rcx
	cmpq	%rcx, %rax
	jne	LBB0_4
## %bb.3:
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	$-1, %edi
	callq	_elf_errmsg
	leaq	L_.str.1(%rip), %rsi
	movl	%r14d, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
	movq	(%rbx), %rcx
LBB0_4:
	movq	16(%r15), %rsi
	cmpq	%rcx, %rsi
	jne	LBB0_6
## %bb.5:
	movq	8(%r15), %rsi
	movq	%rsi, 16(%r15)
LBB0_6:
	movq	24(%r15), %rax
	movq	_ELFDATANONE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_8
## %bb.7:
	movq	-144(%rbp), %rax
	movq	_EI_DATA@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rax,%rcx,8), %rax
	movq	%rax, 24(%r15)
LBB0_8:
	movl	72(%r15), %edi
	callq	_gelf_newehdr
	testq	%rax, %rax
	jne	LBB0_10
## %bb.9:
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	$-1, %edi
	callq	_elf_errmsg
	leaq	L_.str.2(%rip), %rsi
	movl	%r14d, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_10:
	movl	72(%r15), %edi
	leaq	-88(%rbp), %rsi
	callq	_gelf_getehdr
	testq	%rax, %rax
	jne	LBB0_12
## %bb.11:
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	$-1, %edi
	callq	_elf_errmsg
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_12:
	movq	-88(%rbp), %rdi
	movq	-144(%rbp), %rsi
	movl	$8, %edx
	callq	_memcpy
	movq	16(%r15), %rcx
	movq	-88(%rbp), %rax
	movq	_EI_CLASS@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movq	%rcx, (%rax,%rdx,8)
	movq	24(%r15), %rcx
	movq	_EI_DATA@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movq	%rcx, (%rax,%rdx,8)
	movslq	32(%r15), %rcx
	cmpq	$-1, %rcx
	je	LBB0_14
## %bb.13:
	movq	_EI_OSABI@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movq	%rcx, (%rax,%rdx,8)
LBB0_14:
	movl	-104(%rbp), %eax
	movl	%eax, -48(%rbp)
	movq	-136(%rbp), %rcx
	movq	%rcx, -80(%rbp)
	movl	-120(%rbp), %eax
	movl	%eax, -64(%rbp)
	movq	_EXECUTABLE@GOTPCREL(%rip), %rdi
	movq	_DYNAMIC@GOTPCREL(%rip), %rsi
	movl	(%rsi), %eax
	orl	(%rdi), %eax
	movq	-112(%rbp), %rbx
	movq	_RELOCATABLE@GOTPCREL(%rip), %rdx
	orl	(%rdx), %eax
	movq	%rbx, -56(%rbp)
	notl	%eax
	andl	(%r15), %eax
	movl	%eax, (%r15)
	movq	_ET_EXEC@GOTPCREL(%rip), %rbx
	cmpq	(%rbx), %rcx
	jne	LBB0_16
## %bb.15:
	orl	(%rdi), %eax
	movl	%eax, (%r15)
	jmp	LBB0_21
LBB0_16:
	movq	_ET_DYN@GOTPCREL(%rip), %rdi
	cmpq	(%rdi), %rcx
	jne	LBB0_18
## %bb.17:
	orl	(%rsi), %eax
	movl	%eax, (%r15)
	jmp	LBB0_21
LBB0_18:
	movq	_ET_REL@GOTPCREL(%rip), %rsi
	cmpq	(%rsi), %rcx
	jne	LBB0_20
## %bb.19:
	orl	(%rdx), %eax
	movl	%eax, (%r15)
	jmp	LBB0_21
LBB0_20:
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.3(%rip), %rsi
	xorl	%eax, %eax
	callq	_errx
LBB0_21:
	movl	104(%r15), %edi
	leaq	-96(%rbp), %rsi
	callq	_elf_getshnum
	testl	%eax, %eax
	jne	LBB0_23
## %bb.22:
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	$-1, %edi
	callq	_elf_errmsg
	leaq	L_.str.4(%rip), %rsi
	movl	%r14d, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_23:
	movq	-96(%rbp), %rdi
	testq	%rdi, %rdi
	je	LBB0_26
## %bb.24:
	movl	$4, %esi
	callq	_calloc
	movq	%rax, 96(%r15)
	testq	%rax, %rax
	jne	LBB0_26
## %bb.25:
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.5(%rip), %rsi
	callq	_err
LBB0_26:
	movq	%r15, %rdi
	callq	_setup_phdr
	movq	%r15, %rdi
	callq	_create_scn
	movq	%r15, %rdi
	callq	_adjust_addr
	movq	40(%r15), %rax
	movq	_STRIP_DEBUG@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_35
## %bb.27:
	movq	_STRIP_UNNEEDED@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_35
## %bb.28:
	movl	(%r15), %eax
	movq	_WEAKEN_ALL@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_35
## %bb.29:
	movq	_LOCALIZE_HIDDEN@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_35
## %bb.30:
	movq	_DISCARD_LOCAL@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_35
## %bb.31:
	movq	_DISCARD_LLABEL@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	jne	LBB0_35
## %bb.32:
	cmpq	$0, 88(%r15)
	je	LBB0_33
LBB0_35:
	movl	(%r13), %eax
	notl	%eax
	andl	(%r15), %eax
	movl	%eax, (%r15)
	testl	%eax, (%r12)
	je	LBB0_38
LBB0_37:
	movq	%r15, %rdi
	callq	_create_symtab
LBB0_38:
	movl	72(%r15), %edi
	leaq	-88(%rbp), %rsi
	callq	_gelf_update_ehdr
	testq	%rax, %rax
	jne	LBB0_40
## %bb.39:
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	$-1, %edi
	callq	_elf_errmsg
	leaq	L_.str.6(%rip), %rsi
	movl	%r14d, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_40:
	movq	%r15, %rdi
	callq	_copy_content
	movq	%r15, %rdi
	movl	$1, %esi
	callq	_update_shdr
	movl	72(%r15), %edi
	leaq	-88(%rbp), %rsi
	callq	_gelf_getehdr
	testq	%rax, %rax
	jne	LBB0_42
## %bb.41:
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	$-1, %edi
	callq	_elf_errmsg
	leaq	L_.str(%rip), %rsi
	movl	%r14d, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_42:
	movq	-88(%rbp), %rax
	movq	_EI_OSABI@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	_ELFOSABI_FREEBSD@GOTPCREL(%rip), %rdx
	movslq	(%rdx), %rdx
	xorl	%esi, %esi
	cmpq	%rdx, (%rax,%rcx,8)
	sete	%sil
	movq	%r15, %rdi
	callq	_insert_shtab
	movq	%rax, %rbx
	movq	%r15, %rdi
	callq	_resync_sections
	movl	(%rbx), %eax
	movl	%eax, -60(%rbp)
	cmpq	$0, 48(%r15)
	jle	LBB0_45
## %bb.43:
	movl	72(%r15), %edi
	movq	_ELF_T_EHDR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_EV_CURRENT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	$1, %edx
	callq	_gelf_fsize
	movq	%rax, -72(%rbp)
	testq	%rax, %rax
	jne	LBB0_45
## %bb.44:
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	$-1, %edi
	callq	_elf_errmsg
	leaq	L_.str.7(%rip), %rsi
	movl	%ebx, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_45:
	movq	56(%r15), %rax
	testq	%rax, %rax
	je	LBB0_47
## %bb.46:
	addl	%eax, -64(%rbp)
LBB0_47:
	movq	_SET_START@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r15)
	je	LBB0_49
## %bb.48:
	movl	76(%r15), %eax
	movl	%eax, -64(%rbp)
LBB0_49:
	movq	64(%r15), %rax
	testq	%rax, %rax
	je	LBB0_51
## %bb.50:
	addl	%eax, -64(%rbp)
LBB0_51:
	movl	72(%r15), %edi
	leaq	-88(%rbp), %rsi
	callq	_gelf_update_ehdr
	testq	%rax, %rax
	jne	LBB0_53
## %bb.52:
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	$-1, %edi
	callq	_elf_errmsg
	leaq	L_.str.6(%rip), %rsi
	movl	%ebx, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_53:
	cmpq	$0, 48(%r15)
	jle	LBB0_55
## %bb.54:
	movq	%r15, %rdi
	callq	_copy_phdr
LBB0_55:
	movl	72(%r15), %edi
	movq	_ELF_C_WRITE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_elf_update
	testq	%rax, %rax
	jns	LBB0_57
## %bb.56:
	movq	_EXIT_FAILURE@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	$-1, %edi
	callq	_elf_errmsg
	leaq	L_.str.8(%rip), %rsi
	movl	%ebx, %edi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_errx
LBB0_57:
	movq	%r15, %rdi
	callq	_free_elf
	addq	$104, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_33:
	leaq	80(%r15), %rdi
	callq	_STAILQ_EMPTY
	testl	%eax, %eax
	je	LBB0_35
## %bb.34:
	movl	(%r15), %eax
	testl	%eax, (%r12)
	jne	LBB0_37
	jmp	LBB0_38
	.cfi_endproc
                                        ## -- End function
	.comm	_SYMTAB_INTACT,4,2              ## @SYMTAB_INTACT
	.comm	_SYMTAB_EXIST,4,2               ## @SYMTAB_EXIST
	.comm	_EXIT_FAILURE,4,2               ## @EXIT_FAILURE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"gelf_getehdr() failed: %s"

	.comm	_ELFCLASSNONE,8,3               ## @ELFCLASSNONE
L_.str.1:                               ## @.str.1
	.asciz	"getclass() failed: %s"

	.comm	_ELFDATANONE,8,3                ## @ELFDATANONE
	.comm	_EI_DATA,8,3                    ## @EI_DATA
L_.str.2:                               ## @.str.2
	.asciz	"gelf_newehdr failed: %s"

	.comm	_EI_CLASS,8,3                   ## @EI_CLASS
	.comm	_EI_OSABI,8,3                   ## @EI_OSABI
	.comm	_EXECUTABLE,4,2                 ## @EXECUTABLE
	.comm	_DYNAMIC,4,2                    ## @DYNAMIC
	.comm	_RELOCATABLE,4,2                ## @RELOCATABLE
	.comm	_ET_EXEC,8,3                    ## @ET_EXEC
	.comm	_ET_DYN,8,3                     ## @ET_DYN
	.comm	_ET_REL,8,3                     ## @ET_REL
L_.str.3:                               ## @.str.3
	.asciz	"unsupported e_type"

L_.str.4:                               ## @.str.4
	.asciz	"elf_getshnum failed: %s"

L_.str.5:                               ## @.str.5
	.asciz	"calloc failed"

	.comm	_STRIP_DEBUG,8,3                ## @STRIP_DEBUG
	.comm	_STRIP_UNNEEDED,8,3             ## @STRIP_UNNEEDED
	.comm	_WEAKEN_ALL,4,2                 ## @WEAKEN_ALL
	.comm	_LOCALIZE_HIDDEN,4,2            ## @LOCALIZE_HIDDEN
	.comm	_DISCARD_LOCAL,4,2              ## @DISCARD_LOCAL
	.comm	_DISCARD_LLABEL,4,2             ## @DISCARD_LLABEL
L_.str.6:                               ## @.str.6
	.asciz	"gelf_update_ehdr() failed: %s"

	.comm	_ELFOSABI_FREEBSD,4,2           ## @ELFOSABI_FREEBSD
	.comm	_ELF_T_EHDR,4,2                 ## @ELF_T_EHDR
	.comm	_EV_CURRENT,4,2                 ## @EV_CURRENT
L_.str.7:                               ## @.str.7
	.asciz	"gelf_fsize() failed: %s"

	.comm	_SET_START,4,2                  ## @SET_START
	.comm	_ELF_C_WRITE,4,2                ## @ELF_C_WRITE
L_.str.8:                               ## @.str.8
	.asciz	"elf_update() failed: %s"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_create_elf                     ; -- Begin function create_elf
	.p2align	2
_create_elf:                            ; @create_elf
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #176
	.cfi_def_cfa_offset 176
	stp	x24, x23, [sp, #112]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #128]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #144]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #160]            ; 16-byte Folded Spill
	add	x29, sp, #160
	.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, x0
Lloh0:
	adrp	x22, _SYMTAB_INTACT@GOTPAGE
Lloh1:
	ldr	x22, [x22, _SYMTAB_INTACT@GOTPAGEOFF]
	ldr	w8, [x22]
	ldr	w9, [x0]
	orr	w8, w9, w8
	str	w8, [x0]
Lloh2:
	adrp	x21, _SYMTAB_EXIST@GOTPAGE
Lloh3:
	ldr	x21, [x21, _SYMTAB_EXIST@GOTPAGEOFF]
	ldr	w9, [x21]
	bic	w8, w8, w9
	str	w8, [x0]
	ldr	w0, [x0, #104]
	add	x1, sp, #64
	bl	_gelf_getehdr
	cbnz	x0, LBB0_2
; %bb.1:
Lloh4:
	adrp	x8, _EXIT_FAILURE@GOTPAGE
Lloh5:
	ldr	x8, [x8, _EXIT_FAILURE@GOTPAGEOFF]
Lloh6:
	ldr	w20, [x8]
	mov	w0, #-1
	bl	_elf_errmsg
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh7:
	adrp	x1, l_.str@PAGE
Lloh8:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_errx
LBB0_2:
	ldr	w0, [x19, #104]
	bl	_gelf_getclass
	str	x0, [x19, #8]
Lloh9:
	adrp	x23, _ELFCLASSNONE@GOTPAGE
Lloh10:
	ldr	x23, [x23, _ELFCLASSNONE@GOTPAGEOFF]
	ldr	x8, [x23]
	cmp	x0, x8
	b.ne	LBB0_4
; %bb.3:
Lloh11:
	adrp	x8, _EXIT_FAILURE@GOTPAGE
Lloh12:
	ldr	x8, [x8, _EXIT_FAILURE@GOTPAGEOFF]
Lloh13:
	ldr	w20, [x8]
	mov	w0, #-1
	bl	_elf_errmsg
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh14:
	adrp	x1, l_.str.1@PAGE
Lloh15:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x20
	bl	_errx
	ldr	x8, [x23]
LBB0_4:
	ldr	x1, [x19, #16]
	cmp	x1, x8
	b.ne	LBB0_6
; %bb.5:
	ldr	x1, [x19, #8]
	str	x1, [x19, #16]
LBB0_6:
	ldr	x8, [x19, #24]
Lloh16:
	adrp	x9, _ELFDATANONE@GOTPAGE
Lloh17:
	ldr	x9, [x9, _ELFDATANONE@GOTPAGEOFF]
Lloh18:
	ldr	x9, [x9]
Lloh19:
	adrp	x23, _EI_DATA@GOTPAGE
Lloh20:
	ldr	x23, [x23, _EI_DATA@GOTPAGEOFF]
	cmp	x8, x9
	b.ne	LBB0_8
; %bb.7:
	ldr	x8, [sp, #64]
	ldr	x9, [x23]
	ldr	x8, [x8, x9, lsl #3]
	str	x8, [x19, #24]
LBB0_8:
	ldr	w0, [x19, #72]
	bl	_gelf_newehdr
	cbnz	x0, LBB0_10
; %bb.9:
Lloh21:
	adrp	x8, _EXIT_FAILURE@GOTPAGE
Lloh22:
	ldr	x8, [x8, _EXIT_FAILURE@GOTPAGEOFF]
Lloh23:
	ldr	w20, [x8]
	mov	w0, #-1
	bl	_elf_errmsg
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh24:
	adrp	x1, l_.str.2@PAGE
Lloh25:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x20
	bl	_errx
LBB0_10:
	ldr	w0, [x19, #72]
	add	x1, sp, #16
	bl	_gelf_getehdr
	cbnz	x0, LBB0_12
; %bb.11:
Lloh26:
	adrp	x8, _EXIT_FAILURE@GOTPAGE
Lloh27:
	ldr	x8, [x8, _EXIT_FAILURE@GOTPAGEOFF]
Lloh28:
	ldr	w20, [x8]
	mov	w0, #-1
	bl	_elf_errmsg
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh29:
	adrp	x1, l_.str@PAGE
Lloh30:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_errx
LBB0_12:
	ldr	x0, [sp, #16]
	ldr	x1, [sp, #64]
	mov	w2, #8
	bl	_memcpy
	ldr	x9, [x19, #16]
Lloh31:
	adrp	x10, _EI_CLASS@GOTPAGE
Lloh32:
	ldr	x10, [x10, _EI_CLASS@GOTPAGEOFF]
	ldr	x8, [sp, #16]
Lloh33:
	ldr	x10, [x10]
	str	x9, [x8, x10, lsl #3]
	ldr	x9, [x19, #24]
	ldr	x10, [x23]
	str	x9, [x8, x10, lsl #3]
	ldrsw	x9, [x19, #32]
Lloh34:
	adrp	x23, _EI_OSABI@GOTPAGE
Lloh35:
	ldr	x23, [x23, _EI_OSABI@GOTPAGEOFF]
	cmn	w9, #1
	b.eq	LBB0_14
; %bb.13:
	ldr	x10, [x23]
	str	x9, [x8, x10, lsl #3]
LBB0_14:
	ldur	d0, [sp, #100]
	stur	d0, [sp, #52]
	ldr	x8, [sp, #72]
	str	x8, [sp, #24]
	ldr	w9, [sp, #88]
	ldr	w10, [sp, #96]
	str	w9, [sp, #40]
	str	w10, [sp, #48]
Lloh36:
	adrp	x12, _EXECUTABLE@GOTPAGE
Lloh37:
	ldr	x12, [x12, _EXECUTABLE@GOTPAGEOFF]
	ldr	w9, [x12]
Lloh38:
	adrp	x11, _DYNAMIC@GOTPAGE
Lloh39:
	ldr	x11, [x11, _DYNAMIC@GOTPAGEOFF]
	ldr	w10, [x11]
	orr	w9, w10, w9
Lloh40:
	adrp	x10, _RELOCATABLE@GOTPAGE
Lloh41:
	ldr	x10, [x10, _RELOCATABLE@GOTPAGEOFF]
	ldr	w13, [x10]
	orr	w9, w9, w13
	ldr	w13, [x19]
	bic	w9, w13, w9
	str	w9, [x19]
Lloh42:
	adrp	x13, _ET_EXEC@GOTPAGE
Lloh43:
	ldr	x13, [x13, _ET_EXEC@GOTPAGEOFF]
Lloh44:
	ldr	x13, [x13]
	cmp	x8, x13
	b.ne	LBB0_16
; %bb.15:
	ldr	w8, [x12]
	b	LBB0_20
LBB0_16:
Lloh45:
	adrp	x12, _ET_DYN@GOTPAGE
Lloh46:
	ldr	x12, [x12, _ET_DYN@GOTPAGEOFF]
Lloh47:
	ldr	x12, [x12]
	cmp	x8, x12
	b.ne	LBB0_18
; %bb.17:
	ldr	w8, [x11]
	b	LBB0_20
LBB0_18:
Lloh48:
	adrp	x11, _ET_REL@GOTPAGE
Lloh49:
	ldr	x11, [x11, _ET_REL@GOTPAGEOFF]
Lloh50:
	ldr	x11, [x11]
	cmp	x8, x11
	b.ne	LBB0_56
; %bb.19:
	ldr	w8, [x10]
LBB0_20:
	orr	w8, w8, w9
	str	w8, [x19]
LBB0_21:
	ldr	w0, [x19, #104]
	add	x1, sp, #8
	bl	_elf_getshnum
	cbnz	w0, LBB0_23
; %bb.22:
Lloh51:
	adrp	x8, _EXIT_FAILURE@GOTPAGE
Lloh52:
	ldr	x8, [x8, _EXIT_FAILURE@GOTPAGEOFF]
Lloh53:
	ldr	w20, [x8]
	mov	w0, #-1
	bl	_elf_errmsg
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh54:
	adrp	x1, l_.str.4@PAGE
Lloh55:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x20
	bl	_errx
LBB0_23:
	ldr	x0, [sp, #8]
	cbz	x0, LBB0_26
; %bb.24:
	mov	w1, #4
	bl	_calloc
	str	x0, [x19, #96]
	cbnz	x0, LBB0_26
; %bb.25:
Lloh56:
	adrp	x8, _EXIT_FAILURE@GOTPAGE
Lloh57:
	ldr	x8, [x8, _EXIT_FAILURE@GOTPAGEOFF]
Lloh58:
	ldr	w0, [x8]
Lloh59:
	adrp	x1, l_.str.5@PAGE
Lloh60:
	add	x1, x1, l_.str.5@PAGEOFF
	bl	_err
LBB0_26:
	mov	x0, x19
	bl	_setup_phdr
	mov	x0, x19
	bl	_create_scn
	mov	x0, x19
	bl	_adjust_addr
	ldr	x8, [x19, #40]
Lloh61:
	adrp	x9, _STRIP_DEBUG@GOTPAGE
Lloh62:
	ldr	x9, [x9, _STRIP_DEBUG@GOTPAGEOFF]
Lloh63:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_33
; %bb.27:
Lloh64:
	adrp	x9, _STRIP_UNNEEDED@GOTPAGE
Lloh65:
	ldr	x9, [x9, _STRIP_UNNEEDED@GOTPAGEOFF]
Lloh66:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_33
; %bb.28:
	ldr	w8, [x19]
Lloh67:
	adrp	x9, _WEAKEN_ALL@GOTPAGE
Lloh68:
	ldr	x9, [x9, _WEAKEN_ALL@GOTPAGEOFF]
Lloh69:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_33
; %bb.29:
Lloh70:
	adrp	x9, _LOCALIZE_HIDDEN@GOTPAGE
Lloh71:
	ldr	x9, [x9, _LOCALIZE_HIDDEN@GOTPAGEOFF]
Lloh72:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_33
; %bb.30:
Lloh73:
	adrp	x9, _DISCARD_LOCAL@GOTPAGE
Lloh74:
	ldr	x9, [x9, _DISCARD_LOCAL@GOTPAGEOFF]
Lloh75:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_33
; %bb.31:
Lloh76:
	adrp	x9, _DISCARD_LLABEL@GOTPAGE
Lloh77:
	ldr	x9, [x9, _DISCARD_LLABEL@GOTPAGEOFF]
Lloh78:
	ldr	w9, [x9]
	tst	w9, w8
	b.ne	LBB0_33
; %bb.32:
	ldr	x8, [x19, #88]
	cbz	x8, LBB0_57
LBB0_33:
	ldr	w8, [x22]
	ldr	w9, [x19]
	bic	w8, w9, w8
	str	w8, [x19]
LBB0_34:
	ldr	w9, [x21]
	tst	w9, w8
	b.eq	LBB0_36
; %bb.35:
	mov	x0, x19
	bl	_create_symtab
LBB0_36:
	ldr	w0, [x19, #72]
	add	x1, sp, #16
	bl	_gelf_update_ehdr
	cbnz	x0, LBB0_38
; %bb.37:
Lloh79:
	adrp	x8, _EXIT_FAILURE@GOTPAGE
Lloh80:
	ldr	x8, [x8, _EXIT_FAILURE@GOTPAGEOFF]
Lloh81:
	ldr	w20, [x8]
	mov	w0, #-1
	bl	_elf_errmsg
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh82:
	adrp	x1, l_.str.6@PAGE
Lloh83:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x0, x20
	bl	_errx
LBB0_38:
	mov	x0, x19
	bl	_copy_content
	mov	x0, x19
	mov	w1, #1
	bl	_update_shdr
	ldr	w0, [x19, #72]
	add	x1, sp, #16
	bl	_gelf_getehdr
	cbnz	x0, LBB0_40
; %bb.39:
Lloh84:
	adrp	x8, _EXIT_FAILURE@GOTPAGE
Lloh85:
	ldr	x8, [x8, _EXIT_FAILURE@GOTPAGEOFF]
Lloh86:
	ldr	w20, [x8]
	mov	w0, #-1
	bl	_elf_errmsg
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh87:
	adrp	x1, l_.str@PAGE
Lloh88:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_errx
LBB0_40:
	ldr	x8, [sp, #16]
	ldr	x9, [x23]
	ldr	x8, [x8, x9, lsl #3]
Lloh89:
	adrp	x9, _ELFOSABI_FREEBSD@GOTPAGE
Lloh90:
	ldr	x9, [x9, _ELFOSABI_FREEBSD@GOTPAGEOFF]
Lloh91:
	ldrsw	x9, [x9]
	cmp	x8, x9
	cset	w1, eq
	mov	x0, x19
	bl	_insert_shtab
	mov	x20, x0
	mov	x0, x19
	bl	_resync_sections
	ldr	w8, [x20]
	str	w8, [sp, #44]
	ldr	x8, [x19, #48]
	cmp	x8, #1
	b.lt	LBB0_43
; %bb.41:
	ldr	w0, [x19, #72]
Lloh92:
	adrp	x8, _ELF_T_EHDR@GOTPAGE
Lloh93:
	ldr	x8, [x8, _ELF_T_EHDR@GOTPAGEOFF]
Lloh94:
	ldr	w1, [x8]
Lloh95:
	adrp	x8, _EV_CURRENT@GOTPAGE
Lloh96:
	ldr	x8, [x8, _EV_CURRENT@GOTPAGEOFF]
Lloh97:
	ldr	w3, [x8]
	mov	w2, #1
	bl	_gelf_fsize
	str	x0, [sp, #32]
	cbnz	x0, LBB0_43
; %bb.42:
Lloh98:
	adrp	x8, _EXIT_FAILURE@GOTPAGE
Lloh99:
	ldr	x8, [x8, _EXIT_FAILURE@GOTPAGEOFF]
Lloh100:
	ldr	w20, [x8]
	mov	w0, #-1
	bl	_elf_errmsg
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh101:
	adrp	x1, l_.str.7@PAGE
Lloh102:
	add	x1, x1, l_.str.7@PAGEOFF
	mov	x0, x20
	bl	_errx
LBB0_43:
	ldr	x8, [x19, #56]
	cbz	x8, LBB0_45
; %bb.44:
	ldr	w9, [sp, #40]
	add	w8, w9, w8
	str	w8, [sp, #40]
LBB0_45:
	ldr	w8, [x19]
Lloh103:
	adrp	x9, _SET_START@GOTPAGE
Lloh104:
	ldr	x9, [x9, _SET_START@GOTPAGEOFF]
Lloh105:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_47
; %bb.46:
	ldr	w8, [x19, #76]
	str	w8, [sp, #40]
LBB0_47:
	ldr	x8, [x19, #64]
	cbz	x8, LBB0_49
; %bb.48:
	ldr	w9, [sp, #40]
	add	w8, w9, w8
	str	w8, [sp, #40]
LBB0_49:
	ldr	w0, [x19, #72]
	add	x1, sp, #16
	bl	_gelf_update_ehdr
	cbnz	x0, LBB0_51
; %bb.50:
Lloh106:
	adrp	x8, _EXIT_FAILURE@GOTPAGE
Lloh107:
	ldr	x8, [x8, _EXIT_FAILURE@GOTPAGEOFF]
Lloh108:
	ldr	w20, [x8]
	mov	w0, #-1
	bl	_elf_errmsg
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh109:
	adrp	x1, l_.str.6@PAGE
Lloh110:
	add	x1, x1, l_.str.6@PAGEOFF
	mov	x0, x20
	bl	_errx
LBB0_51:
	ldr	x8, [x19, #48]
	cmp	x8, #1
	b.lt	LBB0_53
; %bb.52:
	mov	x0, x19
	bl	_copy_phdr
LBB0_53:
	ldr	w0, [x19, #72]
Lloh111:
	adrp	x8, _ELF_C_WRITE@GOTPAGE
Lloh112:
	ldr	x8, [x8, _ELF_C_WRITE@GOTPAGEOFF]
Lloh113:
	ldr	w1, [x8]
	bl	_elf_update
	tbz	x0, #63, LBB0_55
; %bb.54:
Lloh114:
	adrp	x8, _EXIT_FAILURE@GOTPAGE
Lloh115:
	ldr	x8, [x8, _EXIT_FAILURE@GOTPAGEOFF]
Lloh116:
	ldr	w20, [x8]
	mov	w0, #-1
	bl	_elf_errmsg
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh117:
	adrp	x1, l_.str.8@PAGE
Lloh118:
	add	x1, x1, l_.str.8@PAGEOFF
	mov	x0, x20
	bl	_errx
LBB0_55:
	mov	x0, x19
	bl	_free_elf
	ldp	x29, x30, [sp, #160]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #144]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #128]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #112]            ; 16-byte Folded Reload
	add	sp, sp, #176
	ret
LBB0_56:
Lloh119:
	adrp	x8, _EXIT_FAILURE@GOTPAGE
Lloh120:
	ldr	x8, [x8, _EXIT_FAILURE@GOTPAGEOFF]
Lloh121:
	ldr	w0, [x8]
Lloh122:
	adrp	x1, l_.str.3@PAGE
Lloh123:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_errx
	b	LBB0_21
LBB0_57:
	add	x0, x19, #80
	bl	_STAILQ_EMPTY
	cbz	w0, LBB0_33
; %bb.58:
	ldr	w8, [x19]
	b	LBB0_34
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGot	Lloh40, Lloh41
	.loh AdrpLdrGot	Lloh38, Lloh39
	.loh AdrpLdrGot	Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpAdd	Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh51, Lloh52, Lloh53
	.loh AdrpAdd	Lloh59, Lloh60
	.loh AdrpLdrGotLdr	Lloh56, Lloh57, Lloh58
	.loh AdrpLdrGotLdr	Lloh61, Lloh62, Lloh63
	.loh AdrpLdrGotLdr	Lloh64, Lloh65, Lloh66
	.loh AdrpLdrGotLdr	Lloh67, Lloh68, Lloh69
	.loh AdrpLdrGotLdr	Lloh70, Lloh71, Lloh72
	.loh AdrpLdrGotLdr	Lloh73, Lloh74, Lloh75
	.loh AdrpLdrGotLdr	Lloh76, Lloh77, Lloh78
	.loh AdrpAdd	Lloh82, Lloh83
	.loh AdrpLdrGotLdr	Lloh79, Lloh80, Lloh81
	.loh AdrpAdd	Lloh87, Lloh88
	.loh AdrpLdrGotLdr	Lloh84, Lloh85, Lloh86
	.loh AdrpLdrGotLdr	Lloh89, Lloh90, Lloh91
	.loh AdrpLdrGotLdr	Lloh95, Lloh96, Lloh97
	.loh AdrpLdrGotLdr	Lloh92, Lloh93, Lloh94
	.loh AdrpAdd	Lloh101, Lloh102
	.loh AdrpLdrGotLdr	Lloh98, Lloh99, Lloh100
	.loh AdrpLdrGotLdr	Lloh103, Lloh104, Lloh105
	.loh AdrpAdd	Lloh109, Lloh110
	.loh AdrpLdrGotLdr	Lloh106, Lloh107, Lloh108
	.loh AdrpLdrGotLdr	Lloh111, Lloh112, Lloh113
	.loh AdrpAdd	Lloh117, Lloh118
	.loh AdrpLdrGotLdr	Lloh114, Lloh115, Lloh116
	.loh AdrpAdd	Lloh122, Lloh123
	.loh AdrpLdrGotLdr	Lloh119, Lloh120, Lloh121
	.cfi_endproc
                                        ; -- End function
	.comm	_SYMTAB_INTACT,4,2              ; @SYMTAB_INTACT
	.comm	_SYMTAB_EXIST,4,2               ; @SYMTAB_EXIST
	.comm	_EXIT_FAILURE,4,2               ; @EXIT_FAILURE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"gelf_getehdr() failed: %s"

	.comm	_ELFCLASSNONE,8,3               ; @ELFCLASSNONE
l_.str.1:                               ; @.str.1
	.asciz	"getclass() failed: %s"

	.comm	_ELFDATANONE,8,3                ; @ELFDATANONE
	.comm	_EI_DATA,8,3                    ; @EI_DATA
l_.str.2:                               ; @.str.2
	.asciz	"gelf_newehdr failed: %s"

	.comm	_EI_CLASS,8,3                   ; @EI_CLASS
	.comm	_EI_OSABI,8,3                   ; @EI_OSABI
	.comm	_EXECUTABLE,4,2                 ; @EXECUTABLE
	.comm	_DYNAMIC,4,2                    ; @DYNAMIC
	.comm	_RELOCATABLE,4,2                ; @RELOCATABLE
	.comm	_ET_EXEC,8,3                    ; @ET_EXEC
	.comm	_ET_DYN,8,3                     ; @ET_DYN
	.comm	_ET_REL,8,3                     ; @ET_REL
l_.str.3:                               ; @.str.3
	.asciz	"unsupported e_type"

l_.str.4:                               ; @.str.4
	.asciz	"elf_getshnum failed: %s"

l_.str.5:                               ; @.str.5
	.asciz	"calloc failed"

	.comm	_STRIP_DEBUG,8,3                ; @STRIP_DEBUG
	.comm	_STRIP_UNNEEDED,8,3             ; @STRIP_UNNEEDED
	.comm	_WEAKEN_ALL,4,2                 ; @WEAKEN_ALL
	.comm	_LOCALIZE_HIDDEN,4,2            ; @LOCALIZE_HIDDEN
	.comm	_DISCARD_LOCAL,4,2              ; @DISCARD_LOCAL
	.comm	_DISCARD_LLABEL,4,2             ; @DISCARD_LLABEL
l_.str.6:                               ; @.str.6
	.asciz	"gelf_update_ehdr() failed: %s"

	.comm	_ELFOSABI_FREEBSD,4,2           ; @ELFOSABI_FREEBSD
	.comm	_ELF_T_EHDR,4,2                 ; @ELF_T_EHDR
	.comm	_EV_CURRENT,4,2                 ; @EV_CURRENT
l_.str.7:                               ; @.str.7
	.asciz	"gelf_fsize() failed: %s"

	.comm	_SET_START,4,2                  ; @SET_START
	.comm	_ELF_C_WRITE,4,2                ; @ELF_C_WRITE
l_.str.8:                               ; @.str.8
	.asciz	"elf_update() failed: %s"

.subsections_via_symbols
