	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function unrotate_iov
_unrotate_iov:                          ## @unrotate_iov
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rsi, -64(%rbp)                 ## 8-byte Spill
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movl	%ecx, %eax
	movl	%ecx, -48(%rbp)                 ## 4-byte Spill
	testl	%ecx, %ecx
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	jle	LBB0_22
## %bb.1:
	leaq	(,%rax,8), %rax
	leaq	(%rax,%rax,2), %r12
	xorl	%ebx, %ebx
	movq	_GSS_IOV_BUFFER_TYPE_DATA@GOTPCREL(%rip), %r15
	xorl	%r13d, %r13d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	addq	(%r14,%rbx), %r13
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	addq	$24, %rbx
	cmpq	%rbx, %r12
	je	LBB0_7
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	16(%r14,%rbx), %edi
	callq	_GSS_IOV_BUFFER_TYPE
	cmpq	(%r15), %rax
	je	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	16(%r14,%rbx), %edi
	callq	_GSS_IOV_BUFFER_TYPE
	movq	_GSS_IOV_BUFFER_TYPE_PADDING@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	16(%r14,%rbx), %edi
	callq	_GSS_IOV_BUFFER_TYPE
	movq	_GSS_IOV_BUFFER_TYPE_TRAILER@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_5
	jmp	LBB0_6
LBB0_7:
	movq	%r13, %rdi
	callq	_malloc
	testq	%rax, %rax
	je	LBB0_23
## %bb.8:
	movq	%rax, %r15
	xorl	%ebx, %ebx
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_9 Depth=1
	movq	(%r14,%rbx), %rdx
	movq	8(%r14,%rbx), %rsi
	movq	%r15, %rdi
	callq	_memcpy
	movq	(%r14,%rbx), %rax
	leaq	(%r15,%rax,4), %r15
LBB0_13:                                ##   in Loop: Header=BB0_9 Depth=1
	addq	$24, %rbx
	cmpq	%rbx, %r12
	je	LBB0_14
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movl	16(%r14,%rbx), %edi
	callq	_GSS_IOV_BUFFER_TYPE
	movq	_GSS_IOV_BUFFER_TYPE_DATA@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_12
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	movl	16(%r14,%rbx), %edi
	callq	_GSS_IOV_BUFFER_TYPE
	movq	_GSS_IOV_BUFFER_TYPE_PADDING@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_9 Depth=1
	movl	16(%r14,%rbx), %edi
	callq	_GSS_IOV_BUFFER_TYPE
	movq	_GSS_IOV_BUFFER_TYPE_TRAILER@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_12
	jmp	LBB0_13
LBB0_22:
	xorl	%r13d, %r13d
	xorl	%edi, %edi
	callq	_malloc
	movq	%rax, %rbx
	movq	%rax, %r15
	testq	%rax, %rax
	jne	LBB0_15
LBB0_23:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movl	%eax, (%rcx)
	movq	_GSS_S_FAILURE@GOTPCREL(%rip), %rax
	jmp	LBB0_34
LBB0_14:
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
LBB0_15:
	subq	%rbx, %r15
	sarq	$2, %r15
	xorl	%edi, %edi
	cmpq	%r13, %r15
	sete	%dil
	callq	_assert
	movq	_GSS_S_COMPLETE@GOTPCREL(%rip), %rax
	cmpl	$0, -48(%rbp)                   ## 4-byte Folded Reload
	jle	LBB0_34
## %bb.16:
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	movq	%rbx, %r13
	leaq	(%rbx,%r15,4), %r12
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	shlq	$3, %rax
	leaq	(%rax,%rax,2), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	xorl	%ebx, %ebx
	jmp	LBB0_17
	.p2align	4, 0x90
LBB0_24:                                ##   in Loop: Header=BB0_17 Depth=1
	leaq	(,%r15,4), %rdi
	addq	8(%r14,%rbx), %rdi
	movq	%r12, %rsi
	callq	_memcpy
	movq	(%r14,%rbx), %rax
	subq	%r15, %rax
	leaq	(%r12,%rax,4), %r12
	xorl	%r15d, %r15d
LBB0_25:                                ##   in Loop: Header=BB0_17 Depth=1
	addq	$24, %rbx
	cmpq	%rbx, -48(%rbp)                 ## 8-byte Folded Reload
	je	LBB0_26
