	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function addarg
_addarg:                                ## @addarg
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	_nargs@GOTPCREL(%rip), %r14
	movl	(%r14), %edx
	incl	%edx
	movq	_cargs@GOTPCREL(%rip), %rcx
	movl	(%rcx), %eax
	cmpl	%eax, %edx
	jl	LBB0_3
## %bb.1:
	leal	16(%rax), %edx
	movl	%edx, (%rcx)
	movq	_args@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	leal	128(,%rax,8), %esi
	callq	_realloc
	movq	%rax, (%r15)
	testq	%rax, %rax
	jne	LBB0_3
## %bb.2:
	leaq	L_.str(%rip), %rsi
	movl	$1, %edi
	callq	_err
LBB0_3:
	movq	%rbx, %rdi
	callq	_strdup
	movq	_args@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rdx
	movslq	(%r14), %rsi
	leal	1(%rsi), %ecx
	movl	%ecx, (%r14)
	movq	%rax, (%rdx,%rsi,8)
	testq	%rax, %rax
	jne	LBB0_5
## %bb.4:
	leaq	L_.str.1(%rip), %rsi
	movl	$1, %edi
	callq	_err
	movl	(%r14), %ecx
LBB0_5:
	movq	(%rbx), %rax
	movslq	%ecx, %rcx
	movq	$0, (%rax,%rcx,8)
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_nargs,4,2                      ## @nargs
	.comm	_cargs,4,2                      ## @cargs
	.comm	_args,8,3                       ## @args
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"malloc"

L_.str.1:                               ## @.str.1
	.asciz	"strdup"

	.no_dead_strip	_addarg
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function addarg
_addarg:                                ; @addarg
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x0
Lloh0:
	adrp	x20, _nargs@GOTPAGE
Lloh1:
	ldr	x20, [x20, _nargs@GOTPAGEOFF]
	ldr	w8, [x20]
	add	w10, w8, #1
Lloh2:
	adrp	x8, _cargs@GOTPAGE
Lloh3:
	ldr	x8, [x8, _cargs@GOTPAGEOFF]
	ldr	w9, [x8]
Lloh4:
	adrp	x21, _args@GOTPAGE
Lloh5:
	ldr	x21, [x21, _args@GOTPAGEOFF]
	cmp	w10, w9
	b.lt	LBB0_3
; %bb.1:
	add	w9, w9, #16
	str	w9, [x8]
	ldr	x0, [x21]
	lsl	w1, w9, #3
	bl	_realloc
	str	x0, [x21]
	cbnz	x0, LBB0_3
; %bb.2:
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #1
	bl	_err
LBB0_3:
	mov	x0, x19
	bl	_strdup
	ldr	x9, [x21]
	ldrsw	x10, [x20]
	add	w8, w10, #1
	str	w8, [x20]
	str	x0, [x9, x10, lsl #3]
	cbnz	x0, LBB0_5
; %bb.4:
Lloh8:
	adrp	x1, l_.str.1@PAGE
Lloh9:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	w0, #1
	bl	_err
	ldr	w8, [x20]
LBB0_5:
	ldr	x9, [x21]
	str	xzr, [x9, w8, sxtw #3]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_nargs,4,2                      ; @nargs
	.comm	_cargs,4,2                      ; @cargs
	.comm	_args,8,3                       ; @args
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"malloc"

l_.str.1:                               ; @.str.1
	.asciz	"strdup"

	.no_dead_strip	_addarg
.subsections_via_symbols
