	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_LoadJPG                        ## -- Begin function LoadJPG
	.p2align	4, 0x90
_LoadJPG:                               ## @LoadJPG
	.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
	movq	%rcx, %r14
	movq	%rdx, %r15
	movq	%rsi, %r12
	movq	_qfalse@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	-72(%rbp), %rsi
	callq	_FS_FOpenFileRead
	cmpq	$0, -72(%rbp)
	je	LBB0_1
## %bb.2:
	leaq	-80(%rbp), %rdi
	callq	_jpeg_std_error
	movl	%eax, -48(%rbp)
	leaq	-64(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_jpeg_create_decompress
	movq	-72(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_jpeg_stdio_src
	movq	_TRUE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_jpeg_read_header
	movq	%rbx, %rdi
	callq	_jpeg_start_decompress
	movl	-60(%rbp), %r13d
	imull	-64(%rbp), %r13d
	movl	-56(%rbp), %edi
	imull	%r13d, %edi
	callq	_Z_Malloc
	movq	%rax, %rbx
	movq	%rax, (%r12)
	movl	-64(%rbp), %eax
	movl	%eax, (%r15)
	movl	-56(%rbp), %ecx
	movl	%ecx, (%r14)
	movl	-52(%rbp), %eax
	cmpl	%ecx, %eax
	jge	LBB0_5
## %bb.3:
	leaq	-64(%rbp), %r14
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	imull	%r13d, %eax
	movslq	%eax, %rsi
	addq	%rbx, %rsi
	movq	%r14, %rdi
	movl	$1, %edx
	callq	_jpeg_read_scanlines
	movl	-52(%rbp), %eax
	cmpl	-56(%rbp), %eax
	jl	LBB0_4
LBB0_5:
	leaq	-64(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_jpeg_finish_decompress
	movq	%rbx, %rdi
	callq	_jpeg_destroy_decompress
	movq	-72(%rbp), %rdi
	callq	_FS_FCloseFile
	movl	$1, %eax
	jmp	LBB0_6
LBB0_1:
	xorl	%eax, %eax
LBB0_6:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_qfalse,4,2                     ## @qfalse
	.comm	_TRUE,4,2                       ## @TRUE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_LoadJPG                        ; -- Begin function LoadJPG
	.p2align	2
_LoadJPG:                               ; @LoadJPG
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	mov	x19, x3
	mov	x20, x2
	mov	x21, x1
Lloh0:
	adrp	x8, _qfalse@GOTPAGE
Lloh1:
	ldr	x8, [x8, _qfalse@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	add	x1, sp, #8
	bl	_FS_FOpenFileRead
	ldr	x8, [sp, #8]
	cbz	x8, LBB0_5
; %bb.1:
	add	x0, sp, #16
	bl	_jpeg_std_error
	str	w0, [sp, #40]
	add	x0, sp, #24
	bl	_jpeg_create_decompress
	ldr	x1, [sp, #8]
	add	x0, sp, #24
	bl	_jpeg_stdio_src
Lloh3:
	adrp	x8, _TRUE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _TRUE@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	add	x0, sp, #24
	bl	_jpeg_read_header
	add	x0, sp, #24
	bl	_jpeg_start_decompress
	ldp	w8, w9, [sp, #24]
	mul	w23, w9, w8
	ldr	w8, [sp, #32]
	mul	w0, w23, w8
	bl	_Z_Malloc
	str	x0, [x21]
	ldr	w8, [sp, #24]
	ldr	w9, [sp, #32]
	str	w8, [x20]
	str	w9, [x19]
	ldr	w8, [sp, #36]
	cmp	w8, w9
	b.ge	LBB0_4
; %bb.2:
	mov	x22, x0
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	mul	w8, w23, w8
	add	x1, x22, w8, sxtw
	add	x0, sp, #24
	mov	w2, #1
	bl	_jpeg_read_scanlines
	ldp	w9, w8, [sp, #32]
	cmp	w8, w9
	b.lt	LBB0_3
LBB0_4:
	add	x0, sp, #24
	bl	_jpeg_finish_decompress
	add	x0, sp, #24
	bl	_jpeg_destroy_decompress
	ldr	x0, [sp, #8]
	bl	_FS_FCloseFile
	mov	w0, #1
	b	LBB0_6
LBB0_5:
	mov	w0, #0
LBB0_6:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_qfalse,4,2                     ; @qfalse
	.comm	_TRUE,4,2                       ; @TRUE
.subsections_via_symbols
