	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pvrdma_create_ah               ## -- Begin function pvrdma_create_ah
	.p2align	4, 0x90
_pvrdma_create_ah:                      ## @pvrdma_create_ah
	.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, %r15
	movq	%rdi, %r12
	movl	4(%rdi), %edi
	callq	_to_vdev
	movq	%rax, %r14
	movq	%r12, %rdi
	callq	_to_vah
	movq	%rax, %rbx
	movq	%r15, %rdi
	callq	_rdma_ah_get_port_num
	movl	%eax, %r13d
	movq	%r15, %rdi
	callq	_rdma_ah_get_ah_flags
	movq	_IB_AH_GRH@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_1
## %bb.3:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movq	%r15, %rdi
	callq	_rdma_ah_read_grh
	movq	%rax, %rbx
	movq	(%r15), %rax
	movq	_RDMA_AH_ATTR_TYPE_ROCE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_1
## %bb.4:
	movq	8(%rbx), %rdi
	callq	_rdma_is_multicast_addr
	testq	%rax, %rax
	je	LBB0_5
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
LBB0_2:
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_8:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movq	%r14, %rdi
	addq	$8, %rdi
	movq	(%r14), %rax
	movl	(%rax), %edx
	movl	$1, %esi
	callq	_atomic_add_unless
	testl	%eax, %eax
	je	LBB0_6
## %bb.7:
	movl	(%r12), %edi
	callq	_to_vpd
	shll	$24, %r13d
	orl	(%rax), %r13d
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movl	%r13d, (%r14)
	movq	%r15, %rdi
	callq	_rdma_ah_get_path_bits
	orl	$128, %eax
	movl	%eax, 4(%r14)
	movl	20(%rbx), %eax
	movl	%eax, 24(%r14)
	movl	16(%rbx), %eax
	movl	%eax, 20(%r14)
	movl	(%rbx), %eax
	shll	$20, %eax
	orl	4(%rbx), %eax
	movl	%eax, 8(%r14)
	movl	16(%r14), %edi
	movq	8(%rbx), %rsi
	movl	$16, %edx
	callq	_memcpy
	movl	12(%r14), %edi
	movq	8(%r15), %rsi
	movq	_ETH_ALEN@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_memcpy
	xorl	%eax, %eax
	jmp	LBB0_8
LBB0_6:
	movq	_ENOMEM@GOTPCREL(%rip), %rcx
	jmp	LBB0_2
	.cfi_endproc
                                        ## -- End function
	.comm	_IB_AH_GRH,4,2                  ## @IB_AH_GRH
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_RDMA_AH_ATTR_TYPE_ROCE,8,3     ## @RDMA_AH_ATTR_TYPE_ROCE
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_ETH_ALEN,4,2                   ## @ETH_ALEN
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_pvrdma_create_ah               ; -- Begin function pvrdma_create_ah
	.p2align	2
_pvrdma_create_ah:                      ; @pvrdma_create_ah
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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, x1
	mov	x21, x0
	ldr	w0, [x0, #4]
	bl	_to_vdev
	mov	x24, x0
	mov	x0, x21
	bl	_to_vah
	mov	x20, x0
	mov	x0, x19
	bl	_rdma_ah_get_port_num
	mov	x23, x0
	mov	x0, x19
	bl	_rdma_ah_get_ah_flags
Lloh0:
	adrp	x8, _IB_AH_GRH@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IB_AH_GRH@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_3
; %bb.1:
	mov	x0, x19
	bl	_rdma_ah_read_grh
	ldr	x8, [x19]
Lloh3:
	adrp	x9, _RDMA_AH_ATTR_TYPE_ROCE@GOTPAGE
Lloh4:
	ldr	x9, [x9, _RDMA_AH_ATTR_TYPE_ROCE@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_3
; %bb.2:
	mov	x22, x0
	ldr	x0, [x0, #8]
	bl	_rdma_is_multicast_addr
	cbz	x0, LBB0_6
LBB0_3:
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_4:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_5:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_6:
	ldr	x8, [x24], #8
	ldr	w2, [x8]
	mov	x0, x24
	mov	w1, #1
	bl	_atomic_add_unless
	cbz	w0, LBB0_8
; %bb.7:
	ldr	w0, [x21]
	bl	_to_vpd
	ldr	w8, [x0]
	orr	w8, w8, w23, lsl #24
	str	w8, [x20]
	mov	x0, x19
	bl	_rdma_ah_get_path_bits
	orr	w8, w0, #0x80
	str	w8, [x20, #4]
	ldr	d0, [x22, #16]
	stur	d0, [x20, #20]
	ldp	w8, w9, [x22]
	orr	w8, w9, w8, lsl #20
	str	w8, [x20, #8]
	ldr	w0, [x20, #16]
	ldr	x1, [x22, #8]
	mov	w2, #16
	bl	_memcpy
	ldr	w0, [x20, #12]
	ldr	x1, [x19, #8]
Lloh8:
	adrp	x8, _ETH_ALEN@GOTPAGE
Lloh9:
	ldr	x8, [x8, _ETH_ALEN@GOTPAGEOFF]
Lloh10:
	ldr	w2, [x8]
	bl	_memcpy
	mov	w0, #0
	b	LBB0_5
LBB0_8:
Lloh11:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh12:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
	b	LBB0_4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_IB_AH_GRH,4,2                  ; @IB_AH_GRH
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_RDMA_AH_ATTR_TYPE_ROCE,8,3     ; @RDMA_AH_ATTR_TYPE_ROCE
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_ETH_ALEN,4,2                   ; @ETH_ALEN
.subsections_via_symbols
