	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_stack_restore                  ## -- Begin function stack_restore
	.p2align	4, 0x90
_stack_restore:                         ## @stack_restore
	.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	%rdi, %rbx
	leaq	24(%rdi), %r14
	movq	(%rdi), %rsi
	jmp	LBB0_1
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_1 Depth=1
	movq	%rbx, %rdi
	callq	_stack_pop
	movl	%eax, %edi
	callq	_jv_free
	movq	(%rbx), %rsi
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	callq	_stack_pop_will_free
	testq	%rax, %rax
	jne	LBB0_8
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	8(%rbx), %rsi
	movq	%r14, %rdi
	callq	_stack_pop_will_free
	testq	%rax, %rax
	jne	LBB0_3
## %bb.4:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	16(%rbx), %rsi
	movq	%r14, %rdi
	callq	_stack_pop_will_free
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_1 Depth=1
	movq	%rbx, %rdi
	callq	_frame_pop
	movq	(%rbx), %rsi
	jmp	LBB0_1
LBB0_6:                                 ##   in Loop: Header=BB0_1 Depth=1
	xorl	%edi, %edi
	callq	_assert
	movq	(%rbx), %rsi
	jmp	LBB0_1
LBB0_8:
	movq	(%rbx), %rsi
	testq	%rsi, %rsi
	je	LBB0_9
## %bb.10:
	movq	%r14, %rdi
	callq	_stack_block
	movq	%rax, %r12
	movq	32(%rax), %r15
	movups	(%rax), %xmm0
	movups	%xmm0, 8(%rbx)
	movl	16(%rax), %r13d
	movl	36(%rbx), %edi
	callq	_jv_get_kind
	movq	_JV_KIND_ARRAY@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_12
## %bb.11:
	movl	%r13d, %edi
	notl	%edi
	shrl	$31, %edi
	callq	_assert
	movl	36(%rbx), %edi
	xorl	%esi, %esi
	movl	%r13d, %edx
	callq	_jv_array_slice
	movl	%eax, 36(%rbx)
	jmp	LBB0_13
LBB0_9:
	xorl	%r15d, %r15d
	jmp	LBB0_14
LBB0_12:
	movl	$0, 16(%r12)
LBB0_13:
	movl	32(%rbx), %edi
	callq	_jv_free
	movl	24(%r12), %eax
	movl	%eax, 32(%rbx)
	movl	20(%r12), %eax
	movl	%eax, 28(%rbx)
	movq	(%rbx), %rsi
	movq	%r14, %rdi
	movl	$40, %edx
	callq	_stack_pop_block
	movq	%rax, (%rbx)
LBB0_14:
	movq	%r15, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_JV_KIND_ARRAY,8,3              ## @JV_KIND_ARRAY
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_stack_restore                  ; -- Begin function stack_restore
	.p2align	2
_stack_restore:                         ; @stack_restore
	.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, x0
	mov	x20, x0
	ldr	x1, [x20], #24
	b	LBB0_2
LBB0_1:                                 ;   in Loop: Header=BB0_2 Depth=1
	mov	x0, x19
	bl	_stack_pop
	bl	_jv_free
	ldr	x1, [x19]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	bl	_stack_pop_will_free
	cbnz	x0, LBB0_7
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x1, [x19, #8]
	mov	x0, x20
	bl	_stack_pop_will_free
	cbnz	x0, LBB0_1
; %bb.4:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	x1, [x19, #16]
	mov	x0, x20
	bl	_stack_pop_will_free
	cbz	x0, LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	x0, x19
	bl	_frame_pop
	ldr	x1, [x19]
	b	LBB0_2
LBB0_6:                                 ;   in Loop: Header=BB0_2 Depth=1
	bl	_assert
	ldr	x1, [x19]
	b	LBB0_2
LBB0_7:
	ldr	x1, [x19]
	cbz	x1, LBB0_10
; %bb.8:
	mov	x0, x20
	bl	_stack_block
	mov	x22, x0
	ldr	x21, [x0, #32]
	ldr	q0, [x0]
	stur	q0, [x19, #8]
	ldr	w23, [x0, #16]
	ldr	w0, [x19, #36]
	bl	_jv_get_kind
Lloh0:
	adrp	x8, _JV_KIND_ARRAY@GOTPAGE
Lloh1:
	ldr	x8, [x8, _JV_KIND_ARRAY@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_11
; %bb.9:
	mvn	w8, w23
	lsr	w0, w8, #31
	bl	_assert
	ldr	w0, [x19, #36]
	mov	w1, #0
	mov	x2, x23
	bl	_jv_array_slice
	str	w0, [x19, #36]
	b	LBB0_12
LBB0_10:
	mov	x21, #0
	b	LBB0_13
LBB0_11:
	str	wzr, [x22, #16]
LBB0_12:
	ldr	w0, [x19, #32]
	bl	_jv_free
	ldur	d0, [x22, #20]
	stur	d0, [x19, #28]
	ldr	x1, [x19]
	mov	x0, x20
	mov	w2, #40
	bl	_stack_pop_block
	str	x0, [x19]
LBB0_13:
	mov	x0, x21
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_JV_KIND_ARRAY,8,3              ; @JV_KIND_ARRAY
.subsections_via_symbols