LBB0_17:                                ## =>This Inner Loop Header: Depth=1
	movl	16(%r14,%rbx), %edi
	callq	_GSS_IOV_BUFFER_TYPE
	movq	_GSS_IOV_BUFFER_TYPE_DATA@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_20
## %bb.18:                              ##   in Loop: Header=BB0_17 Depth=1
	movl	16(%r14,%rbx), %edi
	callq	_GSS_IOV_BUFFER_TYPE
	movq	_GSS_IOV_BUFFER_TYPE_PADDING@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_20
## %bb.19:                              ##   in Loop: Header=BB0_17 Depth=1
	movl	16(%r14,%rbx), %edi
	callq	_GSS_IOV_BUFFER_TYPE
	movq	_GSS_IOV_BUFFER_TYPE_TRAILER@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_25
	.p2align	4, 0x90
LBB0_20:                                ##   in Loop: Header=BB0_17 Depth=1
	movq	(%r14,%rbx), %rax
	movq	%rax, %rdx
	subq	%r15, %rdx
	ja	LBB0_24
## %bb.21:                              ##   in Loop: Header=BB0_17 Depth=1
	subq	%rax, %r15
	jmp	LBB0_25
LBB0_26:
	xorl	%ebx, %ebx
	movq	-64(%rbp), %r12                 ## 8-byte Reload
	jmp	LBB0_27
	.p2align	4, 0x90
LBB0_32:                                ##   in Loop: Header=BB0_27 Depth=1
	addq	$24, %rbx
	cmpq	%rbx, -48(%rbp)                 ## 8-byte Folded Reload
	je	LBB0_33
LBB0_27:                                ## =>This Inner Loop Header: Depth=1
	movl	16(%r14,%rbx), %edi
	callq	_GSS_IOV_BUFFER_TYPE
	movq	_GSS_IOV_BUFFER_TYPE_DATA@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_30
## %bb.28:                              ##   in Loop: Header=BB0_27 Depth=1
	movl	16(%r14,%rbx), %edi
	callq	_GSS_IOV_BUFFER_TYPE
	movq	_GSS_IOV_BUFFER_TYPE_PADDING@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_30
## %bb.29:                              ##   in Loop: Header=BB0_27 Depth=1
	movl	16(%r14,%rbx), %edi
	callq	_GSS_IOV_BUFFER_TYPE
	movq	_GSS_IOV_BUFFER_TYPE_TRAILER@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_32
	.p2align	4, 0x90
LBB0_30:                                ##   in Loop: Header=BB0_27 Depth=1
	movq	(%r14,%rbx), %rdi
	movq	8(%r14,%rbx), %r15
	movq	%r12, %rsi
	callq	_min
	movq	%r13, %rdi
	movq	%r15, %rsi
	movq	%rax, %rdx
	callq	_memcpy
	movq	(%r14,%rbx), %rax
	subq	%rax, %r12
	jb	LBB0_33
## %bb.31:                              ##   in Loop: Header=BB0_27 Depth=1
	leaq	(%r13,%rax,4), %r13
	jmp	LBB0_32
LBB0_33:
	movq	_GSS_S_COMPLETE@GOTPCREL(%rip), %rax
LBB0_34:
	movl	(%rax), %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GSS_IOV_BUFFER_TYPE_DATA,8,3   ## @GSS_IOV_BUFFER_TYPE_DATA
	.comm	_GSS_IOV_BUFFER_TYPE_PADDING,8,3 ## @GSS_IOV_BUFFER_TYPE_PADDING
	.comm	_GSS_IOV_BUFFER_TYPE_TRAILER,8,3 ## @GSS_IOV_BUFFER_TYPE_TRAILER
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_GSS_S_FAILURE,4,2              ## @GSS_S_FAILURE
	.comm	_GSS_S_COMPLETE,4,2             ## @GSS_S_COMPLETE
	.no_dead_strip	_unrotate_iov
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function unrotate_iov
_unrotate_iov:                          ; @unrotate_iov
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x22, x3
	mov	x20, x2
	mov	x28, x1
	mov	x24, x0
Lloh0:
	adrp	x25, _GSS_IOV_BUFFER_TYPE_DATA@GOTPAGE
Lloh1:
	ldr	x25, [x25, _GSS_IOV_BUFFER_TYPE_DATA@GOTPAGEOFF]
	mov	w27, w3
Lloh2:
	adrp	x26, _GSS_IOV_BUFFER_TYPE_PADDING@GOTPAGE
