	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function shader_glsl_generate_patch_constant_setup
_shader_glsl_generate_patch_constant_setup: ## @shader_glsl_generate_patch_constant_setup
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	cmpl	$0, (%rsi)
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	movq	%rdx, -72(%rbp)                 ## 8-byte Spill
	movq	%rsi, -64(%rbp)                 ## 8-byte Spill
	je	LBB0_1
## %bb.2:
	xorl	%ebx, %ebx
	xorl	%r15d, %r15d
	xorl	%edx, %edx
	xorl	%r14d, %r14d
	movq	-64(%rbp), %r12                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r12), %r13
	movq	(%r13,%rbx), %rdi
	incq	%rdi
	movl	%edx, %esi
	callq	_max
	movl	%eax, %edx
	cmpl	$1, 12(%r13,%rbx)
	adcl	$0, %r14d
	incq	%r15
	movl	(%r12), %eax
	addq	$16, %rbx
	cmpq	%rax, %r15
	jb	LBB0_3
## %bb.4:
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	testl	%r14d, %r14d
	je	LBB0_5
## %bb.6:
	movq	-72(%rbp), %rbx                 ## 8-byte Reload
	testq	%rbx, %rbx
	leaq	L_.str.2(%rip), %rax
	movl	%edx, %r12d
	leaq	L_.str.1(%rip), %rdx
	cmoveq	%rax, %rdx
	leaq	L_.str(%rip), %rsi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movl	%r14d, %ecx
	xorl	%eax, %eax
	callq	_shader_addline
	movl	%r12d, %edx
	testq	%rbx, %rbx
	jne	LBB0_9
	jmp	LBB0_8
LBB0_1:
	movq	%rdx, %rbx
	movq	%rsi, %r15
	xorl	%edx, %edx
	testq	%rbx, %rbx
	je	LBB0_8
LBB0_9:
	leaq	L_.str.3(%rip), %rsi
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	xorl	%eax, %eax
	callq	_shader_addline
	leaq	L_.str.5(%rip), %rdx
	jmp	LBB0_10
LBB0_5:
	movq	-72(%rbp), %rbx                 ## 8-byte Reload
	testq	%rbx, %rbx
	jne	LBB0_9
LBB0_8:
	leaq	L_.str.6(%rip), %rdx
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
LBB0_10:
	leaq	L_.str.4(%rip), %rsi
	movq	%rbx, %rdi
	xorl	%eax, %eax
	callq	_shader_addline
	movl	$0, -52(%rbp)
	cmpl	$0, (%r15)
	je	LBB0_16
## %bb.11:
	leaq	-78(%rbp), %r13
	xorl	%r14d, %r14d
	xorl	%r12d, %r12d
	jmp	LBB0_12
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_12 Depth=1
	movq	%r15, %rsi
	movq	-48(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	leaq	-52(%rbp), %rdx
	movq	%r13, %rcx
	callq	_shader_glsl_generate_patch_constant_name
	movq	%r15, %rdi
	leaq	L_.str.8(%rip), %rsi
	xorl	%eax, %eax
	callq	_shader_addline
	movq	(%rbx,%r14), %rdx
	movq	%r15, %rbx
	movq	%r15, %rdi
	leaq	L_.str.9(%rip), %rsi
	movq	%r13, %rcx
	xorl	%eax, %eax
	callq	_shader_addline
LBB0_15:                                ##   in Loop: Header=BB0_12 Depth=1
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	movq	%rbx, %rdi
	leaq	L_.str.10(%rip), %rsi
	xorl	%eax, %eax
	callq	_shader_addline
	incq	%r12
	movl	(%r15), %eax
	addq	$16, %r14
	cmpq	%rax, %r12
	leaq	-78(%rbp), %r13
	jae	LBB0_16
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r15), %rbx
	leaq	(%rbx,%r14), %r15
	movl	8(%rbx,%r14), %edi
	movq	%r13, %rsi
	callq	_shader_glsl_write_mask_to_str
	cmpq	$0, -72(%rbp)                   ## 8-byte Folded Reload
	je	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_12 Depth=1
	movq	(%rbx,%r14), %rdx
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	leaq	L_.str.7(%rip), %rsi
	movq	%r13, %rcx
	xorl	%eax, %eax
	callq	_shader_addline
	movq	%rbx, %rdi
	leaq	L_.str.8(%rip), %rsi
	xorl	%eax, %eax
	callq	_shader_addline
	movq	%rbx, %rdi
	movq	%r15, %rsi
	leaq	-52(%rbp), %rdx
	movq	%r13, %rcx
	callq	_shader_glsl_generate_patch_constant_name
	jmp	LBB0_15
