	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_context_obtain_alloc           ## -- Begin function context_obtain_alloc
	.p2align	4, 0x90
_context_obtain_alloc:                  ## @context_obtain_alloc
	.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	%esi, %r12d
	movq	%rdi, %r14
	testl	%esi, %esi
	je	LBB0_2
## %bb.1:
	leaq	8(%r14), %rdi
	callq	_lock_basic_lock
LBB0_2:
	movq	16(%r14), %rbx
	testq	%rbx, %rbx
	je	LBB0_4
## %bb.3:
	movq	(%rbx), %rax
	movq	%rax, 16(%r14)
	xorl	%r15d, %r15d
	testl	%r12d, %r12d
	je	LBB0_7
LBB0_6:
	leaq	8(%r14), %rdi
	callq	_lock_basic_unlock
LBB0_7:
	testq	%rbx, %rbx
	je	LBB0_9
## %bb.8:
	movq	%r14, (%rbx)
	jmp	LBB0_12
LBB0_4:
	movl	12(%r14), %r15d
	leal	1(%r15), %eax
	movl	%eax, 12(%r14)
	testl	%r12d, %r12d
	jne	LBB0_6
	jmp	LBB0_7
LBB0_9:
	movl	$1, %edi
	movl	$8, %esi
	callq	_calloc
	testq	%rax, %rax
	je	LBB0_10
## %bb.11:
	movq	%rax, %rbx
	movq	%rax, %rdi
	movq	%r14, %rsi
	movl	%r15d, %edx
	callq	_alloc_init
	jmp	LBB0_12
LBB0_10:
	xorl	%ebx, %ebx
LBB0_12:
	movq	%rbx, %rax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_context_obtain_alloc           ; -- Begin function context_obtain_alloc
	.p2align	2
_context_obtain_alloc:                  ; @context_obtain_alloc
	.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	x22, x1
	mov	x19, x0
	cbz	w1, LBB0_2
; %bb.1:
	add	x0, x19, #8
	bl	_lock_basic_lock
LBB0_2:
	ldr	x20, [x19, #16]
	cbz	x20, LBB0_7
; %bb.3:
	mov	w21, #0
	ldr	x8, [x20]
	str	x8, [x19, #16]
	cbz	w22, LBB0_5
LBB0_4:
	add	x0, x19, #8
	bl	_lock_basic_unlock
LBB0_5:
	cbz	x20, LBB0_8
; %bb.6:
	str	x19, [x20]
	b	LBB0_10
LBB0_7:
	ldr	w21, [x19, #12]
	add	w8, w21, #1
	str	w8, [x19, #12]
	cbnz	w22, LBB0_4
	b	LBB0_5
LBB0_8:
	mov	w0, #1
	mov	w1, #8
	bl	_calloc
	mov	x20, x0
	cbz	x0, LBB0_10
; %bb.9:
	mov	x0, x20
	mov	x1, x19
	mov	x2, x21
	bl	_alloc_init
LBB0_10:
	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
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
