	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mapBuffer                      ## -- Begin function mapBuffer
	.p2align	4, 0x90
_mapBuffer:                             ## @mapBuffer
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movl	%esi, %r8d
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movq	_pagesize@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	addl	%esi, %esi
	movq	_PROT_READ@GOTPCREL(%rip), %rax
	movq	_PROT_WRITE@GOTPCREL(%rip), %r14
	movl	(%r14), %edx
	orl	(%rax), %edx
	movq	_MAP_SHARED@GOTPCREL(%rip), %r12
	movl	(%r12), %ecx
	xorl	%edi, %edi
	xorl	%r9d, %r9d
	callq	_mmap
	movq	_MAP_FAILED@GOTPCREL(%rip), %r15
	cmpq	(%r15), %rax
	je	LBB0_1
## %bb.3:
	movq	%rax, %rbx
	movslq	(%r13), %rsi
	movq	%rsi, %rdi
	addq	%rax, %rdi
	movl	(%r14), %edx
	movq	_PROT_READ@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	movq	_MAP_FIXED@GOTPCREL(%rip), %rax
	movl	(%r12), %ecx
	orl	(%rax), %ecx
	xorl	%r12d, %r12d
                                        ## kill: def $esi killed $esi killed $rsi
	movl	-44(%rbp), %r8d                 ## 4-byte Reload
	xorl	%r9d, %r9d
	callq	_mmap
	cmpq	(%r15), %rax
	je	LBB0_4
## %bb.5:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	%rbx, (%rax)
LBB0_6:
	movl	%r12d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	leaq	L_.str(%rip), %rdi
	jmp	LBB0_2
LBB0_4:
	leaq	L_.str.1(%rip), %rdi
LBB0_2:
	callq	_perror
	movl	$1, %r12d
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.comm	_pagesize,4,2                   ## @pagesize
	.comm	_PROT_READ,4,2                  ## @PROT_READ
	.comm	_PROT_WRITE,4,2                 ## @PROT_WRITE
	.comm	_MAP_SHARED,4,2                 ## @MAP_SHARED
	.comm	_MAP_FAILED,8,3                 ## @MAP_FAILED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Mmap failed"

	.comm	_MAP_FIXED,4,2                  ## @MAP_FIXED
L_.str.1:                               ## @.str.1
	.asciz	"Mmap2 failed"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mapBuffer                      ; -- Begin function mapBuffer
	.p2align	2
_mapBuffer:                             ; @mapBuffer
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x2
	mov	x4, x1
	mov	x19, x0
Lloh0:
	adrp	x22, _pagesize@GOTPAGE
Lloh1:
	ldr	x22, [x22, _pagesize@GOTPAGEOFF]
	ldr	w8, [x22]
	lsl	w1, w8, #1
Lloh2:
	adrp	x23, _PROT_READ@GOTPAGE
Lloh3:
	ldr	x23, [x23, _PROT_READ@GOTPAGEOFF]
Lloh4:
	adrp	x25, _PROT_WRITE@GOTPAGE
Lloh5:
	ldr	x25, [x25, _PROT_WRITE@GOTPAGEOFF]
	ldr	w8, [x23]
	ldr	w9, [x25]
	orr	w2, w9, w8
Lloh6:
	adrp	x24, _MAP_SHARED@GOTPAGE
Lloh7:
	ldr	x24, [x24, _MAP_SHARED@GOTPAGEOFF]
	ldr	w3, [x24]
	mov	x0, #0
	mov	w5, #0
	bl	_mmap
Lloh8:
	adrp	x26, _MAP_FAILED@GOTPAGE
Lloh9:
	ldr	x26, [x26, _MAP_FAILED@GOTPAGEOFF]
	ldr	x8, [x26]
	cmp	x0, x8
	b.eq	LBB0_4
; %bb.1:
	mov	x21, x0
	ldrsw	x1, [x22]
	add	x0, x0, x1
	ldr	w8, [x23]
	ldr	w9, [x25]
	orr	w2, w9, w8
Lloh10:
	adrp	x8, _MAP_FIXED@GOTPAGE
Lloh11:
	ldr	x8, [x8, _MAP_FIXED@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	ldr	w9, [x24]
	orr	w3, w9, w8
                                        ; kill: def $w1 killed $w1 killed $x1
	mov	x4, x20
	mov	w5, #0
	bl	_mmap
	ldr	x8, [x26]
	cmp	x0, x8
	b.eq	LBB0_5
; %bb.2:
	mov	w0, #0
	str	x21, [x19]
LBB0_3:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_4:
Lloh13:
	adrp	x0, l_.str@PAGE
Lloh14:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_6
LBB0_5:
Lloh15:
	adrp	x0, l_.str.1@PAGE
Lloh16:
	add	x0, x0, l_.str.1@PAGEOFF
LBB0_6:
	bl	_perror
	mov	w0, #1
	b	LBB0_3
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_pagesize,4,2                   ; @pagesize
	.comm	_PROT_READ,4,2                  ; @PROT_READ
	.comm	_PROT_WRITE,4,2                 ; @PROT_WRITE
	.comm	_MAP_SHARED,4,2                 ; @MAP_SHARED
	.comm	_MAP_FAILED,8,3                 ; @MAP_FAILED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Mmap failed"

	.comm	_MAP_FIXED,4,2                  ; @MAP_FIXED
l_.str.1:                               ; @.str.1
	.asciz	"Mmap2 failed"

.subsections_via_symbols