Lloh3:
	ldr	x26, [x26, _GSS_IOV_BUFFER_TYPE_PADDING@GOTPAGEOFF]
	cmp	w3, #1
	b.lt	LBB0_15
; %bb.1:
	mov	x23, #0
	add	x19, x20, #16
	mov	x21, x27
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldur	x8, [x19, #-16]
	add	x23, x8, x23
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	add	x19, x19, #24
	subs	x21, x21, #1
	b.eq	LBB0_7
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x19]
	bl	_GSS_IOV_BUFFER_TYPE
	ldr	x8, [x25]
	cmp	x0, x8
	b.eq	LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w0, [x19]
	bl	_GSS_IOV_BUFFER_TYPE
	ldr	x8, [x26]
	cmp	x0, x8
	b.eq	LBB0_2
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w0, [x19]
	bl	_GSS_IOV_BUFFER_TYPE
Lloh4:
	adrp	x8, _GSS_IOV_BUFFER_TYPE_TRAILER@GOTPAGE
Lloh5:
	ldr	x8, [x8, _GSS_IOV_BUFFER_TYPE_TRAILER@GOTPAGEOFF]
Lloh6:
	ldr	x8, [x8]
	cmp	x0, x8
	b.eq	LBB0_2
	b	LBB0_3
LBB0_7:
	mov	x0, x23
	bl	_malloc
	cbz	x0, LBB0_33
