	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_create_mspace_with_base        ## -- Begin function create_mspace_with_base
	.p2align	4, 0x90
_create_mspace_with_base:               ## @create_mspace_with_base
	.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
	movl	%edx, %r14d
	movq	%rsi, %rbx
	movq	%rdi, %r12
	xorl	%r15d, %r15d
	xorl	%eax, %eax
	callq	_ensure_initialization
	movl	$4, %edi
	callq	_pad_request
	movq	_TOP_FOOT_SIZE@GOTPCREL(%rip), %rcx
	addq	(%rcx), %rax
	cmpq	%rbx, %rax
	jae	LBB0_3
## %bb.1:
	movq	_mparams@GOTPCREL(%rip), %rcx
	addq	(%rcx), %rax
	negq	%rax
	cmpq	%rbx, %rax
	jbe	LBB0_3
## %bb.2:
	movq	%r12, %rdi
	movq	%rbx, %rsi
	callq	_init_user_mstate
	movq	%rax, %r15
	movq	_EXTERN_BIT@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%r15)
	movq	%r15, %rdi
	movl	%r14d, %esi
	callq	_set_lock
LBB0_3:
	movl	%r15d, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_TOP_FOOT_SIZE,8,3              ## @TOP_FOOT_SIZE
	.comm	_mparams,8,3                    ## @mparams
	.comm	_EXTERN_BIT,4,2                 ## @EXTERN_BIT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_create_mspace_with_base        ; -- Begin function create_mspace_with_base
	.p2align	2
_create_mspace_with_base:               ; @create_mspace_with_base
	.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
	mov	x19, x2
	mov	x20, x1
	mov	x21, x0
	bl	_ensure_initialization
	mov	w0, #4
	bl	_pad_request
Lloh0:
	adrp	x8, _TOP_FOOT_SIZE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _TOP_FOOT_SIZE@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	add	x8, x8, x0
	cmp	x8, x20
	b.hs	LBB0_3
; %bb.1:
Lloh3:
	adrp	x9, _mparams@GOTPAGE
Lloh4:
	ldr	x9, [x9, _mparams@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	add	x8, x8, x9
	neg	x8, x8
	cmp	x8, x20
	b.ls	LBB0_3
; %bb.2:
	mov	x0, x21
	mov	x1, x20
	bl	_init_user_mstate
	mov	x20, x0
Lloh6:
	adrp	x8, _EXTERN_BIT@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EXTERN_BIT@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	str	w8, [x0]
	mov	x1, x19
	bl	_set_lock
	b	LBB0_4
LBB0_3:
	mov	w20, #0
LBB0_4:
	mov	x0, x20
	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	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_TOP_FOOT_SIZE,8,3              ; @TOP_FOOT_SIZE
	.comm	_mparams,8,3                    ; @mparams
	.comm	_EXTERN_BIT,4,2                 ; @EXTERN_BIT
.subsections_via_symbols
