	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_kvm_load_segment_descriptor    ## -- Begin function kvm_load_segment_descriptor
	.p2align	4, 0x90
_kvm_load_segment_descriptor:           ## @kvm_load_segment_descriptor
	.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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %ebx
	movl	%esi, %r12d
	movq	%rdi, %r14
	movq	_GP_VECTOR@GOTPCREL(%rip), %r13
	movl	(%r13), %r15d
	movl	%edx, %esi
	callq	_is_vm86_segment
	testq	%rax, %rax
	je	LBB0_1
LBB0_43:
	movq	%r14, %rdi
	movl	%r12d, %esi
	movl	%ebx, %edx
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_kvm_load_realmode_segment      ## TAILCALL
LBB0_1:
	movq	_X86_CR0_PE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r14, %rdi
	callq	_kvm_read_cr0_bits
	testl	%eax, %eax
	je	LBB0_43
## %bb.2:
	movl	%ebx, %eax
	andl	$-3, %eax
	cmpl	$129, %eax
	sete	%al
	cmpl	$128, %ebx
	sete	%cl
	xorl	%edx, %edx
	cmpl	$3, %r12d
	ja	LBB0_4
## %bb.3:
	orb	%al, %cl
	jne	LBB0_31
LBB0_4:
	cmpl	$128, %ebx
	jne	LBB0_6
## %bb.5:
	movl	%r12d, %eax
	andl	$4, %eax
	je	LBB0_6
LBB0_31:
	movq	%r14, %rdi
	movl	%r15d, %esi
	callq	_kvm_queue_exception_e
	movq	_X86EMUL_PROPAGATE_FAULT@GOTPCREL(%rip), %rax
LBB0_41:
	movl	(%rax), %eax
LBB0_42:
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	leaq	-56(%rbp), %rdx
	movq	%r14, %rdi
	movl	%r12d, %esi
	callq	_load_guest_segment_descriptor
	testl	%eax, %eax
	jne	LBB0_42
## %bb.7:
	leaq	-56(%rbp), %rdi
	leaq	-88(%rbp), %rdx
	movl	%r12d, %esi
	callq	_seg_desct_to_kvm_desct
	cmpl	$3, %r12d
	ja	LBB0_9
## %bb.8:
	movl	$1, -88(%rbp)
LBB0_40:
	leaq	-88(%rbp), %rsi
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_kvm_set_segment
	movq	_X86EMUL_CONTINUE@GOTPCREL(%rip), %rax
	jmp	LBB0_41
LBB0_9:
	movl	%r12d, %edx
	andl	$65532, %edx                    ## imm = 0xFFFC
	movl	(%r13), %r15d
	movq	_VCPU_SREG_GS@GOTPCREL(%rip), %rax
	cmpl	%ebx, (%rax)
	jl	LBB0_11
## %bb.10:
	cmpq	$0, -72(%rbp)
	je	LBB0_31
LBB0_11:
	cmpl	$0, -64(%rbp)
	je	LBB0_12
## %bb.16:
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movl	%r12d, %r13d
	andl	$3, %r13d
	movl	-84(%rbp), %eax
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movq	_kvm_x86_ops@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%r14, %rdi
	callq	*(%rax)
	leal	-128(%rbx), %ecx
	cmpl	$3, %ecx
	ja	LBB0_32
## %bb.17:
	leaq	LJTI0_0(%rip), %rdx
	movslq	(%rdx,%rcx,4), %rcx
	addq	%rdx, %rcx
	jmpq	*%rcx
LBB0_27:
	cmpq	$0, -72(%rbp)
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	jne	LBB0_31
## %bb.28:
	movl	-80(%rbp), %ecx
	movl	%ecx, %eax
	andl	$-9, %eax
	cmpl	$1, %eax
	jne	LBB0_31
	jmp	LBB0_37
LBB0_12:
	cmpl	$129, %ebx
	jne	LBB0_13
## %bb.14:
	movq	_SS_VECTOR@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	jmp	LBB0_31
