	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ibv_init_ah_from_wc            ## -- Begin function ibv_init_ah_from_wc
	.p2align	4, 0x90
_ibv_init_ah_from_wc:                   ## @ibv_init_ah_from_wc
	.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, %rbx
	movq	%rcx, %r15
	movq	%rdx, %r12
	movl	%esi, %r14d
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	xorl	%r13d, %r13d
	movq	%r8, %rdi
	xorl	%esi, %esi
	movl	$4, %edx
	callq	_memset
	movq	%rbx, %rdi
	movq	%r12, %rsi
	movq	%r15, %rdx
	movl	%r14d, %ecx
	callq	_set_ah_attr_generic_fields
	movq	_IBV_WC_GRH@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r12)
	je	LBB0_5
## %bb.1:
	movl	$1, (%rbx)
	movq	%r15, %rdi
	callq	_get_grh_header_version
	cmpl	$6, %eax
	je	LBB0_4
## %bb.2:
	movl	$-1, %r13d
	cmpl	$4, %eax
	jne	LBB0_5
## %bb.3:
	addq	$20, %r15
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	movq	%r15, %rdx
	movl	%r14d, %ecx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_set_ah_attr_by_ipv4            ## TAILCALL
LBB0_5:
	movl	%r13d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	movq	%r15, %rdx
	movl	%r14d, %ecx
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_set_ah_attr_by_ipv6            ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_IBV_WC_GRH,4,2                 ## @IBV_WC_GRH
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ibv_init_ah_from_wc            ; -- Begin function ibv_init_ah_from_wc
	.p2align	2
_ibv_init_ah_from_wc:                   ; @ibv_init_ah_from_wc
	.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	x20, x4
	mov	x21, x3
	mov	x23, x2
	mov	x19, x1
	mov	x22, x0
	mov	x0, x4
	mov	w1, #0
	mov	w2, #4
	bl	_memset
	mov	x0, x20
	mov	x1, x23
	mov	x2, x21
	mov	x3, x19
	bl	_set_ah_attr_generic_fields
	ldr	w8, [x23]
Lloh0:
	adrp	x9, _IBV_WC_GRH@GOTPAGE
Lloh1:
	ldr	x9, [x9, _IBV_WC_GRH@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_4
; %bb.1:
	mov	w8, #1
	str	w8, [x20]
	mov	x0, x21
	bl	_get_grh_header_version
	cmp	w0, #6
	b.eq	LBB0_5
; %bb.2:
	cmp	w0, #4
	b.ne	LBB0_6
; %bb.3:
	add	x2, x21, #20
	mov	x0, x22
	mov	x1, x20
	mov	x3, 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	_set_ah_attr_by_ipv4
LBB0_4:
	mov	w0, #0
	b	LBB0_7
LBB0_5:
	mov	x0, x22
	mov	x1, x20
	mov	x2, x21
	mov	x3, 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	_set_ah_attr_by_ipv6
LBB0_6:
	mov	w0, #-1
LBB0_7:
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_IBV_WC_GRH,4,2                 ; @IBV_WC_GRH
.subsections_via_symbols
