	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mlx5_modify_qp                 ## -- Begin function mlx5_modify_qp
	.p2align	4, 0x90
_mlx5_modify_qp:                        ## @mlx5_modify_qp
	.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
	movl	%edx, %r12d
	movq	%rsi, %rbx
	movq	%rdi, %r15
	movl	$0, -64(%rbp)
	movl	$0, -56(%rbp)
	movl	$0, -48(%rbp)
	callq	_to_mqp
	movq	%rax, %r14
	movl	32(%r15), %edi
	callq	_to_mctx
	cmpq	$0, 32(%r14)
	je	LBB0_2
## %bb.1:
	movq	_ENOSYS@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	jmp	LBB0_29
LBB0_2:
	movq	%rax, %r13
	movq	_IBV_QP_PORT@GOTPCREL(%rip), %rax
	testl	%r12d, (%rax)
	je	LBB0_9
## %bb.3:
	cmpl	$128, (%r15)
	jne	LBB0_9
## %bb.4:
	movq	16(%r13), %rax
	movslq	8(%rbx), %rcx
	movl	-4(%rax,%rcx,4), %eax
	movq	_IBV_LINK_LAYER_ETHERNET@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_9
## %bb.5:
	movq	_IBV_DEVICE_RAW_IP_CSUM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r13)
	je	LBB0_7
## %bb.6:
	movq	_MLX5_CSUM_SUPPORT_RAW_OVER_ETH@GOTPCREL(%rip), %rax
	movq	_MLX5_RX_CSUM_VALID@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	orl	%ecx, (%r14)
LBB0_7:
	movl	8(%r13), %edi
	movl	$128, %esi
	callq	_ibv_is_qpt_supported
	testl	%eax, %eax
	je	LBB0_9
## %bb.8:
	movl	4(%r13), %eax
	movl	%eax, 28(%r14)
LBB0_9:
	movq	_MLX5_MODIFY_QP_EX_ATTR_MASK@GOTPCREL(%rip), %rax
	testl	%r12d, (%rax)
	movq	%rbx, -80(%rbp)                 ## 8-byte Spill
	je	LBB0_11
## %bb.10:
	subq	$8, %rsp
	leaq	-48(%rbp), %rax
	leaq	-56(%rbp), %rcx
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movl	%r12d, %edx
	movl	$4, %r8d
	movl	$4, %r9d
	pushq	$4
	pushq	$4
	pushq	%rax
	callq	_ibv_cmd_modify_qp_ex
	addq	$32, %rsp
	jmp	LBB0_12
LBB0_11:
	leaq	-64(%rbp), %rcx
	movq	%r15, %rdi
	movq	%rbx, %rsi
	movl	%r12d, %edx
	movl	$4, %r8d
	callq	_ibv_cmd_modify_qp
LBB0_12:
	movl	%eax, %r13d
	testl	%eax, %eax
	je	LBB0_13
LBB0_29:
	movl	%r13d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_13:
	movq	_IBV_QP_STATE@GOTPCREL(%rip), %rbx
	xorl	%r13d, %r13d
	testl	%r12d, (%rbx)
	je	LBB0_29
## %bb.14:
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movq	_IBV_QPS_RESET@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_26
## %bb.15:
	movq	8(%r15), %rdi
	testq	%rdi, %rdi
	je	LBB0_16
## %bb.17:
	callq	_to_mcq
	movl	24(%r14), %esi
	movq	24(%r15), %rdi
	testq	%rdi, %rdi
	je	LBB0_18
## %bb.19:
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movl	%esi, -68(%rbp)                 ## 4-byte Spill
	callq	_to_msrq
	movl	-68(%rbp), %esi                 ## 4-byte Reload
	movq	%rax, %rdx
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	jmp	LBB0_20
LBB0_16:
	xorl	%eax, %eax
	jmp	LBB0_21
LBB0_18:
	xorl	%edx, %edx