LBB0_13:
	movq	_NP_VECTOR@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	jmp	LBB0_31
LBB0_32:
	movl	-80(%rbp), %ecx
	movl	%ecx, %edx
	andl	$10, %edx
	cmpl	$8, %edx
	jne	LBB0_34
## %bb.33:
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	jmp	LBB0_31
LBB0_18:
	cmpl	%eax, %r13d
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	jne	LBB0_31
## %bb.19:
	movl	-80(%rbp), %ecx
	movl	%ecx, %eax
	andl	$10, %eax
	cmpl	$2, %eax
	jne	LBB0_31
## %bb.20:
	cmpl	%r13d, -48(%rbp)                ## 4-byte Folded Reload
	je	LBB0_37
	jmp	LBB0_31
LBB0_29:
	cmpq	$0, -72(%rbp)
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	jne	LBB0_31
## %bb.30:
	movl	$2, %ecx
	cmpl	$2, -80(%rbp)
	je	LBB0_37
	jmp	LBB0_31
LBB0_21:
	movl	-80(%rbp), %ecx
	testb	$8, %cl
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	je	LBB0_31
## %bb.22:
	testb	$4, %cl
	jne	LBB0_23
## %bb.24:
	cmpl	%eax, %r13d
	jg	LBB0_31
## %bb.25:
	cmpl	%eax, -48(%rbp)                 ## 4-byte Folded Reload
	je	LBB0_26
	jmp	LBB0_31
LBB0_34:
	movl	%ecx, %edx
	notl	%edx
	testb	$12, %dl
	je	LBB0_37
## %bb.35:
	movl	-48(%rbp), %esi                 ## 4-byte Reload
	cmpl	%esi, %r13d
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	jle	LBB0_37
## %bb.36:
	cmpl	%esi, %eax
	jg	LBB0_31
	jmp	LBB0_37
LBB0_23:
	cmpl	%eax, -48(%rbp)                 ## 4-byte Folded Reload
	jg	LBB0_31
LBB0_26:
	orl	%edx, %eax
	movl	%eax, %r12d
LBB0_37:
	cmpl	$0, -88(%rbp)
	jne	LBB0_40
## %bb.38:
	cmpq	$0, -72(%rbp)
	je	LBB0_40
## %bb.39:
	orl	$1, %ecx
	movl	%ecx, -80(%rbp)
	orb	$1, -56(%rbp)
	leaq	-56(%rbp), %rdx
	movq	%r14, %rdi
	movl	%r12d, %esi
	callq	_save_guest_segment_descriptor
	jmp	LBB0_40
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_27, LBB0_27-LJTI0_0
.set L0_0_set_18, LBB0_18-LJTI0_0
.set L0_0_set_29, LBB0_29-LJTI0_0
.set L0_0_set_21, LBB0_21-LJTI0_0
LJTI0_0:
	.long	L0_0_set_27
	.long	L0_0_set_18
	.long	L0_0_set_29
	.long	L0_0_set_21
	.end_data_region
                                        ## -- End function
	.comm	_GP_VECTOR,4,2                  ## @GP_VECTOR
	.comm	_X86_CR0_PE,4,2                 ## @X86_CR0_PE
	.comm	_VCPU_SREG_GS,4,2               ## @VCPU_SREG_GS
	.comm	_SS_VECTOR,4,2                  ## @SS_VECTOR
	.comm	_NP_VECTOR,4,2                  ## @NP_VECTOR
	.comm	_kvm_x86_ops,8,3                ## @kvm_x86_ops
	.comm	_X86EMUL_CONTINUE,4,2           ## @X86EMUL_CONTINUE
	.comm	_X86EMUL_PROPAGATE_FAULT,4,2    ## @X86EMUL_PROPAGATE_FAULT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_kvm_load_segment_descriptor    ; -- Begin function kvm_load_segment_descriptor
	.p2align	2
_kvm_load_segment_descriptor:           ; @kvm_load_segment_descriptor
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x20, x2
	mov	x22, x1
	mov	x19, x0
