	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function hns_roce_mhop_free
LCPI0_0:
	.space	16
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_hns_roce_mhop_free:                    ## @hns_roce_mhop_free
	.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	%rsi, %rbx
	movq	8(%rdi), %r15
	movl	(%rsi), %esi
	movq	_PAGE_SHIFT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	addl	(%rdi), %ecx
	movl	$1, %r12d
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %r12d
	movq	8(%rbx), %rax
	movq	_MR_TYPE_FRMR@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_1
## %bb.22:
	movq	_HNS_ROCE_HOP_NUM_0@GOTPCREL(%rip), %rax
	cmpl	$1, (%rax)
	je	LBB0_21
	jmp	LBB0_23
LBB0_1:
	movl	4(%rdi), %r14d
	movq	_HNS_ROCE_HOP_NUM_0@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r14d
	jne	LBB0_2
LBB0_21:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_2:
	cmpl	$1, %r14d
	jne	LBB0_3
LBB0_23:
	movq	_BA_BYTE_LEN@GOTPCREL(%rip), %rax
	imull	(%rax), %esi
	movl	64(%rbx), %ecx
	movl	68(%rbx), %edx
	movq	%r15, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_dma_free_coherent              ## TAILCALL
LBB0_3:
	movl	%esi, -44(%rbp)                 ## 4-byte Spill
	movl	56(%rbx), %ecx
	movl	60(%rbx), %edx
	movq	%r15, %rdi
	movl	%r12d, %esi
	callq	_dma_free_coherent
	cmpl	$2, %r14d
	movl	%r14d, -48(%rbp)                ## 4-byte Spill
	je	LBB0_12
## %bb.4:
	cmpl	$3, %r14d
	jne	LBB0_19
## %bb.5:
	cmpl	$0, 16(%rbx)
	jle	LBB0_19
## %bb.6:
	xorl	%r13d, %r13d
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_18:                                ##   in Loop: Header=BB0_7 Depth=1
	incq	%r13
	movslq	16(%rbx), %rax
	cmpq	%rax, %r13
	jge	LBB0_19
LBB0_7:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_9 Depth 2
	movq	40(%rbx), %rax
	movq	48(%rbx), %rcx
	movl	(%rcx,%r13,4), %edx
	movl	(%rax,%r13,4), %ecx
	movq	%r15, %rdi
	movl	%r12d, %esi
	callq	_dma_free_coherent
	movq	_BA_BYTE_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	%r12d, %eax
	cltd
	idivl	%ecx
	testl	%eax, %eax
	jle	LBB0_18
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	xorl	%r14d, %r14d
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_17:                                ##   in Loop: Header=BB0_9 Depth=2
	movq	24(%rbx), %rax
	movq	32(%rbx), %rcx
	movslq	%edx, %rsi
	movl	(%rcx,%rsi,4), %edx
	movl	(%rax,%rsi,4), %ecx
	movq	%r15, %rdi
	movl	%r12d, %esi
	callq	_dma_free_coherent
	incl	%r14d
	movq	_BA_BYTE_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	%r12d, %eax
	cltd
	idivl	%ecx
	cmpl	%eax, %r14d
	jge	LBB0_18
LBB0_9:                                 ##   Parent Loop BB0_7 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	%r13d, %edx
	imull	%eax, %edx
	addl	%r14d, %edx
	movl	16(%rbx), %esi
	decl	%esi
	cmpq	%rsi, %r13
	jne	LBB0_17
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=2
	movl	20(%rbx), %esi
	decl	%esi
	cmpl	%esi, %r14d
	jne	LBB0_17
## %bb.11:                              ##   in Loop: Header=BB0_7 Depth=1
	imull	%edx, %eax
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	subl	%eax, %esi
	imull	%ecx, %esi
	movq	24(%rbx), %rax
	movq	32(%rbx), %rcx
	movslq	%edx, %rdi
	movl	(%rcx,%rdi,4), %edx
	movl	(%rax,%rdi,4), %ecx
	movq	%r15, %rdi
	callq	_dma_free_coherent
	jmp	LBB0_18
LBB0_12:
	movl	16(%rbx), %eax
	testl	%eax, %eax
	jle	LBB0_19
## %bb.13:
	xorl	%r14d, %r14d
	.p2align	4, 0x90
LBB0_14:                                ## =>This Inner Loop Header: Depth=1
	decl	%eax
	cmpq	%rax, %r14
	je	LBB0_15