; %bb.8:
	mov	x21, x0
	mov	x8, x20
	mov	x20, x26
	str	x8, [sp, #8]                    ; 8-byte Folded Spill
	add	x19, x8, #16
	mov	x26, x27
	mov	x24, x0
	b	LBB0_11
LBB0_9:                                 ;   in Loop: Header=BB0_11 Depth=1
	ldp	x2, x1, [x19, #-16]
	mov	x0, x24
	bl	_memcpy
	ldur	x8, [x19, #-16]
	add	x24, x24, x8, lsl #2
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	add	x19, x19, #24
	subs	x26, x26, #1
	b.eq	LBB0_14
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x19]
	bl	_GSS_IOV_BUFFER_TYPE
	ldr	x8, [x25]
	cmp	x0, x8
	b.eq	LBB0_9
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	ldr	w0, [x19]
	bl	_GSS_IOV_BUFFER_TYPE
	ldr	x8, [x20]
	cmp	x0, x8
	b.eq	LBB0_9
; %bb.13:                               ;   in Loop: Header=BB0_11 Depth=1
	ldr	w0, [x19]
	bl	_GSS_IOV_BUFFER_TYPE
Lloh7:
	adrp	x8, _GSS_IOV_BUFFER_TYPE_TRAILER@GOTPAGE
Lloh8:
	ldr	x8, [x8, _GSS_IOV_BUFFER_TYPE_TRAILER@GOTPAGEOFF]
Lloh9:
	ldr	x8, [x8]
	cmp	x0, x8
	b.eq	LBB0_9
	b	LBB0_10
LBB0_14:
	mov	x26, x20
	ldr	x20, [sp, #8]                   ; 8-byte Folded Reload
	b	LBB0_17
LBB0_15:
	mov	x0, #0
	bl	_malloc
	cbz	x0, LBB0_33
; %bb.16:
	mov	x21, x0
	mov	x23, #0
	mov	x24, x0
LBB0_17:
	sub	x8, x24, x21
	cmp	x23, x8, asr #2
	cset	w0, eq
	bl	_assert
	cmp	w22, #1
	b.lt	LBB0_34
; %bb.18:
	add	x23, x20, #16
	mov	x24, x27
	mov	x19, x28
	add	x22, x21, x28, lsl #2
	b	LBB0_21
LBB0_19:                                ;   in Loop: Header=BB0_21 Depth=1
	ldur	x8, [x23, #-8]
	add	x0, x8, x19, lsl #2
	mov	x1, x22
	bl	_memcpy
	ldur	x8, [x23, #-16]
	sub	x8, x8, x19
	mov	x19, #0
	add	x22, x22, x8, lsl #2
LBB0_20:                                ;   in Loop: Header=BB0_21 Depth=1
	add	x23, x23, #24
	subs	x24, x24, #1
	b.eq	LBB0_26
LBB0_21:                                ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x23]
	bl	_GSS_IOV_BUFFER_TYPE
	ldr	x8, [x25]
	cmp	x0, x8
	b.eq	LBB0_24
; %bb.22:                               ;   in Loop: Header=BB0_21 Depth=1
	ldr	w0, [x23]
	bl	_GSS_IOV_BUFFER_TYPE
	ldr	x8, [x26]
	cmp	x0, x8
	b.eq	LBB0_24
; %bb.23:                               ;   in Loop: Header=BB0_21 Depth=1
	ldr	w0, [x23]
	bl	_GSS_IOV_BUFFER_TYPE
Lloh10:
	adrp	x8, _GSS_IOV_BUFFER_TYPE_TRAILER@GOTPAGE
Lloh11:
	ldr	x8, [x8, _GSS_IOV_BUFFER_TYPE_TRAILER@GOTPAGEOFF]
Lloh12:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_20
LBB0_24:                                ;   in Loop: Header=BB0_21 Depth=1
	ldur	x8, [x23, #-16]
	subs	x2, x8, x19
	b.hi	LBB0_19
; %bb.25:                               ;   in Loop: Header=BB0_21 Depth=1
	sub	x19, x19, x8
	b	LBB0_20
LBB0_26:
	add	x23, x20, #16
Lloh13:
	adrp	x22, _GSS_S_COMPLETE@GOTPAGE
Lloh14:
	ldr	x22, [x22, _GSS_S_COMPLETE@GOTPAGEOFF]
	b	LBB0_28
LBB0_27:                                ;   in Loop: Header=BB0_28 Depth=1
	add	x23, x23, #24
	subs	x27, x27, #1
	b.eq	LBB0_35
LBB0_28:                                ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x23]
	bl	_GSS_IOV_BUFFER_TYPE
	ldr	x8, [x25]
	cmp	x0, x8
	b.eq	LBB0_31
; %bb.29:                               ;   in Loop: Header=BB0_28 Depth=1
	ldr	w0, [x23]
	bl	_GSS_IOV_BUFFER_TYPE
	ldr	x8, [x26]
	cmp	x0, x8
	b.eq	LBB0_31
; %bb.30:                               ;   in Loop: Header=BB0_28 Depth=1
	ldr	w0, [x23]
	bl	_GSS_IOV_BUFFER_TYPE
Lloh15:
	adrp	x8, _GSS_IOV_BUFFER_TYPE_TRAILER@GOTPAGE
Lloh16:
	ldr	x8, [x8, _GSS_IOV_BUFFER_TYPE_TRAILER@GOTPAGEOFF]
Lloh17:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_27
LBB0_31:                                ;   in Loop: Header=BB0_28 Depth=1
	ldp	x0, x20, [x23, #-16]
	mov	x1, x28
	bl	_min
	mov	x2, x0
	mov	x0, x21
	mov	x1, x20
	bl	_memcpy
	ldur	x8, [x23, #-16]
	subs	x28, x28, x8
	b.lo	LBB0_35
; %bb.32:                               ;   in Loop: Header=BB0_28 Depth=1
	add	x21, x21, x8, lsl #2
	b	LBB0_27
LBB0_33:
Lloh18:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh19:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	str	w8, [x24]
Lloh21:
	adrp	x22, _GSS_S_FAILURE@GOTPAGE
Lloh22:
	ldr	x22, [x22, _GSS_S_FAILURE@GOTPAGEOFF]
	b	LBB0_35
LBB0_34:
Lloh23:
	adrp	x22, _GSS_S_COMPLETE@GOTPAGE
Lloh24:
	ldr	x22, [x22, _GSS_S_COMPLETE@GOTPAGEOFF]
LBB0_35:
	ldr	w0, [x22]
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	_GSS_IOV_BUFFER_TYPE_DATA,8,3   ; @GSS_IOV_BUFFER_TYPE_DATA
	.comm	_GSS_IOV_BUFFER_TYPE_PADDING,8,3 ; @GSS_IOV_BUFFER_TYPE_PADDING
	.comm	_GSS_IOV_BUFFER_TYPE_TRAILER,8,3 ; @GSS_IOV_BUFFER_TYPE_TRAILER
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_GSS_S_FAILURE,4,2              ; @GSS_S_FAILURE
	.comm	_GSS_S_COMPLETE,4,2             ; @GSS_S_COMPLETE
	.no_dead_strip	_unrotate_iov
.subsections_via_symbols
