	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function Write
_Write:                                 ## @Write
	.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
	subq	$32, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r12
	movl	%esi, %r14d
	movl	%edi, %r15d
	movl	%edi, -40(%rbp)
	movq	%rdx, -48(%rbp)
	xorl	%eax, %eax
	callq	_NtCurrentProcess
	movq	_PAGE_EXECUTE_READWRITE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	leaq	-40(%rbp), %rsi
	leaq	-48(%rbp), %rdx
	leaq	-36(%rbp), %r8
	movl	%eax, %edi
	callq	_NtProtectVirtualMemory
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_NT_SUCCESS
	testq	%rax, %rax
	je	LBB0_4
## %bb.1:
	xorl	%eax, %eax
	callq	_NtCurrentProcess
	leaq	-56(%rbp), %r8
	movl	%eax, %edi
	movl	%r15d, %esi
	movl	%r14d, %edx
	movq	%r12, %rcx
	callq	_NtWriteVirtualMemory
	movl	%eax, %r14d
	movl	%eax, %edi
	callq	_NT_SUCCESS
	movl	%r14d, %ebx
	cmpq	%r12, -56(%rbp)
	je	LBB0_3
## %bb.2:
	movq	_STATUS_MEMORY_NOT_ALLOCATED@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ebx
LBB0_3:
	testq	%rax, %rax
	cmovel	%r14d, %ebx
	xorl	%eax, %eax
	callq	_NtCurrentProcess
	movl	-36(%rbp), %ecx
	leaq	-40(%rbp), %rsi
	leaq	-48(%rbp), %rdx
	leaq	-36(%rbp), %r8
	movl	%eax, %edi
	callq	_NtProtectVirtualMemory
LBB0_4:
	movl	%ebx, %edi
	callq	_NT_SUCCESS
	addq	$32, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PAGE_EXECUTE_READWRITE,4,2     ## @PAGE_EXECUTE_READWRITE
	.comm	_STATUS_MEMORY_NOT_ALLOCATED,4,2 ## @STATUS_MEMORY_NOT_ALLOCATED
	.no_dead_strip	_Write
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function Write
_Write:                                 ; @Write
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	mov	x19, x2
	mov	x20, x1
	mov	x21, x0
	str	w0, [sp, #28]
	str	x2, [sp, #16]
	bl	_NtCurrentProcess
Lloh0:
	adrp	x8, _PAGE_EXECUTE_READWRITE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PAGE_EXECUTE_READWRITE@GOTPAGEOFF]
Lloh2:
	ldr	w3, [x8]
	add	x1, sp, #28
	add	x2, sp, #16
	add	x4, sp, #12
	bl	_NtProtectVirtualMemory
	mov	x22, x0
	bl	_NT_SUCCESS
	cbz	x0, LBB0_2
; %bb.1:
	bl	_NtCurrentProcess
	mov	x4, sp
	mov	x1, x21
	mov	x2, x20
	mov	x3, x19
	bl	_NtWriteVirtualMemory
	mov	x20, x0
	bl	_NT_SUCCESS
	ldr	x8, [sp]
	cmp	x8, x19
	ccmp	x0, #0, #4, ne
Lloh3:
	adrp	x8, _STATUS_MEMORY_NOT_ALLOCATED@GOTPAGE
Lloh4:
	ldr	x8, [x8, _STATUS_MEMORY_NOT_ALLOCATED@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	csel	w22, w20, w8, eq
	bl	_NtCurrentProcess
	ldr	w3, [sp, #12]
	add	x1, sp, #28
	add	x2, sp, #16
	add	x4, sp, #12
	bl	_NtProtectVirtualMemory
LBB0_2:
	mov	x0, x22
	bl	_NT_SUCCESS
	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
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_PAGE_EXECUTE_READWRITE,4,2     ; @PAGE_EXECUTE_READWRITE
	.comm	_STATUS_MEMORY_NOT_ALLOCATED,4,2 ; @STATUS_MEMORY_NOT_ALLOCATED
	.no_dead_strip	_Write
.subsections_via_symbols