LBB0_16:
	leaq	L_.str.11(%rip), %rsi
	movq	%rbx, %rdi
	xorl	%eax, %eax
	callq	_shader_addline
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"patch %s vec4 user_patch_constant[%u];\n"

L_.str.1:                               ## @.str.1
	.asciz	"in"

L_.str.2:                               ## @.str.2
	.asciz	"out"

L_.str.3:                               ## @.str.3
	.asciz	"vec4 vpc[%u];\n"

L_.str.4:                               ## @.str.4
	.asciz	"void setup_patch_constant_%s()\n{\n"

L_.str.5:                               ## @.str.5
	.asciz	"input"

L_.str.6:                               ## @.str.6
	.asciz	"output"

L_.str.7:                               ## @.str.7
	.asciz	"vpc[%u]%s"

L_.str.8:                               ## @.str.8
	.asciz	" = "

L_.str.9:                               ## @.str.9
	.asciz	"hs_out[%u]%s"

L_.str.10:                              ## @.str.10
	.asciz	";\n"

L_.str.11:                              ## @.str.11
	.asciz	"}\n"

	.no_dead_strip	_shader_glsl_generate_patch_constant_setup
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function shader_glsl_generate_patch_constant_setup
_shader_glsl_generate_patch_constant_setup: ; @shader_glsl_generate_patch_constant_setup
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x20, x2
	mov	x21, x1
	mov	x19, x0
	ldr	w8, [x1]
	cbz	w8, LBB0_7
