	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gamw_echo_dev_rw_ia_write
_gamw_echo_dev_rw_ia_write:             ## @gamw_echo_dev_rw_ia_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	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%ecx, %r15d
	movq	%rdx, %r12
	movl	%esi, %r14d
	movq	%rdi, %r13
	movq	_GAMW_ECO_ENABLE_64K_IPS_FIELD@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	andl	(%rdx), %ebx
	movq	8(%rdi), %rax
	movl	(%rax), %edi
	callq	_INTEL_GEN
	cmpl	$10, %eax
	jg	LBB0_6
## %bb.1:
	movq	_GAMW_ECO_ENABLE_64K_IPS_FIELD@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_3
## %bb.2:
	leaq	L_.str(%rip), %rdi
	jmp	LBB0_5
LBB0_3:
	testl	%ebx, %ebx
	je	LBB0_4
## %bb.8:
	leaq	L_.str.2(%rip), %rdi
	movl	%ebx, %esi
	callq	_gvt_vgpu_err
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_7
LBB0_4:
	leaq	L_.str.1(%rip), %rdi
LBB0_5:
	movl	(%r13), %esi
	callq	_gvt_dbg_core
LBB0_6:
	movq	%r13, %rdi
	movl	%r14d, %esi
	movq	%r12, %rdx
	movl	%r15d, %ecx
	callq	_write_vreg
	xorl	%eax, %eax
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_GAMW_ECO_ENABLE_64K_IPS_FIELD,4,2 ## @GAMW_ECO_ENABLE_64K_IPS_FIELD
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"vgpu%d: ips enabled\n"

L_.str.1:                               ## @.str.1
	.asciz	"vgpu%d: ips disabled\n"

L_.str.2:                               ## @.str.2
	.asciz	"Unsupported IPS setting %x, cannot enable 64K gtt.\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_gamw_echo_dev_rw_ia_write
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function gamw_echo_dev_rw_ia_write
_gamw_echo_dev_rw_ia_write:             ; @gamw_echo_dev_rw_ia_write
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x3
	mov	x20, x2
	mov	x21, x1
	mov	x22, x0
	ldr	w23, [x2]
Lloh0:
	adrp	x24, _GAMW_ECO_ENABLE_64K_IPS_FIELD@GOTPAGE
Lloh1:
	ldr	x24, [x24, _GAMW_ECO_ENABLE_64K_IPS_FIELD@GOTPAGEOFF]
	ldr	w25, [x24]
	ldr	x8, [x0, #8]
	ldr	w0, [x8]
	bl	_INTEL_GEN
	cmp	w0, #10
	b.gt	LBB0_7
; %bb.1:
	and	w1, w25, w23
	ldr	w8, [x24]
	cmp	w1, w8
	b.ne	LBB0_3
; %bb.2:
Lloh2:
	adrp	x0, l_.str@PAGE
Lloh3:
	add	x0, x0, l_.str@PAGEOFF
	b	LBB0_6
LBB0_3:
	cbz	w1, LBB0_5
; %bb.4:
Lloh4:
	adrp	x0, l_.str.2@PAGE
Lloh5:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_gvt_vgpu_err
Lloh6:
	adrp	x8, _EINVAL@GOTPAGE
Lloh7:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_8
LBB0_5:
Lloh9:
	adrp	x0, l_.str.1@PAGE
Lloh10:
	add	x0, x0, l_.str.1@PAGEOFF
LBB0_6:
	ldr	w1, [x22]
	bl	_gvt_dbg_core
LBB0_7:
	mov	x0, x22
	mov	x1, x21
	mov	x2, x20
	mov	x3, x19
	bl	_write_vreg
	mov	w0, #0
LBB0_8:
	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
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_GAMW_ECO_ENABLE_64K_IPS_FIELD,4,2 ; @GAMW_ECO_ENABLE_64K_IPS_FIELD
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"vgpu%d: ips enabled\n"

l_.str.1:                               ; @.str.1
	.asciz	"vgpu%d: ips disabled\n"

l_.str.2:                               ; @.str.2
	.asciz	"Unsupported IPS setting %x, cannot enable 64K gtt.\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_gamw_echo_dev_rw_ia_write
.subsections_via_symbols
