	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pack_sg_list
_pack_sg_list:                          ## @pack_sg_list
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r12d
	testl	%r8d, %r8d
	je	LBB0_4
## %bb.1:
	movl	%r8d, %r15d
	movq	%rcx, %r13
	movl	%esi, -44(%rbp)                 ## 4-byte Spill
	movslq	%esi, %r12
	movslq	%edx, %rcx
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	leaq	(%rdi,%r12,4), %rbx
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r13, %rdi
	callq	_rest_of_page
	movl	%eax, %r14d
	cmpl	%r15d, %eax
	cmovgel	%r15d, %r14d
	leaq	1(%r12), %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	movq	%r13, %rsi
	movl	%r14d, %edx
	callq	_sg_set_buf
	movslq	%r14d, %r14
	addq	%r14, %r13
	xorl	%edi, %edi
	cmpq	-56(%rbp), %r12                 ## 8-byte Folded Reload
	setge	%dil
	callq	_BUG_ON
	movq	-64(%rbp), %r12                 ## 8-byte Reload
	addq	$4, %rbx
	subl	%r14d, %r15d
	jne	LBB0_2
## %bb.3:
	movl	-44(%rbp), %esi                 ## 4-byte Reload
LBB0_4:
	subl	%esi, %r12d
	movl	%r12d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_pack_sg_list
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pack_sg_list
_pack_sg_list:                          ; @pack_sg_list
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
                                        ; kill: def $w2 killed $w2 def $x2
	mov	x19, x1
	mov	x26, x1
	cbz	w4, LBB0_3
; %bb.1:
	mov	x20, x4
	mov	x21, x3
	sxtw	x25, w19
	sxtw	x24, w2
	add	x22, x0, w19, sxtw #2
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x21
	bl	_rest_of_page
	cmp	w0, w20
	csel	w23, w0, w20, lt
	add	x26, x25, #1
	mov	x0, x22
	mov	x1, x21
	mov	x2, x23
	bl	_sg_set_buf
	sub	w20, w20, w23
	add	x21, x21, w23, sxtw
	cmp	x25, x24
	cset	w0, ge
	bl	_BUG_ON
	add	x22, x22, #4
	mov	x25, x26
	cbnz	w20, LBB0_2
LBB0_3:
	sub	w0, w26, w19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_pack_sg_list
.subsections_via_symbols