; %bb.1:
	mov	x24, #0
	mov	x25, #0
	mov	w22, #0
	mov	w23, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x21, #8]
	add	x26, x8, x24
	ldr	x8, [x26]
	add	x0, x8, #1
	mov	x1, x22
	bl	_max
	mov	x22, x0
	ldr	w8, [x26, #12]
	cmp	w8, #0
	cinc	w23, w23, eq
	add	x25, x25, #1
	ldr	w8, [x21]
	add	x24, x24, #16
	cmp	x25, x8
	b.lo	LBB0_2
; %bb.3:
	cbz	w23, LBB0_5
; %bb.4:
Lloh0:
	adrp	x8, l_.str.1@PAGE
Lloh1:
	add	x8, x8, l_.str.1@PAGEOFF
Lloh2:
	adrp	x9, l_.str.2@PAGE
Lloh3:
	add	x9, x9, l_.str.2@PAGEOFF
	cmp	x20, #0
	csel	x8, x9, x8, eq
	stp	x8, x23, [sp]
Lloh4:
	adrp	x1, l_.str@PAGE
Lloh5:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_shader_addline
LBB0_5:
	cbz	x20, LBB0_8
LBB0_6:
	str	x22, [sp]
Lloh6:
	adrp	x1, l_.str.3@PAGE
Lloh7:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x19
	bl	_shader_addline
Lloh8:
	adrp	x8, l_.str.5@PAGE
Lloh9:
	add	x8, x8, l_.str.5@PAGEOFF
	b	LBB0_9
LBB0_7:
	mov	w22, #0
	cbnz	x20, LBB0_6
LBB0_8:
Lloh10:
	adrp	x8, l_.str.6@PAGE
Lloh11:
	add	x8, x8, l_.str.6@PAGEOFF
LBB0_9:
	str	x8, [sp]
Lloh12:
	adrp	x1, l_.str.4@PAGE
Lloh13:
	add	x1, x1, l_.str.4@PAGEOFF
	mov	x0, x19
	bl	_shader_addline
	str	wzr, [sp, #28]
	ldr	w8, [x21]
	cbz	w8, LBB0_15
; %bb.10:
	mov	x27, #0
	mov	x28, #0
	add	x23, sp, #22
Lloh14:
	adrp	x22, l_.str.8@PAGE
Lloh15:
	add	x22, x22, l_.str.8@PAGEOFF
Lloh16:
	adrp	x24, l_.str.10@PAGE
Lloh17:
	add	x24, x24, l_.str.10@PAGEOFF
	b	LBB0_13
LBB0_11:                                ;   in Loop: Header=BB0_13 Depth=1
	add	x2, sp, #28
	add	x3, sp, #22
	mov	x0, x19
	mov	x1, x26
	bl	_shader_glsl_generate_patch_constant_name
	mov	x0, x19
	mov	x1, x22
	bl	_shader_addline
	ldr	x8, [x25, x27]
	stp	x8, x23, [sp]
	mov	x0, x19
Lloh18:
	adrp	x1, l_.str.9@PAGE
Lloh19:
	add	x1, x1, l_.str.9@PAGEOFF
	bl	_shader_addline
LBB0_12:                                ;   in Loop: Header=BB0_13 Depth=1
	mov	x0, x19
	mov	x1, x24
	bl	_shader_addline
	add	x28, x28, #1
	ldr	w8, [x21]
	add	x27, x27, #16
	cmp	x28, x8
	b.hs	LBB0_15
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldr	x25, [x21, #8]
	add	x26, x25, x27
	ldr	w0, [x26, #8]
	add	x1, sp, #22
	bl	_shader_glsl_write_mask_to_str
	cbz	x20, LBB0_11
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	x8, [x25, x27]
	stp	x8, x23, [sp]
	mov	x0, x19
Lloh20:
	adrp	x1, l_.str.7@PAGE
Lloh21:
	add	x1, x1, l_.str.7@PAGEOFF
	bl	_shader_addline
	mov	x0, x19
	mov	x1, x22
	bl	_shader_addline
	add	x2, sp, #28
	add	x3, sp, #22
	mov	x0, x19
	mov	x1, x26
	bl	_shader_glsl_generate_patch_constant_name
	b	LBB0_12
LBB0_15:
Lloh22:
	adrp	x1, l_.str.11@PAGE
Lloh23:
	add	x1, x1, l_.str.11@PAGEOFF
	mov	x0, x19
	bl	_shader_addline
	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
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"patch %s vec4 user_patch_constant[%u];\n"

l_.str.1:                               ; @.str.1
	.asciz	"in"

l_.str.2:                               ; @.str.2
	.asciz	"out"

l_.str.3:                               ; @.str.3
	.asciz	"vec4 vpc[%u];\n"

l_.str.4:                               ; @.str.4
	.asciz	"void setup_patch_constant_%s()\n{\n"

l_.str.5:                               ; @.str.5
	.asciz	"input"

l_.str.6:                               ; @.str.6
	.asciz	"output"

l_.str.7:                               ; @.str.7
	.asciz	"vpc[%u]%s"

l_.str.8:                               ; @.str.8
	.asciz	" = "

l_.str.9:                               ; @.str.9
	.asciz	"hs_out[%u]%s"

l_.str.10:                              ; @.str.10
	.asciz	";\n"

l_.str.11:                              ; @.str.11
	.asciz	"}\n"

	.no_dead_strip	_shader_glsl_generate_patch_constant_setup
.subsections_via_symbols