Lloh0:
	adrp	x24, _GP_VECTOR@GOTPAGE
Lloh1:
	ldr	x24, [x24, _GP_VECTOR@GOTPAGEOFF]
	ldr	w21, [x24]
	mov	x1, x2
	bl	_is_vm86_segment
	cbz	x0, LBB0_2
LBB0_1:
	mov	x0, x19
	mov	x1, x22
	mov	x2, x20
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #128
	b	_kvm_load_realmode_segment
LBB0_2:
Lloh2:
	adrp	x8, _X86_CR0_PE@GOTPAGE
Lloh3:
	ldr	x8, [x8, _X86_CR0_PE@GOTPAGEOFF]
Lloh4:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_kvm_read_cr0_bits
	cbz	w0, LBB0_1
; %bb.3:
	and	w8, w20, #0xfffffffd
	cmp	w20, #128
	mov	w9, #129
	ccmp	w8, w9, #4, ne
	cset	w8, eq
	cmp	w22, #3
	b.hi	LBB0_5
; %bb.4:
	tbnz	w8, #0, LBB0_7
LBB0_5:
	subs	w25, w20, #128
	b.ne	LBB0_11
; %bb.6:
	tbz	w22, #2, LBB0_11
LBB0_7:
	mov	w23, #0
LBB0_8:
	mov	x0, x19
	mov	x1, x21
	mov	x2, x23
	bl	_kvm_queue_exception_e
Lloh5:
	adrp	x8, _X86EMUL_PROPAGATE_FAULT@GOTPAGE
Lloh6:
	ldr	x8, [x8, _X86EMUL_PROPAGATE_FAULT@GOTPAGEOFF]
LBB0_9:
	ldr	w0, [x8]
LBB0_10:
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_11:
	add	x2, sp, #8
	mov	x0, x19
	mov	x1, x22
	bl	_load_guest_segment_descriptor
	cbnz	w0, LBB0_10
; %bb.12:
	add	x0, sp, #8
	add	x2, sp, #16
	mov	x1, x22
	bl	_seg_desct_to_kvm_desct
	cmp	w22, #3
	b.hi	LBB0_15
