	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_qib_do_send                    ## -- Begin function qib_do_send
	.p2align	4, 0x90
_qib_do_send:                           ## @qib_do_send
	.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	%rdi, %rbx
	movq	48(%rdi), %r15
	movl	32(%rdi), %edi
	movl	44(%rbx), %esi
	callq	_to_iport
	movq	%rax, %rdi
	callq	_ppd_from_ibp
	movq	%rax, %r14
	movq	24(%rbx), %rax
	movq	_IB_QPT_RC@GOTPCREL(%rip), %r12
	movq	(%r12), %rcx
	movq	_IB_QPT_UC@GOTPCREL(%rip), %r13
	cmpq	%rcx, %rax
	je	LBB0_2
## %bb.1:
	movq	(%r13), %rdx
	cmpq	%rdx, %rax
	je	LBB0_2
## %bb.4:
	cmpq	%rdx, %rax
	jne	LBB0_5
LBB0_6:
	movq	_qib_make_uc_req@GOTPCREL(%rip), %r12
	cmpq	%rcx, %rax
	je	LBB0_8
	jmp	LBB0_9
LBB0_2:
	leaq	40(%rbx), %rdi
	callq	_rdma_ah_get_dlid
	movb	(%r14), %cl
	shrl	%cl, %eax
	shll	%cl, %eax
	cmpl	4(%r14), %eax
	jne	LBB0_3
## %bb.17:
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_rvt_ruc_loopback               ## TAILCALL
LBB0_3:
	movq	24(%rbx), %rax
	movq	(%r12), %rcx
	movq	(%r13), %rdx
	cmpq	%rdx, %rax
	je	LBB0_6
LBB0_5:
	movq	_qib_make_ud_req@GOTPCREL(%rip), %r12
	cmpq	%rcx, %rax
	jne	LBB0_9
LBB0_8:
	movq	_qib_make_rc_req@GOTPCREL(%rip), %r12
LBB0_9:
	movq	%rbx, %rdi
	callq	_spin_lock_irqsave
	movq	%rbx, %rdi
	callq	_qib_send_ok
	testl	%eax, %eax
	je	LBB0_18
## %bb.10:
	movq	_RVT_S_BUSY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, 16(%rbx)
	leaq	-48(%rbp), %r14
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_11 Depth=1
	movl	$0, 4(%rbx)
	movq	-48(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_spin_lock_irqsave
LBB0_14:                                ##   in Loop: Header=BB0_11 Depth=1
	movq	%rbx, %rdi
	movq	%r14, %rsi
	callq	*%r12
	testl	%eax, %eax
	je	LBB0_15
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	cmpl	$0, 4(%rbx)
	je	LBB0_14
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	-48(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_spin_unlock_irqrestore
	movl	(%r15), %esi
	movl	12(%rbx), %ecx
	movl	4(%rbx), %edx
	movl	8(%rbx), %r8d
	movq	%rbx, %rdi
	callq	_qib_verbs_send
	testq	%rax, %rax
	je	LBB0_13
	jmp	LBB0_16
LBB0_15:
	movq	-48(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_spin_unlock_irqrestore
LBB0_16:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_18:
	movq	%rbx, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_spin_unlock_irqrestore         ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_IB_QPT_RC,8,3                  ## @IB_QPT_RC
	.comm	_IB_QPT_UC,8,3                  ## @IB_QPT_UC
	.comm	_RVT_S_BUSY,4,2                 ## @RVT_S_BUSY
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_qib_do_send                    ; -- Begin function qib_do_send
	.p2align	2
_qib_do_send:                           ; @qib_do_send
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.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
	mov	x19, x0
	ldr	x21, [x0, #48]
	ldr	w0, [x0, #32]
	ldr	w1, [x19, #44]
	bl	_to_iport
	bl	_ppd_from_ibp
	ldr	x8, [x19, #24]
Lloh0:
	adrp	x22, _IB_QPT_RC@GOTPAGE
Lloh1:
	ldr	x22, [x22, _IB_QPT_RC@GOTPAGEOFF]
	ldr	x9, [x22]
Lloh2:
	adrp	x23, _IB_QPT_UC@GOTPAGE
Lloh3:
	ldr	x23, [x23, _IB_QPT_UC@GOTPAGEOFF]
	ldr	x10, [x23]
	cmp	x8, x9
	ccmp	x8, x10, #4, ne
	b.ne	LBB0_4
; %bb.1:
	mov	x20, x0
	add	x0, x19, #40
	bl	_rdma_ah_get_dlid
	mov	w8, #-1
	ldp	w9, w10, [x20]
	lsl	w8, w8, w9
	and	w8, w8, w0
	cmp	w8, w10
	b.ne	LBB0_3
; %bb.2:
	mov	x0, x19
	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
	add	sp, sp, #80
	b	_rvt_ruc_loopback
LBB0_3:
	ldr	x8, [x19, #24]
	ldr	x9, [x22]
	ldr	x10, [x23]
LBB0_4:
Lloh4:
	adrp	x11, _qib_make_ud_req@GOTPAGE
Lloh5:
	ldr	x11, [x11, _qib_make_ud_req@GOTPAGEOFF]
Lloh6:
	adrp	x12, _qib_make_uc_req@GOTPAGE
Lloh7:
	ldr	x12, [x12, _qib_make_uc_req@GOTPAGEOFF]
	cmp	x8, x10
	csel	x10, x12, x11, eq
Lloh8:
	adrp	x11, _qib_make_rc_req@GOTPAGE
Lloh9:
	ldr	x11, [x11, _qib_make_rc_req@GOTPAGEOFF]
	cmp	x8, x9
	csel	x20, x11, x10, eq
	mov	x0, x19
	bl	_spin_lock_irqsave
	mov	x0, x19
	bl	_qib_send_ok
	cbz	w0, LBB0_10
; %bb.5:
Lloh10:
	adrp	x8, _RVT_S_BUSY@GOTPAGE
Lloh11:
	ldr	x8, [x8, _RVT_S_BUSY@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	ldr	w9, [x19, #16]
	orr	w8, w9, w8
	str	w8, [x19, #16]
	b	LBB0_8
LBB0_6:                                 ;   in Loop: Header=BB0_8 Depth=1
	str	wzr, [x19, #4]
	ldr	x1, [sp, #8]
	mov	x0, x19
	bl	_spin_lock_irqsave
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=1
	add	x1, sp, #8
	mov	x0, x19
	blr	x20
	cbz	w0, LBB0_11
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x19, #4]
	cbz	w8, LBB0_7
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	ldr	x1, [sp, #8]
	mov	x0, x19
	bl	_spin_unlock_irqrestore
	ldr	w1, [x21]
	ldp	w4, w3, [x19, #8]
	ldr	w2, [x19, #4]
	mov	x0, x19
	bl	_qib_verbs_send
	cbz	x0, LBB0_6
	b	LBB0_12
LBB0_10:
	mov	x0, x19
	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
	add	sp, sp, #80
	b	_spin_unlock_irqrestore
LBB0_11:
	ldr	x1, [sp, #8]
	mov	x0, x19
	bl	_spin_unlock_irqrestore
LBB0_12:
	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
	add	sp, sp, #80
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_IB_QPT_RC,8,3                  ; @IB_QPT_RC
	.comm	_IB_QPT_UC,8,3                  ; @IB_QPT_UC
	.comm	_RVT_S_BUSY,4,2                 ; @RVT_S_BUSY
.subsections_via_symbols