LBB0_20:
	movl	%eax, %edi
	callq	_mlx5_cq_clean
	movq	8(%r15), %rax
LBB0_21:
	movq	16(%r15), %rdi
	testq	%rdi, %rdi
	je	LBB0_24
## %bb.22:
	cmpq	%rax, %rdi
	je	LBB0_24
## %bb.23:
	callq	_to_mcq
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	%r15, %rdi
	callq	_to_mqp
	movl	24(%rax), %esi
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	xorl	%edx, %edx
	callq	_mlx5_cq_clean
LBB0_24:
	movq	%r14, %rdi
	callq	_mlx5_init_qp_indices
	movq	16(%r14), %rax
	movq	_MLX5_RCV_DBR@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	$0, (%rax,%rcx,8)
	movq	_MLX5_SND_DBR@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	$0, (%rax,%rcx,8)
	testl	%r12d, (%rbx)
	je	LBB0_25
LBB0_26:
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movq	_IBV_QPS_RTR@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_29
## %bb.27:
	cmpl	$128, (%r15)
	jne	LBB0_29
## %bb.28:
	movq	%r14, %rbx
	addq	$8, %rbx
	movq	%rbx, %rdi
	callq	_mlx5_spin_lock
	movzwl	4(%r14), %edi
	callq	_htobe32
	movq	16(%r14), %rcx
	movq	_MLX5_RCV_DBR@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movq	%rax, (%rcx,%rdx,8)
	movq	%rbx, %rdi
	callq	_mlx5_spin_unlock
	jmp	LBB0_29
LBB0_25:
	xorl	%r13d, %r13d
	jmp	LBB0_29
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOSYS,4,2                     ## @ENOSYS
	.comm	_IBV_QP_PORT,4,2                ## @IBV_QP_PORT
	.comm	_IBV_LINK_LAYER_ETHERNET,4,2    ## @IBV_LINK_LAYER_ETHERNET
	.comm	_IBV_DEVICE_RAW_IP_CSUM,4,2     ## @IBV_DEVICE_RAW_IP_CSUM
	.comm	_MLX5_CSUM_SUPPORT_RAW_OVER_ETH,4,2 ## @MLX5_CSUM_SUPPORT_RAW_OVER_ETH
	.comm	_MLX5_RX_CSUM_VALID,4,2         ## @MLX5_RX_CSUM_VALID
	.comm	_MLX5_MODIFY_QP_EX_ATTR_MASK,4,2 ## @MLX5_MODIFY_QP_EX_ATTR_MASK
	.comm	_IBV_QP_STATE,4,2               ## @IBV_QP_STATE
	.comm	_IBV_QPS_RESET,8,3              ## @IBV_QPS_RESET
	.comm	_MLX5_RCV_DBR,8,3               ## @MLX5_RCV_DBR
	.comm	_MLX5_SND_DBR,8,3               ## @MLX5_SND_DBR
	.comm	_IBV_QPS_RTR,8,3                ## @IBV_QPS_RTR
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mlx5_modify_qp                 ; -- Begin function mlx5_modify_qp
	.p2align	2