## %bb.16:                              ##   in Loop: Header=BB0_14 Depth=1
	movq	40(%rbx), %rax
	movq	48(%rbx), %rcx
	movl	(%rcx,%r14,4), %edx
	movl	(%rax,%r14,4), %ecx
	movq	%r15, %rdi
	movl	%r12d, %esi
	callq	_dma_free_coherent
	incq	%r14
	movslq	16(%rbx), %rax
	cmpq	%rax, %r14
	jl	LBB0_14
	jmp	LBB0_19
LBB0_15:
	movq	_BA_BYTE_LEN@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	%r12d, %eax
	cltd
	idivl	%ecx
	movl	%r14d, %edx
	imull	%eax, %edx
	movl	-44(%rbp), %esi                 ## 4-byte Reload
	subl	%edx, %esi
	imull	%ecx, %esi
	movq	40(%rbx), %rax
	movq	48(%rbx), %rcx
	movl	(%rcx,%r14,4), %edx
	movl	(%rax,%r14,4), %ecx
	movq	%r15, %rdi
	callq	_dma_free_coherent
LBB0_19:
	movq	48(%rbx), %rdi
	callq	_kfree
	movq	40(%rbx), %rdi
	callq	_kfree
	xorps	%xmm0, %xmm0
	movups	%xmm0, 40(%rbx)
	cmpl	$3, -48(%rbp)                   ## 4-byte Folded Reload
	jne	LBB0_21
