	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gl_cg_load_plain
_gl_cg_load_plain:                      ## @gl_cg_load_plain
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %rbx
	callq	_gl_cg_load_stock
	xorl	%r14d, %r14d
	testl	%eax, %eax
	je	LBB0_6
## %bb.1:
	movl	$1, %edi
	movl	$16, %esi
	callq	_calloc
	movq	%rax, (%rbx)
	testq	%rax, %rax
	je	LBB0_6
## %bb.2:
	movl	$1, (%rax)
	movq	%r15, %rdi
	callq	_string_is_empty
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_RARCH_LOG
	movq	8(%rbx), %rax
	movl	(%rax), %ecx
	movl	%ecx, 4(%rax)
	jmp	LBB0_5
LBB0_4:
	movq	%r15, -40(%rbp)
	movl	$1, -32(%rbp)
	leaq	L_.str.1(%rip), %rdi
	xorl	%r14d, %r14d
	movq	%r15, %rsi
	xorl	%eax, %eax
	callq	_RARCH_LOG
	movq	(%rbx), %rax
	movq	8(%rax), %rax
	movl	(%rax), %edi
	movq	%r15, %rsi
	movl	$4, %edx
	callq	_strlcpy
	movq	8(%rbx), %rdx
	addq	$4, %rdx
	leaq	-40(%rbp), %rcx
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_gl_cg_compile_program
	testl	%eax, %eax
	je	LBB0_6
LBB0_5:
	movq	(%rbx), %rsi
	xorl	%edi, %edi
	callq	_video_shader_resolve_parameters
	movl	$1, %r14d
LBB0_6:
	movl	%r14d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"[CG]: Loading stock Cg file.\n"

L_.str.1:                               ## @.str.1
	.asciz	"[CG]: Loading Cg file: %s\n"

	.no_dead_strip	_gl_cg_load_plain
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function gl_cg_load_plain
_gl_cg_load_plain:                      ; @gl_cg_load_plain
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	mov	x20, x1
	mov	x19, x0
	bl	_gl_cg_load_stock
	cbz	w0, LBB0_6
; %bb.1:
	mov	w21, #1
	mov	w0, #1
	mov	w1, #16
	bl	_calloc
	str	x0, [x19]
	cbz	x0, LBB0_6
; %bb.2:
	str	w21, [x0]
	mov	x0, x20
	bl	_string_is_empty
	cbz	x0, LBB0_4
; %bb.3:
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_RARCH_LOG
	ldr	x8, [x19, #8]
	ldr	w9, [x8]
	str	w9, [x8, #4]
	b	LBB0_5
LBB0_4:
	str	x20, [sp, #16]
	mov	w8, #1
	str	w8, [sp, #24]
	str	x20, [sp]
Lloh2:
	adrp	x0, l_.str.1@PAGE
Lloh3:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_RARCH_LOG
	ldr	x8, [x19]
	ldr	x8, [x8, #8]
	ldr	w0, [x8]
	mov	x1, x20
	mov	w2, #4
	bl	_strlcpy
	ldr	x8, [x19, #8]
	add	x2, x8, #4
	add	x3, sp, #16
	mov	x0, x19
	mov	w1, #1
	bl	_gl_cg_compile_program
	cbz	w0, LBB0_6
LBB0_5:
	ldr	x1, [x19]
	mov	x0, #0
	bl	_video_shader_resolve_parameters
	mov	w0, #1
LBB0_6:
	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
	add	sp, sp, #80
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"[CG]: Loading stock Cg file.\n"

l_.str.1:                               ; @.str.1
	.asciz	"[CG]: Loading Cg file: %s\n"

	.no_dead_strip	_gl_cg_load_plain
.subsections_via_symbols