_mlx5_modify_qp:                        ; @mlx5_modify_qp
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	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
	mov	x22, x2
	mov	x21, x1
	mov	x20, x0
	str	wzr, [sp, #24]
	str	wzr, [sp, #16]
	str	wzr, [sp, #8]
	bl	_to_mqp
	mov	x19, x0
	ldr	w0, [x20, #32]
	bl	_to_mctx
	ldr	x8, [x19, #32]
	cbz	x8, LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _ENOSYS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENOSYS@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	b	LBB0_28
LBB0_2:
Lloh3:
	adrp	x8, _IBV_QP_PORT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _IBV_QP_PORT@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	tst	w8, w22
	b.eq	LBB0_9
; %bb.3:
	ldr	w8, [x20]
	cmp	w8, #128
	b.ne	LBB0_9
; %bb.4:
	mov	x23, x0
	ldr	x8, [x0, #16]
	ldrsw	x9, [x21, #8]
	add	x8, x8, x9, lsl #2
	ldur	w8, [x8, #-4]
Lloh6:
	adrp	x9, _IBV_LINK_LAYER_ETHERNET@GOTPAGE
Lloh7:
	ldr	x9, [x9, _IBV_LINK_LAYER_ETHERNET@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	cmp	w8, w9
	b.ne	LBB0_9
; %bb.5:
	ldr	w8, [x23]
Lloh9:
	adrp	x9, _IBV_DEVICE_RAW_IP_CSUM@GOTPAGE
Lloh10:
	ldr	x9, [x9, _IBV_DEVICE_RAW_IP_CSUM@GOTPAGEOFF]
Lloh11:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_7
; %bb.6:
Lloh12:
	adrp	x8, _MLX5_CSUM_SUPPORT_RAW_OVER_ETH@GOTPAGE
Lloh13:
	ldr	x8, [x8, _MLX5_CSUM_SUPPORT_RAW_OVER_ETH@GOTPAGEOFF]
Lloh14:
	adrp	x9, _MLX5_RX_CSUM_VALID@GOTPAGE
Lloh15:
	ldr	x9, [x9, _MLX5_RX_CSUM_VALID@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
Lloh17:
	ldr	w9, [x9]
	orr	w8, w9, w8
	ldr	w9, [x19]
	orr	w8, w8, w9
	str	w8, [x19]
LBB0_7:
	ldr	w0, [x23, #8]
	mov	w1, #128
	bl	_ibv_is_qpt_supported
	cbz	w0, LBB0_9
; %bb.8:
	ldr	w8, [x23, #4]
	str	w8, [x19, #28]
LBB0_9:
Lloh18:
	adrp	x8, _MLX5_MODIFY_QP_EX_ATTR_MASK@GOTPAGE
Lloh19:
	ldr	x8, [x8, _MLX5_MODIFY_QP_EX_ATTR_MASK@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	tst	w8, w22
	b.eq	LBB0_11
; %bb.10:
	mov	w8, #4
	str	w8, [sp]
	add	x3, sp, #16
	add	x6, sp, #8
	mov	x0, x20
	mov	x1, x21
	mov	x2, x22
	mov	w4, #4
	mov	w5, #4
	mov	w7, #4
	bl	_ibv_cmd_modify_qp_ex
	cbnz	w0, LBB0_28
	b	LBB0_12
LBB0_11:
	add	x3, sp, #24
	mov	x0, x20
	mov	x1, x21
	mov	x2, x22
	mov	w4, #4
	bl	_ibv_cmd_modify_qp
	cbnz	w0, LBB0_28
LBB0_12:
Lloh21:
	adrp	x25, _IBV_QP_STATE@GOTPAGE
Lloh22:
	ldr	x25, [x25, _IBV_QP_STATE@GOTPAGEOFF]
	ldr	w8, [x25]
	tst	w8, w22
	b.eq	LBB0_27
; %bb.13:
	ldr	x8, [x21]
Lloh23:
	adrp	x9, _IBV_QPS_RESET@GOTPAGE
Lloh24:
	ldr	x9, [x9, _IBV_QPS_RESET@GOTPAGEOFF]
Lloh25:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_24
; %bb.14:
	ldr	x0, [x20, #8]
	cbz	x0, LBB0_17
; %bb.15:
	bl	_to_mcq
	mov	x23, x0
	ldr	w24, [x19, #24]
	ldr	x0, [x20, #24]
	cbz	x0, LBB0_18
; %bb.16:
	bl	_to_msrq
	mov	x2, x0
	b	LBB0_19
LBB0_17:
	mov	x8, #0
	b	LBB0_20
LBB0_18:
	mov	x2, #0
LBB0_19:
	mov	x0, x23
	mov	x1, x24
	bl	_mlx5_cq_clean
	ldr	x8, [x20, #8]
LBB0_20:
	ldr	x0, [x20, #16]
	cbz	x0, LBB0_23
; %bb.21:
	cmp	x0, x8
	b.eq	LBB0_23
; %bb.22:
	bl	_to_mcq
	mov	x23, x0
	mov	x0, x20
	bl	_to_mqp
	ldr	w1, [x0, #24]
	mov	x0, x23
	mov	x2, #0
	bl	_mlx5_cq_clean
LBB0_23:
	mov	x0, x19
	bl	_mlx5_init_qp_indices
Lloh26:
	adrp	x8, _MLX5_RCV_DBR@GOTPAGE
Lloh27:
	ldr	x8, [x8, _MLX5_RCV_DBR@GOTPAGEOFF]
	ldr	x9, [x19, #16]
Lloh28:
	ldr	x8, [x8]
	str	xzr, [x9, x8, lsl #3]
Lloh29:
	adrp	x8, _MLX5_SND_DBR@GOTPAGE
Lloh30:
	ldr	x8, [x8, _MLX5_SND_DBR@GOTPAGEOFF]
Lloh31:
	ldr	x8, [x8]
	str	xzr, [x9, x8, lsl #3]
	ldr	w8, [x25]
	tst	w8, w22
	b.eq	LBB0_27
LBB0_24:
	ldr	x8, [x21]
Lloh32:
	adrp	x9, _IBV_QPS_RTR@GOTPAGE
Lloh33:
	ldr	x9, [x9, _IBV_QPS_RTR@GOTPAGEOFF]
Lloh34:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_27
; %bb.25:
	ldr	w8, [x20]
	cmp	w8, #128
	b.ne	LBB0_27
; %bb.26:
	add	x20, x19, #8
	mov	x0, x20
	bl	_mlx5_spin_lock
	ldrh	w0, [x19, #4]
	bl	_htobe32
	ldr	x8, [x19, #16]
Lloh35:
	adrp	x9, _MLX5_RCV_DBR@GOTPAGE
Lloh36:
	ldr	x9, [x9, _MLX5_RCV_DBR@GOTPAGEOFF]
Lloh37:
	ldr	x9, [x9]
	str	x0, [x8, x9, lsl #3]
	mov	x0, x20
	bl	_mlx5_spin_unlock
LBB0_27:
	mov	w0, #0
LBB0_28:
	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
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh17
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh16
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOSYS,4,2                     ; @ENOSYS
	.comm	_IBV_QP_PORT,4,2                ; @IBV_QP_PORT
	.comm	_IBV_LINK_LAYER_ETHERNET,4,2    ; @IBV_LINK_LAYER_ETHERNET
	.comm	_IBV_DEVICE_RAW_IP_CSUM,4,2     ; @IBV_DEVICE_RAW_IP_CSUM
	.comm	_MLX5_CSUM_SUPPORT_RAW_OVER_ETH,4,2 ; @MLX5_CSUM_SUPPORT_RAW_OVER_ETH
	.comm	_MLX5_RX_CSUM_VALID,4,2         ; @MLX5_RX_CSUM_VALID
	.comm	_MLX5_MODIFY_QP_EX_ATTR_MASK,4,2 ; @MLX5_MODIFY_QP_EX_ATTR_MASK
	.comm	_IBV_QP_STATE,4,2               ; @IBV_QP_STATE
	.comm	_IBV_QPS_RESET,8,3              ; @IBV_QPS_RESET
	.comm	_MLX5_RCV_DBR,8,3               ; @MLX5_RCV_DBR
	.comm	_MLX5_SND_DBR,8,3               ; @MLX5_SND_DBR
	.comm	_IBV_QPS_RTR,8,3                ; @IBV_QPS_RTR
.subsections_via_symbols