; %bb.13:
	mov	w8, #1
	str	w8, [sp, #16]
LBB0_14:
	add	x1, sp, #16
	mov	x0, x19
	mov	x2, x20
	bl	_kvm_set_segment
Lloh7:
	adrp	x8, _X86EMUL_CONTINUE@GOTPAGE
Lloh8:
	ldr	x8, [x8, _X86EMUL_CONTINUE@GOTPAGEOFF]
	b	LBB0_9
LBB0_15:
	and	w23, w22, #0xfffc
	ldr	w21, [x24]
Lloh9:
	adrp	x8, _VCPU_SREG_GS@GOTPAGE
Lloh10:
	ldr	x8, [x8, _VCPU_SREG_GS@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	ldr	x9, [sp, #32]
	cmp	w8, w20
	ccmp	x9, #0, #0, ge
	b.eq	LBB0_8
; %bb.16:
	ldr	w8, [sp, #40]
	cbz	w8, LBB0_21
; %bb.17:
	and	w26, w22, #0x3
	ldr	w24, [sp, #20]
Lloh12:
	adrp	x8, _kvm_x86_ops@GOTPAGE
Lloh13:
	ldr	x8, [x8, _kvm_x86_ops@GOTPAGEOFF]
Lloh14:
	ldr	x8, [x8]
	ldr	x8, [x8]
	mov	x0, x19
	blr	x8
	cmp	w25, #3
	b.hi	LBB0_22
; %bb.18:
Lloh15:
	adrp	x8, lJTI0_0@PAGE
Lloh16:
	add	x8, x8, lJTI0_0@PAGEOFF
	adr	x9, LBB0_19
	ldrb	w10, [x8, x25]
	add	x9, x9, x10, lsl #2
	br	x9
LBB0_19:
	ldr	x8, [sp, #32]
	cbnz	x8, LBB0_8
; %bb.20:
	ldr	w8, [sp, #24]
	and	w9, w8, #0xfffffff7
	cmp	w9, #1
	b.ne	LBB0_8
	b	LBB0_37
LBB0_21:
Lloh17:
	adrp	x8, _SS_VECTOR@GOTPAGE
Lloh18:
	ldr	x8, [x8, _SS_VECTOR@GOTPAGEOFF]
Lloh19:
	adrp	x9, _NP_VECTOR@GOTPAGE
Lloh20:
	ldr	x9, [x9, _NP_VECTOR@GOTPAGEOFF]
	cmp	w20, #129
	csel	x8, x8, x9, eq
	ldr	w21, [x8]
	b	LBB0_8
LBB0_22:
	ldr	w8, [sp, #24]
	mov	w9, #10
	and	w9, w8, w9
	cmp	w9, #8
	b.eq	LBB0_8
; %bb.23:
	mvn	w9, w8
	tst	w9, #0xc
	b.eq	LBB0_37
; %bb.24:
	cmp	w26, w24
	b.le	LBB0_37
; %bb.25:
	cmp	w0, w24
	b.gt	LBB0_8
	b	LBB0_37
LBB0_26:
	cmp	w26, w0
	b.ne	LBB0_8
; %bb.27:
	ldr	w8, [sp, #24]
	mov	w9, #10
	and	w9, w8, w9
	cmp	w9, #2
	b.ne	LBB0_8
; %bb.28:
	cmp	w24, w26
	b.eq	LBB0_37
	b	LBB0_8
LBB0_29:
	ldr	x8, [sp, #32]
	cbnz	x8, LBB0_8
; %bb.30:
	ldr	w8, [sp, #24]
	cmp	w8, #2
	b.eq	LBB0_37
	b	LBB0_8
LBB0_31:
	ldr	w8, [sp, #24]
	tbz	w8, #3, LBB0_8
; %bb.32:
	tbnz	w8, #2, LBB0_35
; %bb.33:
	cmp	w26, w0
	b.gt	LBB0_8
; %bb.34:
	cmp	w24, w0
	b.eq	LBB0_36
	b	LBB0_8
LBB0_35:
	cmp	w24, w0
	b.gt	LBB0_8
LBB0_36:
	orr	w22, w0, w23
LBB0_37:
	ldr	w9, [sp, #16]
	cbnz	w9, LBB0_14
; %bb.38:
	ldr	x9, [sp, #32]
	cbz	x9, LBB0_14
; %bb.39:
	orr	w8, w8, #0x1
	str	w8, [sp, #24]
	ldr	w8, [sp, #8]
	orr	w8, w8, #0x1
	str	w8, [sp, #8]
	add	x2, sp, #8
	mov	x0, x19
	mov	x1, x22
	bl	_save_guest_segment_descriptor
	b	LBB0_14
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh17, Lloh18
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_19-LBB0_19)>>2
	.byte	(LBB0_26-LBB0_19)>>2
	.byte	(LBB0_29-LBB0_19)>>2
	.byte	(LBB0_31-LBB0_19)>>2
                                        ; -- End function
	.comm	_GP_VECTOR,4,2                  ; @GP_VECTOR
	.comm	_X86_CR0_PE,4,2                 ; @X86_CR0_PE
	.comm	_VCPU_SREG_GS,4,2               ; @VCPU_SREG_GS
	.comm	_SS_VECTOR,4,2                  ; @SS_VECTOR
	.comm	_NP_VECTOR,4,2                  ; @NP_VECTOR
	.comm	_kvm_x86_ops,8,3                ; @kvm_x86_ops
	.comm	_X86EMUL_CONTINUE,4,2           ; @X86EMUL_CONTINUE
	.comm	_X86EMUL_PROPAGATE_FAULT,4,2    ; @X86EMUL_PROPAGATE_FAULT
.subsections_via_symbols
