	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function emulate_test
_emulate_test:                          ## @emulate_test
	.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	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	cmpl	$247, 12(%rcx)
	jne	LBB0_2
## %bb.1:
	movq	%rcx, %rbx
	testb	$7, 4(%rcx)
	je	LBB0_3
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_6:
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	%r8, %rax
	movl	%esi, %r14d
	movq	%rdi, %r12
	movq	16(%rbp), %r9
	movl	(%rbx), %r15d
	leaq	-40(%rbp), %rcx
	movl	%r15d, %r8d
	callq	*%rax
	testl	%eax, %eax
	jne	LBB0_6
## %bb.4:
	movl	-40(%rbp), %esi
	movl	8(%rbx), %edx
	movl	%r15d, %edi
	callq	_getandflags
	movl	%eax, %r15d
	movq	_VM_REG_GUEST_RFLAGS@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	leaq	-36(%rbp), %rcx
	movq	%r12, %rdi
	movl	%r14d, %esi
	callq	_vie_read_register
	testl	%eax, %eax
	jne	LBB0_6
## %bb.5:
	movq	_RFLAGS_STATUS_BITS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	-36(%rbp), %eax
	movq	_PSL_PF@GOTPCREL(%rip), %rdx
	movq	_PSL_Z@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	orl	(%rdx), %ecx
	movq	_PSL_N@GOTPCREL(%rip), %rdx
	orl	(%rdx), %ecx
	andl	%r15d, %ecx
	orl	%eax, %ecx
	movl	%ecx, -36(%rbp)
	movl	(%rbx), %edx
	movq	%r12, %rdi
	movl	%r14d, %esi
	movl	$8, %r8d
	callq	_vie_update_register
	jmp	LBB0_6
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_VM_REG_GUEST_RFLAGS,4,2        ## @VM_REG_GUEST_RFLAGS
	.comm	_RFLAGS_STATUS_BITS,4,2         ## @RFLAGS_STATUS_BITS
	.comm	_PSL_PF,4,2                     ## @PSL_PF
	.comm	_PSL_Z,4,2                      ## @PSL_Z
	.comm	_PSL_N,4,2                      ## @PSL_N
	.no_dead_strip	_emulate_test
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function emulate_test
_emulate_test:                          ; @emulate_test
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	ldr	w9, [x3, #12]
	cmp	w9, #247
	b.ne	LBB0_2
; %bb.1:
	mov	x21, x3
	ldrb	w9, [x3, #4]
	tst	w9, #0x7
	b.eq	LBB0_4
LBB0_2:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
LBB0_3:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
LBB0_4:
	mov	x8, x4
	mov	x19, x1
	mov	x20, x0
	ldr	w22, [x21]
	add	x3, sp, #12
	mov	x4, x22
	mov	x5, x6
	blr	x8
	cbnz	w0, LBB0_3
; %bb.5:
	ldr	w1, [sp, #12]
	ldr	w2, [x21, #8]
	mov	x0, x22
	bl	_getandflags
	mov	x21, x0
Lloh3:
	adrp	x22, _VM_REG_GUEST_RFLAGS@GOTPAGE
Lloh4:
	ldr	x22, [x22, _VM_REG_GUEST_RFLAGS@GOTPAGEOFF]
	ldr	w2, [x22]
	add	x3, sp, #8
	mov	x0, x20
	mov	x1, x19
	bl	_vie_read_register
	cbnz	w0, LBB0_3
; %bb.6:
Lloh5:
	adrp	x8, _RFLAGS_STATUS_BITS@GOTPAGE
Lloh6:
	ldr	x8, [x8, _RFLAGS_STATUS_BITS@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	ldr	w9, [sp, #8]
	bic	w8, w9, w8
Lloh8:
	adrp	x9, _PSL_PF@GOTPAGE
Lloh9:
	ldr	x9, [x9, _PSL_PF@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
Lloh11:
	adrp	x10, _PSL_Z@GOTPAGE
Lloh12:
	ldr	x10, [x10, _PSL_Z@GOTPAGEOFF]
Lloh13:
	ldr	w10, [x10]
	orr	w9, w10, w9
Lloh14:
	adrp	x10, _PSL_N@GOTPAGE
Lloh15:
	ldr	x10, [x10, _PSL_N@GOTPAGEOFF]
Lloh16:
	ldr	w10, [x10]
	orr	w9, w9, w10
	and	w9, w9, w21
	orr	w3, w9, w8
	str	w3, [sp, #8]
	ldr	w2, [x22]
	mov	x0, x20
	mov	x1, x19
	mov	w4, #8
	bl	_vie_update_register
	b	LBB0_3
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_VM_REG_GUEST_RFLAGS,4,2        ; @VM_REG_GUEST_RFLAGS
	.comm	_RFLAGS_STATUS_BITS,4,2         ; @RFLAGS_STATUS_BITS
	.comm	_PSL_PF,4,2                     ; @PSL_PF
	.comm	_PSL_Z,4,2                      ; @PSL_Z
	.comm	_PSL_N,4,2                      ; @PSL_N
	.no_dead_strip	_emulate_test
.subsections_via_symbols
