	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function resolve_mode
_resolve_mode:                          ## @resolve_mode
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	$-1, %r14d
	cmpq	$0, 56(%rdi)
	jne	LBB0_19
## %bb.1:
	movq	%rdi, %rbx
	movl	(%rdi), %eax
	xorl	%r14d, %r14d
	cmpl	$16, %eax
	je	LBB0_16
## %bb.2:
	cmpl	$32, %eax
	je	LBB0_15
## %bb.3:
	cmpl	$64, %eax
	jne	LBB0_19
## %bb.4:
	movq	48(%rbx), %rax
	movl	(%rax), %edi
	callq	_P_INV64
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	callq	_UDERR
	movl	$-1, %r14d
	jmp	LBB0_19
LBB0_16:
	xorl	%eax, %eax
	cmpq	$0, 40(%rbx)
	setne	%al
	shll	$4, %eax
	addl	$16, %eax
	movl	%eax, 24(%rbx)
	xorl	%eax, %eax
	cmpq	$0, 32(%rbx)
	setne	%al
	jmp	LBB0_17
LBB0_15:
	xorl	%eax, %eax
	cmpq	$0, 40(%rbx)
	sete	%al
	shll	$4, %eax
	addl	$16, %eax
	movl	%eax, 24(%rbx)
	xorl	%eax, %eax
	cmpq	$0, 32(%rbx)
	sete	%al
LBB0_17:
	shll	$4, %eax
	addl	$16, %eax
LBB0_18:
	movl	%eax, 28(%rbx)
LBB0_19:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movl	4(%rbx), %eax
	cmpl	$197, %eax
	je	LBB0_9
## %bb.7:
	cmpl	$196, %eax
	jne	LBB0_10
## %bb.8:
	movl	12(%rbx), %ecx
	movl	16(%rbx), %eax
	shrl	$5, %ecx
	andl	$7, %ecx
	shrl	$4, %eax
	andl	$8, %eax
	orl	%ecx, %eax
	xorl	$7, %eax
	jmp	LBB0_11
LBB0_9:
	movl	12(%rbx), %eax
	shrl	$5, %eax
	notl	%eax
	andl	$4, %eax
	jmp	LBB0_11
LBB0_10:
	xorl	%edi, %edi
	testl	%eax, %eax
	sete	%dil
	callq	_UD_ASSERT
	movl	20(%rbx), %eax
LBB0_11:
	movl	%eax, 8(%rbx)
	movq	48(%rbx), %rax
	movl	(%rax), %edi
	callq	_REX_PFX_MASK
	andl	%eax, 8(%rbx)
	movq	48(%rbx), %rax
	movl	(%rax), %edi
	callq	_P_DEF64
	movl	%eax, %r15d
	movl	8(%rbx), %edi
	callq	_REX_W
	movl	$64, %ecx
	testq	%rax, %rax
	jne	LBB0_14
## %bb.12:
	movl	$16, %ecx
	cmpq	$0, 40(%rbx)
	jne	LBB0_14
## %bb.13:
	xorl	%ecx, %ecx
	testl	%r15d, %r15d
	setne	%cl
	shll	$5, %ecx
	addl	$32, %ecx
LBB0_14:
	movl	%ecx, 24(%rbx)
	xorl	%eax, %eax
	cmpq	$0, 32(%rbx)
	sete	%al
	shll	$5, %eax
	addl	$32, %eax
	jmp	LBB0_18
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"instruction invalid in 64bits\n"

	.no_dead_strip	_resolve_mode
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function resolve_mode
_resolve_mode:                          ; @resolve_mode
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	ldr	x8, [x0, #56]
	cbz	x8, LBB0_2
; %bb.1:
	mov	w0, #-1
	b	LBB0_19
LBB0_2:
	mov	x19, x0
	ldr	w8, [x0]
	cmp	w8, #16
	b.eq	LBB0_7
; %bb.3:
	cmp	w8, #32
	b.eq	LBB0_8
; %bb.4:
	cmp	w8, #64
	b.ne	LBB0_10
; %bb.5:
	ldr	x8, [x19, #48]
	ldr	w0, [x8]
	bl	_P_INV64
	cbz	x0, LBB0_11
; %bb.6:
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_UDERR
	mov	w0, #-1
	b	LBB0_19
LBB0_7:
	mov	w0, #0
	ldr	q0, [x19, #32]
	cmeq.2d	v0, v0, #0
	xtn.2s	v0, v0
	movi.2s	v1, #32
	movi.2s	v2, #16
	b	LBB0_9
LBB0_8:
	mov	w0, #0
	ldr	q0, [x19, #32]
	cmeq.2d	v0, v0, #0
	xtn.2s	v0, v0
	movi.2s	v1, #16
	movi.2s	v2, #32
LBB0_9:
	bsl.8b	v0, v2, v1
	rev64.2s	v0, v0
	str	d0, [x19, #24]
	b	LBB0_19
LBB0_10:
	mov	w0, #0
	b	LBB0_19
LBB0_11:
	ldr	w8, [x19, #4]
	cmp	w8, #197
	b.eq	LBB0_14
; %bb.12:
	cmp	w8, #196
	b.ne	LBB0_15
; %bb.13:
	ldp	w8, w9, [x19, #12]
	lsr	w9, w9, #4
	and	w9, w9, #0x8
	bfxil	w9, w8, #5, #3
	eor	w8, w9, #0x7
	b	LBB0_16
LBB0_14:
	ldr	w8, [x19, #12]
	mov	w9, #4
	bic	w8, w9, w8, lsr #5
	b	LBB0_16
LBB0_15:
	cmp	w8, #0
	cset	w0, eq
	bl	_UD_ASSERT
	ldr	w8, [x19, #20]
LBB0_16:
	str	w8, [x19, #8]
	ldr	x8, [x19, #48]
	ldr	w0, [x8]
	bl	_REX_PFX_MASK
	ldr	w8, [x19, #8]
	and	w8, w8, w0
	str	w8, [x19, #8]
	ldr	x8, [x19, #48]
	ldr	w0, [x8]
	bl	_P_DEF64
	mov	x20, x0
	ldr	w0, [x19, #8]
	bl	_REX_W
	mov	w8, #64
	mov	w9, #64
	cbnz	x0, LBB0_18
; %bb.17:
	ldr	x9, [x19, #40]
	mov	w10, #16
	mov	w11, #32
	cmp	w20, #0
	csel	w11, w11, w8, eq
	cmp	x9, #0
	csel	w9, w10, w11, ne
LBB0_18:
	mov	w0, #0
	ldr	x10, [x19, #32]
	cmp	x10, #0
	mov	w10, #32
	csel	w8, w8, w10, eq
	stp	w9, w8, [x19, #24]
LBB0_19:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"instruction invalid in 64bits\n"

	.no_dead_strip	_resolve_mode
.subsections_via_symbols
