	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function genwqe_unpin_mem
_genwqe_unpin_mem:                      ## @genwqe_unpin_mem
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movslq	(%rsi), %rax
	testq	%rax, %rax
	je	LBB0_1
## %bb.3:
	movq	%rdi, %r14
	movq	(%rdi), %r15
	movq	_PAGE_MASK@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdi
	movq	%rdi, %rbx
	andq	%rax, %rbx
	notq	%rdi
	andq	%rax, %rdi
	addq	8(%rsi), %rdi
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_round_up
	xorl	%r12d, %r12d
	movq	%r14, %rdi
	movq	%rbx, %rsi
	movq	%rax, %rdx
	xorl	%ecx, %ecx
	callq	_genwqe_search_pin
	testq	%rax, %rax
	je	LBB0_4
## %bb.5:
	movq	%rax, %rbx
	movq	%r14, %rdi
	movq	%rax, %rsi
	callq	_genwqe_del_pin
	movq	%r15, %rdi
	movq	%rbx, %rsi
	callq	_genwqe_user_vunmap
	movq	%rbx, %rdi
	callq	_kfree
	jmp	LBB0_6
LBB0_1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_2
LBB0_4:
	movq	_ENOENT@GOTPCREL(%rip), %rax
LBB0_2:
	xorl	%r12d, %r12d
	subl	(%rax), %r12d
LBB0_6:
	movl	%r12d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_PAGE_MASK,8,3                  ## @PAGE_MASK
	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.comm	_ENOENT,4,2                     ## @ENOENT
	.no_dead_strip	_genwqe_unpin_mem
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function genwqe_unpin_mem
_genwqe_unpin_mem:                      ; @genwqe_unpin_mem
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	ldrsw	x8, [x1]
	cbz	w8, LBB0_3
; %bb.1:
	mov	x19, x0
	ldr	x20, [x0]
Lloh0:
	adrp	x9, _PAGE_MASK@GOTPAGE
Lloh1:
	ldr	x9, [x9, _PAGE_MASK@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	and	x21, x9, x8
	ldr	x10, [x1, #8]
	bic	x8, x8, x9
	add	x0, x10, x8
Lloh3:
	adrp	x8, _PAGE_SIZE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _PAGE_SIZE@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	bl	_round_up
	mov	x2, x0
	mov	x0, x19
	mov	x1, x21
	mov	x3, #0
	bl	_genwqe_search_pin
	cbz	x0, LBB0_4
; %bb.2:
	mov	x21, x0
	mov	x0, x19
	mov	x1, x21
	bl	_genwqe_del_pin
	mov	x0, x20
	mov	x1, x21
	bl	_genwqe_user_vunmap
	mov	x0, x21
	bl	_kfree
	mov	w0, #0
	b	LBB0_6
LBB0_3:
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_5
LBB0_4:
Lloh8:
	adrp	x8, _ENOENT@GOTPAGE
Lloh9:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
LBB0_5:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_6:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_PAGE_MASK,8,3                  ; @PAGE_MASK
	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.comm	_ENOENT,4,2                     ; @ENOENT
	.no_dead_strip	_genwqe_unpin_mem
.subsections_via_symbols
