	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function set_user_buf_size
_set_user_buf_size:                     ## @set_user_buf_size
	.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
	movq	%rcx, -48(%rbp)                 ## 8-byte Spill
	movq	%rsi, %r15
	movb	4(%rsi), %cl
	movl	$1, %ebx
	shll	%cl, %ebx
	movq	%r8, -56(%rbp)                  ## 8-byte Spill
	movq	%rdx, %r14
	movq	%rdi, %r13
	movl	(%rdi), %edi
	movq	_max_wqe_sz_sq@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	callq	_MLX5_CAP_GEN
	cmpl	%eax, %ebx
	jle	LBB0_4
## %bb.1:
	movl	(%r13), %edi
	movl	(%r12), %esi
	callq	_MLX5_CAP_GEN
	leaq	L_.str(%rip), %rsi
	xorl	%r15d, %r15d
	movq	%r13, %rdi
	movl	%ebx, %edx
	movl	%eax, %ecx
	jmp	LBB0_2
LBB0_4:
	movl	(%r14), %edi
	testl	%edi, %edi
	je	LBB0_5
## %bb.8:
	callq	_is_power_of_2
	movl	(%r14), %r14d
	testl	%eax, %eax
	jne	LBB0_6
## %bb.9:
	leaq	L_.str.1(%rip), %rsi
	xorl	%r15d, %r15d
	movq	%r13, %rdi
	movl	%r14d, %edx
	xorl	%eax, %eax
	callq	_mlx5_ib_warn
	jmp	LBB0_3
LBB0_5:
	xorl	%r14d, %r14d
LBB0_6:
	movl	%r14d, 8(%r15)
	movl	(%r13), %edi
	movq	_log_max_qp_sz@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	callq	_MLX5_CAP_GEN
	movl	$1, %ebx
	movl	$1, %edx
	movl	%eax, %ecx
	shll	%cl, %edx
	cmpl	%edx, %r14d
	jle	LBB0_10
## %bb.7:
	movl	8(%r15), %r14d
	movl	(%r13), %edi
	movl	(%r12), %esi
	callq	_MLX5_CAP_GEN
	movl	%eax, %ecx
	shll	%cl, %ebx
	leaq	L_.str.2(%rip), %rsi
	xorl	%r15d, %r15d
	movq	%r13, %rdi
	movl	%r14d, %edx
	movl	%ebx, %ecx
LBB0_2:
	xorl	%eax, %eax
	callq	_mlx5_ib_warn
LBB0_3:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	subl	(%rax), %r15d
LBB0_15:
	movl	%r15d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_10:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movq	_IB_QPT_RAW_PACKET@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_12
## %bb.11:
	movq	_MLX5_IB_QP_UNDERLAY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r15)
	je	LBB0_13
LBB0_12:
	movl	12(%r15), %eax
	movb	16(%r15), %cl
	shll	%cl, %eax
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movl	%eax, (%rcx)
	movl	8(%r15), %eax
	shll	$6, %eax
	movl	%eax, 20(%r15)
	jmp	LBB0_14
LBB0_13:
	movl	8(%r15), %eax
	movl	12(%r15), %edx
	movb	16(%r15), %cl
	shll	%cl, %edx
	shll	$6, %eax
	addl	%edx, %eax
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movl	%eax, (%rcx)
LBB0_14:
	xorl	%r15d, %r15d
	jmp	LBB0_15
	.cfi_endproc
                                        ## -- End function
	.comm	_max_wqe_sz_sq,4,2              ## @max_wqe_sz_sq
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"desc_sz %d, max_sq_desc_sz %d\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.1:                               ## @.str.1
	.asciz	"sq_wqe_count %d is not a power of two\n"

	.comm	_log_max_qp_sz,4,2              ## @log_max_qp_sz
