	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_unmapmem                       ## -- Begin function unmapmem
	.p2align	4, 0x90
_unmapmem:                              ## @unmapmem
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	%rdi, %rax
	orq	%rcx, %rax
	shrq	$32, %rax
	je	LBB0_1
## %bb.2:
	movq	%rdi, %rax
	cqto
	idivq	%rcx
	jmp	LBB0_3
LBB0_1:
	movl	%edi, %eax
	xorl	%edx, %edx
	divl	%ecx
                                        ## kill: def $edx killed $edx def $rdx
LBB0_3:
	subq	%rdx, %rdi
	addl	%esi, %edx
	movl	%edx, %esi
	callq	_munmap
	testl	%eax, %eax
	jne	LBB0_5
## %bb.4:
	popq	%rbp
	retq
LBB0_5:
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
	callq	_printf
	movl	$-1, %edi
	callq	_exit
	.cfi_endproc
                                        ## -- End function
	.comm	_PAGE_SIZE,8,3                  ## @PAGE_SIZE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"munmap error %d\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_unmapmem                       ; -- Begin function unmapmem
	.p2align	2
_unmapmem:                              ; @unmapmem
	.cfi_startproc
; %bb.0:
	stp	x29, x30, [sp, #-16]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 16
	mov	x29, sp
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
Lloh0:
	adrp	x8, _PAGE_SIZE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PAGE_SIZE@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	sdiv	x9, x0, x8
	mul	x8, x9, x8
	sub	x9, x0, x8
	add	w1, w9, w1
	mov	x0, x8
	bl	_munmap
	cbnz	w0, LBB0_2
; %bb.1:
	ldp	x29, x30, [sp], #16             ; 16-byte Folded Reload
	ret
LBB0_2:
	mov	x1, x0
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_printf
	mov	w0, #-1
	bl	_exit
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_PAGE_SIZE,8,3                  ; @PAGE_SIZE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"munmap error %d\n"

.subsections_via_symbols
