	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ib_init_ah_attr_from_path      ## -- Begin function ib_init_ah_attr_from_path
	.p2align	4, 0x90
_ib_init_ah_attr_from_path:             ## @ib_init_ah_attr_from_path
	.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	%r8, %r14
	movq	%rcx, %rbx
	movq	%rdx, %r15
	movl	%esi, %r12d
	movq	%rdi, %r13
	movq	%rcx, %rdi
	xorl	%esi, %esi
	movl	$8, %edx
	callq	_memset
	movq	%r13, %rdi
	movl	%r12d, %esi
	callq	_rdma_ah_find_type
	movl	%eax, 4(%rbx)
	movl	12(%r15), %esi
	movq	%rbx, %rdi
	callq	_rdma_ah_set_sl
	movq	%rbx, %rdi
	movl	%r12d, %esi
	callq	_rdma_ah_set_port_num
	movl	8(%r15), %esi
	movq	%rbx, %rdi
	callq	_rdma_ah_set_static_rate
	movq	%r15, %rdi
	callq	_sa_path_is_roce
	testq	%rax, %rax
	je	LBB0_3
## %bb.1:
	movq	%r15, %rdi
	movq	%r14, %rsi
	callq	_roce_resolve_route_from_path
	testl	%eax, %eax
	je	LBB0_2
LBB0_10:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movq	%r15, %rdi
	callq	_sa_path_get_dlid
	movl	%eax, %edi
	callq	_be32_to_cpu
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_rdma_ah_set_dlid
	movq	%r15, %rdi
	callq	_sa_path_is_opa
	testq	%rax, %rax
	je	LBB0_6
## %bb.4:
	movq	%rbx, %rdi
	callq	_rdma_ah_get_dlid
	movq	%rax, %r14
	movq	_IB_LID_PERMISSIVE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_be16_to_cpu
	cmpq	%rax, %r14
	jne	LBB0_6
## %bb.5:
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_rdma_ah_set_make_grd
LBB0_6:
	movq	%r15, %rdi
	callq	_sa_path_get_slid
	movl	%eax, %edi
	callq	_be32_to_cpu
	movl	%eax, %r14d
	movq	%r13, %rdi
	movl	%r12d, %esi
	callq	_get_src_path_mask
	andl	%eax, %r14d
	movq	%rbx, %rdi
	movl	%r14d, %esi
	callq	_rdma_ah_set_path_bits
	jmp	LBB0_7
LBB0_2:
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	movl	(%rbx), %r14d
	movq	%r15, %rdi
	callq	_sa_path_get_dmac
	movq	_ETH_ALEN@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%r14d, %edi
	movl	%eax, %esi
	callq	_memcpy
LBB0_7:
	cmpq	$0, (%r15)
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	jg	LBB0_11
## %bb.8:
	movq	%r15, %rdi
	callq	_sa_path_is_roce
	testq	%rax, %rax
	je	LBB0_9
LBB0_11:
	movq	%r13, %rdi
	movl	%r12d, %esi
	movq	%r15, %rdx
	movq	%rbx, %rcx
	movq	%r14, %r8
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_init_ah_attr_grh_fields        ## TAILCALL
LBB0_9:
	xorl	%eax, %eax
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_ETH_ALEN,4,2                   ## @ETH_ALEN
	.comm	_IB_LID_PERMISSIVE,4,2          ## @IB_LID_PERMISSIVE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ib_init_ah_attr_from_path      ; -- Begin function ib_init_ah_attr_from_path
	.p2align	2
_ib_init_ah_attr_from_path:             ; @ib_init_ah_attr_from_path
	.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, x4
	mov	x20, x3
	mov	x21, x2
	mov	x22, x1
	mov	x23, x0
	mov	x0, x3
	mov	w1, #0
	mov	w2, #8
	bl	_memset
	mov	x0, x23
	mov	x1, x22
	bl	_rdma_ah_find_type
	str	w0, [x20, #4]
	ldr	w1, [x21, #12]
	mov	x0, x20
	bl	_rdma_ah_set_sl
	mov	x0, x20
	mov	x1, x22
	bl	_rdma_ah_set_port_num
	ldr	w1, [x21, #8]
	mov	x0, x20
	bl	_rdma_ah_set_static_rate
	mov	x0, x21
	bl	_sa_path_is_roce
	cbz	x0, LBB0_3
; %bb.1:
	mov	x0, x21
	mov	x1, x19
	bl	_roce_resolve_route_from_path
	cbz	w0, LBB0_7
LBB0_2:
	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_3:
	mov	x0, x21
	bl	_sa_path_get_dlid
	bl	_be32_to_cpu
	mov	x1, x0
	mov	x0, x20
	bl	_rdma_ah_set_dlid
	mov	x0, x21
	bl	_sa_path_is_opa
	cbz	x0, LBB0_6
; %bb.4:
	mov	x0, x20
	bl	_rdma_ah_get_dlid
	mov	x24, x0
Lloh0:
	adrp	x8, _IB_LID_PERMISSIVE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _IB_LID_PERMISSIVE@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_be16_to_cpu
	cmp	x24, x0
	b.ne	LBB0_6
; %bb.5:
	mov	x0, x20
	mov	w1, #1
	bl	_rdma_ah_set_make_grd
LBB0_6:
	mov	x0, x21
	bl	_sa_path_get_slid
	bl	_be32_to_cpu
	mov	x24, x0
	mov	x0, x23
	mov	x1, x22
	bl	_get_src_path_mask
	and	w1, w0, w24
	mov	x0, x20
	bl	_rdma_ah_set_path_bits
	b	LBB0_8
LBB0_7:
	ldr	w24, [x20]
	mov	x0, x21
	bl	_sa_path_get_dmac
	mov	x1, x0
Lloh3:
	adrp	x8, _ETH_ALEN@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ETH_ALEN@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x0, x24
	bl	_memcpy
LBB0_8:
	ldr	x8, [x21]
	cmp	x8, #0
	b.gt	LBB0_10
; %bb.9:
	mov	x0, x21
	bl	_sa_path_is_roce
	cbz	x0, LBB0_2
LBB0_10:
	mov	x0, x23
	mov	x1, x22
	mov	x2, x21
	mov	x3, x20
	mov	x4, x19
	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
	b	_init_ah_attr_grh_fields
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_ETH_ALEN,4,2                   ; @ETH_ALEN
	.comm	_IB_LID_PERMISSIVE,4,2          ; @IB_LID_PERMISSIVE
.subsections_via_symbols
