	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function raid10_format_to_md_layout
_raid10_format_to_md_layout:            ## @raid10_format_to_md_layout
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movl	%edx, %ebx
	movq	_ALGORITHM_RAID10_DEFAULT@GOTPCREL(%rip), %rcx
	xorl	%r14d, %r14d
	cmpl	%esi, (%rcx)
	je	LBB0_1
## %bb.2:
	movq	_ALGORITHM_RAID10_NEAR@GOTPCREL(%rip), %rcx
	cmpl	%esi, (%rcx)
	je	LBB0_1
## %bb.3:
	movq	%rdi, %rax
	movq	_ALGORITHM_RAID10_OFFSET@GOTPCREL(%rip), %rcx
	cmpl	%esi, (%rcx)
	jne	LBB0_8
## %bb.4:
	movq	_RAID10_OFFSET@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r14d
	jmp	LBB0_5
LBB0_1:
	movl	%ebx, %edx
	movl	$1, %ebx
	jmp	LBB0_7
LBB0_8:
	movq	_ALGORITHM_RAID10_FAR@GOTPCREL(%rip), %rcx
	cmpl	%esi, (%rcx)
	jne	LBB0_10
## %bb.9:
	movq	_RAID10_OFFSET@GOTPCREL(%rip), %rcx
	xorl	%r14d, %r14d
	cmpl	$0, (%rcx)
	sete	%r14b
LBB0_5:
	movq	___CTR_FLAG_RAID10_USE_NEAR_SETS@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edi
	movq	%rax, %rsi
	callq	_test_bit
	movl	$1, %edx
	testl	%eax, %eax
	jne	LBB0_7
## %bb.6:
	movq	_RAID10_USE_FAR_SETS@GOTPCREL(%rip), %rax
	orl	(%rax), %r14d
LBB0_7:
	orl	%r14d, %edx
	movq	_RAID10_FAR_COPIES_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	shll	%cl, %ebx
	orl	%edx, %ebx
LBB0_11:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_10:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.comm	_ALGORITHM_RAID10_DEFAULT,4,2   ## @ALGORITHM_RAID10_DEFAULT
	.comm	_ALGORITHM_RAID10_NEAR,4,2      ## @ALGORITHM_RAID10_NEAR
	.comm	_ALGORITHM_RAID10_OFFSET,4,2    ## @ALGORITHM_RAID10_OFFSET
	.comm	_RAID10_OFFSET,4,2              ## @RAID10_OFFSET
	.comm	___CTR_FLAG_RAID10_USE_NEAR_SETS,4,2 ## @__CTR_FLAG_RAID10_USE_NEAR_SETS
	.comm	_RAID10_USE_FAR_SETS,4,2        ## @RAID10_USE_FAR_SETS
	.comm	_ALGORITHM_RAID10_FAR,4,2       ## @ALGORITHM_RAID10_FAR
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_RAID10_FAR_COPIES_SHIFT,4,2    ## @RAID10_FAR_COPIES_SHIFT
	.no_dead_strip	_raid10_format_to_md_layout
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function raid10_format_to_md_layout
_raid10_format_to_md_layout:            ; @raid10_format_to_md_layout
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x2
Lloh0:
	adrp	x9, _ALGORITHM_RAID10_DEFAULT@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ALGORITHM_RAID10_DEFAULT@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
Lloh3:
	adrp	x10, _ALGORITHM_RAID10_NEAR@GOTPAGE
Lloh4:
	ldr	x10, [x10, _ALGORITHM_RAID10_NEAR@GOTPAGEOFF]
Lloh5:
	ldr	w10, [x10]
	cmp	w9, w1
	ccmp	w10, w1, #4, ne
	b.ne	LBB0_2
; %bb.1:
	mov	w20, #0
	mov	x8, x19
	mov	w19, #1
	b	LBB0_9
LBB0_2:
	mov	x8, x0
Lloh6:
	adrp	x9, _ALGORITHM_RAID10_OFFSET@GOTPAGE
Lloh7:
	ldr	x9, [x9, _ALGORITHM_RAID10_OFFSET@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	cmp	w9, w1
	b.ne	LBB0_4
; %bb.3:
Lloh9:
	adrp	x9, _RAID10_OFFSET@GOTPAGE
Lloh10:
	ldr	x9, [x9, _RAID10_OFFSET@GOTPAGEOFF]
Lloh11:
	ldr	w20, [x9]
	b	LBB0_6
LBB0_4:
Lloh12:
	adrp	x9, _ALGORITHM_RAID10_FAR@GOTPAGE
Lloh13:
	ldr	x9, [x9, _ALGORITHM_RAID10_FAR@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	cmp	w9, w1
	b.ne	LBB0_11
; %bb.5:
Lloh15:
	adrp	x9, _RAID10_OFFSET@GOTPAGE
Lloh16:
	ldr	x9, [x9, _RAID10_OFFSET@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	cmp	w9, #0
	cset	w20, eq
LBB0_6:
Lloh18:
	adrp	x9, ___CTR_FLAG_RAID10_USE_NEAR_SETS@GOTPAGE
Lloh19:
	ldr	x9, [x9, ___CTR_FLAG_RAID10_USE_NEAR_SETS@GOTPAGEOFF]
Lloh20:
	ldr	w0, [x9]
	mov	x1, x8
	bl	_test_bit
	cbnz	w0, LBB0_8
; %bb.7:
Lloh21:
	adrp	x8, _RAID10_USE_FAR_SETS@GOTPAGE
Lloh22:
	ldr	x8, [x8, _RAID10_USE_FAR_SETS@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	orr	w20, w8, w20
LBB0_8:
	mov	w8, #1
LBB0_9:
Lloh24:
	adrp	x9, _RAID10_FAR_COPIES_SHIFT@GOTPAGE
Lloh25:
	ldr	x9, [x9, _RAID10_FAR_COPIES_SHIFT@GOTPAGEOFF]
Lloh26:
	ldr	w9, [x9]
	lsl	w9, w19, w9
	orr	w8, w20, w8
	orr	w0, w8, w9
LBB0_10:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_11:
Lloh27:
	adrp	x8, _EINVAL@GOTPAGE
Lloh28:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh29:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_10
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.comm	_ALGORITHM_RAID10_DEFAULT,4,2   ; @ALGORITHM_RAID10_DEFAULT
	.comm	_ALGORITHM_RAID10_NEAR,4,2      ; @ALGORITHM_RAID10_NEAR
	.comm	_ALGORITHM_RAID10_OFFSET,4,2    ; @ALGORITHM_RAID10_OFFSET
	.comm	_RAID10_OFFSET,4,2              ; @RAID10_OFFSET
	.comm	___CTR_FLAG_RAID10_USE_NEAR_SETS,4,2 ; @__CTR_FLAG_RAID10_USE_NEAR_SETS
	.comm	_RAID10_USE_FAR_SETS,4,2        ; @RAID10_USE_FAR_SETS
	.comm	_ALGORITHM_RAID10_FAR,4,2       ; @ALGORITHM_RAID10_FAR
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_RAID10_FAR_COPIES_SHIFT,4,2    ; @RAID10_FAR_COPIES_SHIFT
	.no_dead_strip	_raid10_format_to_md_layout
.subsections_via_symbols