## %bb.20:
	movq	32(%rbx), %rdi
	callq	_kfree
	movq	24(%rbx), %rdi
	callq	_kfree
	xorps	%xmm0, %xmm0
	movups	%xmm0, 24(%rbx)
	jmp	LBB0_21
	.cfi_endproc
                                        ## -- End function
	.comm	_PAGE_SHIFT,4,2                 ## @PAGE_SHIFT
	.comm	_MR_TYPE_FRMR,8,3               ## @MR_TYPE_FRMR
	.comm	_HNS_ROCE_HOP_NUM_0,4,2         ## @HNS_ROCE_HOP_NUM_0
	.comm	_BA_BYTE_LEN,4,2                ## @BA_BYTE_LEN
	.no_dead_strip	_hns_roce_mhop_free
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function hns_roce_mhop_free
_hns_roce_mhop_free:                    ; @hns_roce_mhop_free
	.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
	mov	x19, x1
	ldr	x20, [x0, #8]
	ldr	w23, [x1]
	ldr	x8, [x1, #8]
Lloh0:
	adrp	x9, _MR_TYPE_FRMR@GOTPAGE
Lloh1:
	ldr	x9, [x9, _MR_TYPE_FRMR@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_2
; %bb.1:
Lloh3:
	adrp	x8, _HNS_ROCE_HOP_NUM_0@GOTPAGE
Lloh4:
	ldr	x8, [x8, _HNS_ROCE_HOP_NUM_0@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmp	w8, #1
	b.eq	LBB0_3
	b	LBB0_5
LBB0_2:
	ldr	w22, [x0, #4]
Lloh6:
	adrp	x8, _HNS_ROCE_HOP_NUM_0@GOTPAGE
Lloh7:
	ldr	x8, [x8, _HNS_ROCE_HOP_NUM_0@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	cmp	w22, w8
	b.ne	LBB0_4
LBB0_3:
	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
LBB0_4:
	cmp	w22, #1
	b.ne	LBB0_6
LBB0_5:
Lloh9:
	adrp	x8, _BA_BYTE_LEN@GOTPAGE
Lloh10:
	ldr	x8, [x8, _BA_BYTE_LEN@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	mul	w1, w8, w23
	ldp	w3, w2, [x19, #64]
	mov	x0, x20
	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
	b	_dma_free_coherent
LBB0_6:
	ldr	w8, [x0]
Lloh12:
	adrp	x9, _PAGE_SHIFT@GOTPAGE
Lloh13:
	ldr	x9, [x9, _PAGE_SHIFT@GOTPAGEOFF]
Lloh14:
	ldr	w9, [x9]
	add	w8, w9, w8
	mov	w9, #1
	lsl	w21, w9, w8
	ldp	w3, w2, [x19, #56]
	mov	x0, x20
	mov	x1, x21
	bl	_dma_free_coherent
	cmp	w22, #2
	b.eq	LBB0_17
; %bb.7:
	cmp	w22, #3
	b.ne	LBB0_22
; %bb.8:
	ldr	w8, [x19, #16]
	cmp	w8, #1
	b.lt	LBB0_22
; %bb.9:
	mov	x24, #0
Lloh15:
	adrp	x25, _BA_BYTE_LEN@GOTPAGE
Lloh16:
	ldr	x25, [x25, _BA_BYTE_LEN@GOTPAGEOFF]
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	add	x24, x24, #1
	ldrsw	x8, [x19, #16]
	cmp	x24, x8
	b.ge	LBB0_22
LBB0_11:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_14 Depth 2
	lsl	x8, x24, #2
	ldp	x10, x9, [x19, #40]
	ldr	w2, [x9, x8]
	ldr	w3, [x10, x8]
	mov	x0, x20
	mov	x1, x21
	bl	_dma_free_coherent
	ldr	w8, [x25]
	sdiv	w9, w21, w8
	cmp	w9, #1
	b.lt	LBB0_10
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	mov	w26, #0
	b	LBB0_14
LBB0_13:                                ;   in Loop: Header=BB0_14 Depth=2
	sbfiz	x8, x10, #2, #32
	ldp	x10, x9, [x19, #24]
	ldr	w2, [x9, x8]
	ldr	w3, [x10, x8]
	mov	x0, x20
	mov	x1, x21
	bl	_dma_free_coherent
	add	w26, w26, #1
	ldr	w8, [x25]
	sdiv	w9, w21, w8
	cmp	w26, w9
	b.ge	LBB0_10
LBB0_14:                                ;   Parent Loop BB0_11 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	madd	w10, w24, w9, w26
	ldr	w11, [x19, #16]
	sub	w11, w11, #1
	cmp	x24, x11
	b.ne	LBB0_13
; %bb.15:                               ;   in Loop: Header=BB0_14 Depth=2
	ldr	w11, [x19, #20]
	sub	w11, w11, #1
	cmp	w26, w11
	b.ne	LBB0_13
; %bb.16:                               ;   in Loop: Header=BB0_11 Depth=1
	msub	w9, w10, w9, w23
	mul	w1, w9, w8
                                        ; kill: def $w10 killed $w10 killed $x10 def $x10
	sbfiz	x8, x10, #2, #32
	ldp	x10, x9, [x19, #24]
	ldr	w2, [x9, x8]
	ldr	w3, [x10, x8]
	mov	x0, x20
	bl	_dma_free_coherent
	b	LBB0_10
LBB0_17:
	ldr	w8, [x19, #16]
	cmp	w8, #1
	b.lt	LBB0_22
; %bb.18:
	mov	x24, #0
LBB0_19:                                ; =>This Inner Loop Header: Depth=1
	sub	w9, w8, #1
	lsl	x8, x24, #2
	cmp	x24, x9
	b.eq	LBB0_21
; %bb.20:                               ;   in Loop: Header=BB0_19 Depth=1
	ldp	x10, x9, [x19, #40]
	ldr	w2, [x9, x8]
	ldr	w3, [x10, x8]
	mov	x0, x20
	mov	x1, x21
	bl	_dma_free_coherent
	add	x24, x24, #1
	ldrsw	x8, [x19, #16]
	cmp	x24, x8
	b.lt	LBB0_19
	b	LBB0_22
LBB0_21:
Lloh17:
	adrp	x9, _BA_BYTE_LEN@GOTPAGE
Lloh18:
	ldr	x9, [x9, _BA_BYTE_LEN@GOTPAGEOFF]
Lloh19:
	ldr	w9, [x9]
	sdiv	w10, w21, w9
	msub	w10, w10, w24, w23
	mul	w1, w10, w9
	ldp	x10, x9, [x19, #40]
	ldr	w2, [x9, x8]
	ldr	w3, [x10, x8]
	mov	x0, x20
	bl	_dma_free_coherent
LBB0_22:
	ldr	x0, [x19, #48]
	bl	_kfree
	ldr	x0, [x19, #40]
	bl	_kfree
	stp	xzr, xzr, [x19, #40]
	cmp	w22, #3
	b.ne	LBB0_3
; %bb.23:
	ldr	x0, [x19, #32]
	bl	_kfree
	ldr	x0, [x19, #24]
	bl	_kfree
	stp	xzr, xzr, [x19, #24]
	b	LBB0_3
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_PAGE_SHIFT,4,2                 ; @PAGE_SHIFT
	.comm	_MR_TYPE_FRMR,8,3               ; @MR_TYPE_FRMR
	.comm	_HNS_ROCE_HOP_NUM_0,4,2         ; @HNS_ROCE_HOP_NUM_0
	.comm	_BA_BYTE_LEN,4,2                ; @BA_BYTE_LEN
	.no_dead_strip	_hns_roce_mhop_free
.subsections_via_symbols