L_.str.2:                               ## @.str.2
	.asciz	"wqe_cnt %d, max_wqes %d\n"

	.comm	_IB_QPT_RAW_PACKET,8,3          ## @IB_QPT_RAW_PACKET
	.comm	_MLX5_IB_QP_UNDERLAY,4,2        ## @MLX5_IB_QP_UNDERLAY
	.no_dead_strip	_set_user_buf_size
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function set_user_buf_size
_set_user_buf_size:                     ; @set_user_buf_size
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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, x4
	mov	x20, x3
	mov	x24, x2
	mov	x21, x1
	mov	x19, x0
	ldr	w8, [x1, #4]
	mov	w9, #1
	lsl	w23, w9, w8
	ldr	w0, [x0]
Lloh0:
	adrp	x25, _max_wqe_sz_sq@GOTPAGE
Lloh1:
	ldr	x25, [x25, _max_wqe_sz_sq@GOTPAGEOFF]
	ldr	w1, [x25]
	bl	_MLX5_CAP_GEN
	cmp	w23, w0
	b.le	LBB0_3
; %bb.1:
	ldr	w0, [x19]
	ldr	w1, [x25]
	bl	_MLX5_CAP_GEN
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh2:
	adrp	x1, l_.str@PAGE
Lloh3:
	add	x1, x1, l_.str@PAGEOFF
LBB0_2:
	mov	x0, x19
	mov	x2, x23
	b	LBB0_9
LBB0_3:
	ldr	w0, [x24]
	cbz	w0, LBB0_6
; %bb.4:
	bl	_is_power_of_2
	ldr	w23, [x24]
	cbnz	w0, LBB0_7
; %bb.5:
Lloh4:
	adrp	x1, l_.str.1@PAGE
Lloh5:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_2
LBB0_6:
	mov	w23, #0
LBB0_7:
	str	w23, [x21, #8]
	ldr	w0, [x19]
Lloh6:
	adrp	x24, _log_max_qp_sz@GOTPAGE
Lloh7:
	ldr	x24, [x24, _log_max_qp_sz@GOTPAGEOFF]
	ldr	w1, [x24]
	bl	_MLX5_CAP_GEN
	mov	w25, #1
	lsl	w8, w25, w0
	cmp	w23, w8
	b.le	LBB0_11
; %bb.8:
	ldr	w20, [x21, #8]
	ldr	w0, [x19]
	ldr	w1, [x24]
	bl	_MLX5_CAP_GEN
	lsl	w8, w25, w0
	str	x8, [sp]
Lloh8:
	adrp	x1, l_.str.2@PAGE
Lloh9:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x19
	mov	x2, x20
LBB0_9:
	bl	_mlx5_ib_warn
Lloh10:
	adrp	x8, _EINVAL@GOTPAGE
Lloh11:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_10:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_11:
	ldr	x8, [x22]
Lloh13:
	adrp	x9, _IB_QPT_RAW_PACKET@GOTPAGE
Lloh14:
	ldr	x9, [x9, _IB_QPT_RAW_PACKET@GOTPAGEOFF]
Lloh15:
	ldr	x9, [x9]
	cmp	x8, x9
	b.eq	LBB0_13
; %bb.12:
	ldr	w8, [x21]
Lloh16:
	adrp	x9, _MLX5_IB_QP_UNDERLAY@GOTPAGE
Lloh17:
	ldr	x9, [x9, _MLX5_IB_QP_UNDERLAY@GOTPAGEOFF]
Lloh18:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_14
LBB0_13:
	mov	w0, #0
	ldp	w9, w8, [x21, #12]
	ldr	w10, [x21, #8]
	lsl	w8, w9, w8
	str	w8, [x20]
	lsl	w8, w10, #6
	str	w8, [x21, #20]
	b	LBB0_10
LBB0_14:
	mov	w0, #0
	ldp	w9, w8, [x21, #12]
	ldr	w10, [x21, #8]
	lsl	w8, w9, w8
	add	w8, w8, w10, lsl #6
	str	w8, [x20]
	b	LBB0_10
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_max_wqe_sz_sq,4,2              ; @max_wqe_sz_sq
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"desc_sz %d, max_sq_desc_sz %d\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.1:                               ; @.str.1
	.asciz	"sq_wqe_count %d is not a power of two\n"

	.comm	_log_max_qp_sz,4,2              ; @log_max_qp_sz
l_.str.2:                               ; @.str.2
	.asciz	"wqe_cnt %d, max_wqes %d\n"

	.comm	_IB_QPT_RAW_PACKET,8,3          ; @IB_QPT_RAW_PACKET
	.comm	_MLX5_IB_QP_UNDERLAY,4,2        ; @MLX5_IB_QP_UNDERLAY
	.no_dead_strip	_set_user_buf_size
.subsections_via_symbols
