	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pshader_hw_texreg2ar
_pshader_hw_texreg2ar:                  ## @pshader_hw_texreg2ar
	.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	$152, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	(%rdi), %rax
	movq	16(%rdi), %rsi
	movq	8(%rax), %r15
	movq	(%rsi), %rax
	movq	(%rax), %r14
	leaq	-112(%rbp), %rdx
	callq	_shader_arb_get_dst_param
	movq	8(%rbx), %rsi
	xorl	%r13d, %r13d
	leaq	-176(%rbp), %r12
	movq	%rbx, %rdi
	xorl	%edx, %edx
	movq	%r12, %rcx
	callq	_shader_arb_get_src_param
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	movq	%r12, %rdx
	callq	_shader_addline
	leaq	L_.str.1(%rip), %rsi
	movq	%r15, %rdi
	movq	%r12, %rdx
	callq	_shader_addline
	movq	_MAX_TEXTURES@GOTPCREL(%rip), %rax
	cmpq	(%rax), %r14
	jge	LBB0_2
## %bb.1:
	movq	(%rbx), %rax
	movq	(%rax), %rax
	movq	(%rax), %rax
	movq	(%rax), %r13
	movq	_WINED3D_PSARGS_TEXTRANSFORM_SHIFT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	imull	%r14d, %ecx
                                        ## kill: def $cl killed $cl killed $ecx
	sarq	%cl, %r13
LBB0_2:
	movq	_WINED3D_PSARGS_PROJECTED@GOTPCREL(%rip), %rax
	movl	$0, %r8d
	andq	(%rax), %r13
	je	LBB0_4
## %bb.3:
	movq	_TEX_PROJ@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
LBB0_4:
	movq	$0, (%rsp)
	leaq	L_.str.2(%rip), %rcx
	leaq	-112(%rbp), %rdx
	movq	%rbx, %rdi
	movq	%r14, %rsi
	xorl	%r9d, %r9d
	callq	_shader_hw_sample
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_6
## %bb.5:
	addq	$152, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"MOV TA.y, %s.x;\n"

L_.str.1:                               ## @.str.1
	.asciz	"MOV TA.x, %s.w;\n"

	.comm	_MAX_TEXTURES,8,3               ## @MAX_TEXTURES
	.comm	_WINED3D_PSARGS_TEXTRANSFORM_SHIFT,8,3 ## @WINED3D_PSARGS_TEXTRANSFORM_SHIFT
L_.str.2:                               ## @.str.2
	.asciz	"TA"

	.comm	_WINED3D_PSARGS_PROJECTED,8,3   ## @WINED3D_PSARGS_PROJECTED
	.comm	_TEX_PROJ,4,2                   ## @TEX_PROJ
	.no_dead_strip	_pshader_hw_texreg2ar
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pshader_hw_texreg2ar
_pshader_hw_texreg2ar:                  ; @pshader_hw_texreg2ar
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #160
	.cfi_def_cfa_offset 160
	stp	x22, x21, [sp, #112]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #128]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #144]            ; 16-byte Folded Spill
	add	x29, sp, #144
	.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, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-40]
	ldr	x8, [x0]
	ldr	x21, [x8, #8]
	ldr	x1, [x0, #16]
	ldr	x8, [x1]
	ldr	x20, [x8]
	add	x2, sp, #54
	bl	_shader_arb_get_dst_param
	ldr	x1, [x19, #8]
	add	x3, sp, #4
	mov	x0, x19
	mov	w2, #0
	bl	_shader_arb_get_src_param
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	add	x2, sp, #4
	mov	x0, x21
	bl	_shader_addline
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	add	x2, sp, #4
	mov	x0, x21
	bl	_shader_addline
Lloh7:
	adrp	x8, _MAX_TEXTURES@GOTPAGE
Lloh8:
	ldr	x8, [x8, _MAX_TEXTURES@GOTPAGEOFF]
Lloh9:
	ldr	x8, [x8]
	cmp	x20, x8
	b.ge	LBB0_2
; %bb.1:
	ldr	x8, [x19]
	ldr	x8, [x8]
	ldr	x8, [x8]
	ldr	x8, [x8]
Lloh10:
	adrp	x9, _WINED3D_PSARGS_TEXTRANSFORM_SHIFT@GOTPAGE
Lloh11:
	ldr	x9, [x9, _WINED3D_PSARGS_TEXTRANSFORM_SHIFT@GOTPAGEOFF]
Lloh12:
	ldr	x9, [x9]
	mul	x9, x9, x20
	asr	x8, x8, x9
	b	LBB0_3
LBB0_2:
	mov	x8, #0
LBB0_3:
Lloh13:
	adrp	x9, _WINED3D_PSARGS_PROJECTED@GOTPAGE
Lloh14:
	ldr	x9, [x9, _WINED3D_PSARGS_PROJECTED@GOTPAGEOFF]
Lloh15:
	ldr	x9, [x9]
Lloh16:
	adrp	x10, _TEX_PROJ@GOTPAGE
Lloh17:
	ldr	x10, [x10, _TEX_PROJ@GOTPAGEOFF]
Lloh18:
	ldr	w10, [x10]
	tst	x9, x8
	csel	w4, wzr, w10, eq
Lloh19:
	adrp	x3, l_.str.2@PAGE
Lloh20:
	add	x3, x3, l_.str.2@PAGEOFF
	add	x2, sp, #54
	mov	x0, x19
	mov	x1, x20
	mov	x5, #0
	mov	x6, #0
	bl	_shader_hw_sample
	ldur	x8, [x29, #-40]
Lloh21:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh22:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh23:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_5
; %bb.4:
	ldp	x29, x30, [sp, #144]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #128]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #112]            ; 16-byte Folded Reload
	add	sp, sp, #160
	ret
LBB0_5:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"MOV TA.y, %s.x;\n"

l_.str.1:                               ; @.str.1
	.asciz	"MOV TA.x, %s.w;\n"

	.comm	_MAX_TEXTURES,8,3               ; @MAX_TEXTURES
	.comm	_WINED3D_PSARGS_TEXTRANSFORM_SHIFT,8,3 ; @WINED3D_PSARGS_TEXTRANSFORM_SHIFT
l_.str.2:                               ; @.str.2
	.asciz	"TA"

	.comm	_WINED3D_PSARGS_PROJECTED,8,3   ; @WINED3D_PSARGS_PROJECTED
	.comm	_TEX_PROJ,4,2                   ; @TEX_PROJ
	.no_dead_strip	_pshader_hw_texreg2ar
.subsections_via_symbols
