	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_jpeg_copy_critical_parameters  ## -- Begin function jpeg_copy_critical_parameters
	.p2align	4, 0x90
_jpeg_copy_critical_parameters:         ## @jpeg_copy_critical_parameters
	.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	%rsi, %rcx
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movq	(%rsi), %rdx
	movq	_CSTATE_START@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rdx
	movq	%rsi, -48(%rbp)                 ## 8-byte Spill
	je	LBB0_2
## %bb.1:
	movq	_JERR_BAD_STATE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rcx, %rdi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_ERREXIT1
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
LBB0_2:
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movl	40(%rbx), %eax
	movl	%eax, 48(%rcx)
	movl	36(%rbx), %eax
	movl	%eax, 44(%rcx)
	movl	(%rbx), %eax
	movl	%eax, 8(%rcx)
	movl	32(%rbx), %eax
	movl	%eax, 40(%rcx)
	movq	%rcx, %rdi
	callq	_jpeg_set_defaults
	movl	32(%rbx), %esi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_jpeg_set_colorspace
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movl	28(%rbx), %eax
	movl	%eax, 36(%rdi)
	movl	24(%rbx), %eax
	movl	%eax, 32(%rdi)
	movq	_NUM_QUANT_TBLS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, %eax
	jle	LBB0_9
## %bb.3:
	xorl	%ebx, %ebx
	movq	_FALSE@GOTPCREL(%rip), %r13
	jmp	LBB0_4
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_4 Depth=1
	movq	(%rax), %r14
	movq	(%rcx), %r12
	movq	%r14, %rdi
	callq	_SIZEOF
	movq	%r14, %rdi
	movq	%r12, %rsi
	movl	%eax, %edx
	callq	_MEMCOPY
	movl	(%r13), %eax
	movq	(%r15,%rbx,8), %rcx
	movl	%eax, 8(%rcx)
	movq	_NUM_QUANT_TBLS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
LBB0_8:                                 ##   in Loop: Header=BB0_4 Depth=1
	incq	%rbx
	movslq	%eax, %rcx
	cmpq	%rcx, %rbx
	jge	LBB0_9
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movq	8(%rcx), %rcx
	movq	(%rcx,%rbx,8), %rcx
	testq	%rcx, %rcx
	je	LBB0_8
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	24(%rdi), %r15
	movq	(%r15,%rbx,8), %rax
	testq	%rax, %rax
	jne	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_jpeg_alloc_quant_table
	movq	%rax, (%r15,%rbx,8)
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movq	8(%rcx), %rcx
	movq	(%rcx,%rbx,8), %rcx
	jmp	LBB0_7
LBB0_9:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edx
	movl	%edx, 12(%rdi)
	movq	_MAX_COMPONENTS@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	testl	%edx, %edx
	jle	LBB0_11
## %bb.10:
	cmpl	%ecx, %edx
	jle	LBB0_12
LBB0_11:
	movq	_JERR_COMPONENT_COUNT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_ERREXIT2
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	cmpl	$0, 12(%rdi)
	jle	LBB0_24
LBB0_12:
	movq	16(%rdi), %rcx
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	16(%rax), %r13
	xorl	%eax, %eax
	jmp	LBB0_13
	.p2align	4, 0x90
LBB0_23:                                ##   in Loop: Header=BB0_13 Depth=1
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	incl	%eax
	addq	$32, %r13
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	addq	$32, %rcx
	cmpl	12(%rdi), %eax
	jge	LBB0_24
LBB0_13:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_20 Depth 2
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movl	24(%r13), %eax
	movl	%eax, 24(%rcx)
	movl	20(%r13), %eax
	movl	%eax, 20(%rcx)
	movl	16(%r13), %eax
	movl	%eax, 16(%rcx)
	movslq	(%r13), %rbx
	movl	%ebx, %edx
	movq	%rcx, -72(%rbp)                 ## 8-byte Spill
	movl	%ebx, (%rcx)
	testq	%rbx, %rbx
	js	LBB0_16
## %bb.14:                              ##   in Loop: Header=BB0_13 Depth=1
	movq	_NUM_QUANT_TBLS@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jge	LBB0_16
## %bb.15:                              ##   in Loop: Header=BB0_13 Depth=1
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	8(%rax), %rax
	cmpq	$0, (%rax,%rdx,8)
	jne	LBB0_17
LBB0_16:                                ##   in Loop: Header=BB0_13 Depth=1
	movq	_JERR_NO_QUANT_TABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_ERREXIT1
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
LBB0_17:                                ##   in Loop: Header=BB0_13 Depth=1
	movq	8(%r13), %r15
	testq	%r15, %r15
	je	LBB0_23
## %bb.18:                              ##   in Loop: Header=BB0_13 Depth=1
	movq	_DCTSIZE2@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, %eax
	jle	LBB0_23
## %bb.19:                              ##   in Loop: Header=BB0_13 Depth=1
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movq	8(%rcx), %rcx
	movq	(%rcx,%rbx,8), %r14
	xorl	%r12d, %r12d
	jmp	LBB0_20
	.p2align	4, 0x90
LBB0_22:                                ##   in Loop: Header=BB0_20 Depth=2
	incq	%r12
	movslq	%eax, %rcx
	cmpq	%rcx, %r12
	jge	LBB0_23
LBB0_20:                                ##   Parent Loop BB0_13 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	(%r15), %rcx
	movq	(%rcx,%r12,8), %rcx
	movq	(%r14), %rdx
	cmpq	(%rdx,%r12,8), %rcx
	je	LBB0_22
## %bb.21:                              ##   in Loop: Header=BB0_20 Depth=2
	movq	_JERR_MISMATCHED_QUANT_TABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%ebx, %edx
	callq	_ERREXIT1
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	_DCTSIZE2@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_22
LBB0_24:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CSTATE_START,8,3               ## @CSTATE_START
	.comm	_JERR_BAD_STATE,4,2             ## @JERR_BAD_STATE
	.comm	_NUM_QUANT_TBLS,4,2             ## @NUM_QUANT_TBLS
	.comm	_FALSE,4,2                      ## @FALSE
	.comm	_MAX_COMPONENTS,4,2             ## @MAX_COMPONENTS
	.comm	_JERR_COMPONENT_COUNT,4,2       ## @JERR_COMPONENT_COUNT
	.comm	_JERR_NO_QUANT_TABLE,4,2        ## @JERR_NO_QUANT_TABLE
	.comm	_DCTSIZE2,4,2                   ## @DCTSIZE2
	.comm	_JERR_MISMATCHED_QUANT_TABLE,4,2 ## @JERR_MISMATCHED_QUANT_TABLE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_jpeg_copy_critical_parameters  ; -- Begin function jpeg_copy_critical_parameters
	.p2align	2
_jpeg_copy_critical_parameters:         ; @jpeg_copy_critical_parameters
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x1
	str	x0, [sp, #8]                    ; 8-byte Folded Spill
	ldr	x2, [x1]
Lloh0:
	adrp	x8, _CSTATE_START@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CSTATE_START@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x2, x8
	b.eq	LBB0_2
; %bb.1:
Lloh3:
	adrp	x8, _JERR_BAD_STATE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _JERR_BAD_STATE@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x19
                                        ; kill: def $w2 killed $w2 killed $x2
	bl	_ERREXIT1
LBB0_2:
	ldr	x20, [sp, #8]                   ; 8-byte Folded Reload
	ldr	w8, [x20, #40]
	str	w8, [x19, #48]
	ldr	w8, [x20]
	str	w8, [x19, #8]
	ldr	d0, [x20, #32]
	str	d0, [x19, #40]
	mov	x0, x19
	bl	_jpeg_set_defaults
	ldr	w1, [x20, #32]
	mov	x0, x19
	bl	_jpeg_set_colorspace
	ldr	d0, [x20, #24]
	str	d0, [x19, #32]
Lloh6:
	adrp	x8, _NUM_QUANT_TBLS@GOTPAGE
Lloh7:
	ldr	x8, [x8, _NUM_QUANT_TBLS@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	cmp	w8, #1
	b.lt	LBB0_9
; %bb.3:
	mov	x24, #0
Lloh9:
	adrp	x25, _FALSE@GOTPAGE
Lloh10:
	ldr	x25, [x25, _FALSE@GOTPAGEOFF]
	b	LBB0_6
LBB0_4:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	x21, [x0]
	ldr	x22, [x9]
	mov	x0, x21
	bl	_SIZEOF
	mov	x2, x0
	mov	x0, x21
	mov	x1, x22
	bl	_MEMCOPY
	ldr	w8, [x25]
	ldr	x9, [x23, x24, lsl #3]
	str	w8, [x9, #8]
Lloh11:
	adrp	x8, _NUM_QUANT_TBLS@GOTPAGE
Lloh12:
	ldr	x8, [x8, _NUM_QUANT_TBLS@GOTPAGEOFF]
Lloh13:
	ldr	w8, [x8]
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	add	x24, x24, #1
	cmp	x24, w8, sxtw
	b.ge	LBB0_9
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x9, [sp, #8]                    ; 8-byte Folded Reload
	ldr	x9, [x9, #8]
	ldr	x9, [x9, x24, lsl #3]
	cbz	x9, LBB0_5
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	x23, [x19, #24]
	ldr	x0, [x23, x24, lsl #3]
	cbnz	x0, LBB0_4
; %bb.8:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	x0, x19
	bl	_jpeg_alloc_quant_table
	lsl	x8, x24, #3
	str	x0, [x23, x8]
	ldr	x9, [sp, #8]                    ; 8-byte Folded Reload
	ldr	x9, [x9, #8]
	ldr	x9, [x9, x8]
	b	LBB0_4
LBB0_9:
	ldr	x8, [sp, #8]                    ; 8-byte Folded Reload
	ldr	w2, [x8]
	str	w2, [x19, #12]
Lloh14:
	adrp	x8, _MAX_COMPONENTS@GOTPAGE
Lloh15:
	ldr	x8, [x8, _MAX_COMPONENTS@GOTPAGEOFF]
Lloh16:
	ldr	w3, [x8]
	cmp	w2, #1
	ccmp	w2, w3, #0, ge
	b.le	LBB0_11
; %bb.10:
Lloh17:
	adrp	x8, _JERR_COMPONENT_COUNT@GOTPAGE
Lloh18:
	ldr	x8, [x8, _JERR_COMPONENT_COUNT@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_ERREXIT2
	ldr	w8, [x19, #12]
	cmp	w8, #1
	b.lt	LBB0_23
LBB0_11:
	mov	w22, #0
	ldr	x24, [x19, #16]
	ldr	x8, [sp, #8]                    ; 8-byte Folded Reload
	ldr	x25, [x8, #16]
Lloh20:
	adrp	x27, _DCTSIZE2@GOTPAGE
Lloh21:
	ldr	x27, [x27, _DCTSIZE2@GOTPAGEOFF]
Lloh22:
	adrp	x28, _JERR_MISMATCHED_QUANT_TABLE@GOTPAGE
Lloh23:
	ldr	x28, [x28, _JERR_MISMATCHED_QUANT_TABLE@GOTPAGEOFF]
	b	LBB0_13
LBB0_12:                                ;   in Loop: Header=BB0_13 Depth=1
	add	w22, w22, #1
	add	x25, x25, #32
	add	x24, x24, #32
	ldr	w8, [x19, #12]
	cmp	w22, w8
	b.ge	LBB0_23
LBB0_13:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_21 Depth 2
	ldr	w8, [x25, #24]
	str	w8, [x24, #24]
	ldr	d0, [x25, #16]
	str	d0, [x24, #16]
	ldr	w21, [x25]
	str	w21, [x24]
	tbnz	w21, #31, LBB0_16
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
Lloh24:
	adrp	x8, _NUM_QUANT_TBLS@GOTPAGE
Lloh25:
	ldr	x8, [x8, _NUM_QUANT_TBLS@GOTPAGEOFF]
Lloh26:
	ldr	w8, [x8]
	cmp	w21, w8
	b.ge	LBB0_16
; %bb.15:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	x8, [sp, #8]                    ; 8-byte Folded Reload
	ldr	x8, [x8, #8]
	ldr	x8, [x8, x21, lsl #3]
	cbnz	x8, LBB0_17
LBB0_16:                                ;   in Loop: Header=BB0_13 Depth=1
Lloh27:
	adrp	x8, _JERR_NO_QUANT_TABLE@GOTPAGE
Lloh28:
	ldr	x8, [x8, _JERR_NO_QUANT_TABLE@GOTPAGEOFF]
Lloh29:
	ldr	w1, [x8]
	mov	x0, x19
	mov	x2, x21
	bl	_ERREXIT1
LBB0_17:                                ;   in Loop: Header=BB0_13 Depth=1
	ldr	x23, [x25, #8]
	cbz	x23, LBB0_12
; %bb.18:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	w8, [x27]
	cmp	w8, #1
	b.lt	LBB0_12
; %bb.19:                               ;   in Loop: Header=BB0_13 Depth=1
	mov	x26, #0
                                        ; kill: def $w21 killed $w21 killed $x21 def $x21
	sxtw	x21, w21
	ldr	x9, [sp, #8]                    ; 8-byte Folded Reload
	ldr	x9, [x9, #8]
	ldr	x20, [x9, x21, lsl #3]
	b	LBB0_21
LBB0_20:                                ;   in Loop: Header=BB0_21 Depth=2
	add	x26, x26, #1
	cmp	x26, w8, sxtw
	b.ge	LBB0_12
LBB0_21:                                ;   Parent Loop BB0_13 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	x9, [x23]
	lsl	x10, x26, #3
	ldr	x9, [x9, x10]
	ldr	x11, [x20]
	ldr	x10, [x11, x10]
	cmp	x9, x10
	b.eq	LBB0_20
; %bb.22:                               ;   in Loop: Header=BB0_21 Depth=2
	ldr	w1, [x28]
	mov	x0, x19
	mov	x2, x21
	bl	_ERREXIT1
	ldr	w8, [x27]
	b	LBB0_20
LBB0_23:
	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
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.comm	_CSTATE_START,8,3               ; @CSTATE_START
	.comm	_JERR_BAD_STATE,4,2             ; @JERR_BAD_STATE
	.comm	_NUM_QUANT_TBLS,4,2             ; @NUM_QUANT_TBLS
	.comm	_FALSE,4,2                      ; @FALSE
	.comm	_MAX_COMPONENTS,4,2             ; @MAX_COMPONENTS
	.comm	_JERR_COMPONENT_COUNT,4,2       ; @JERR_COMPONENT_COUNT
	.comm	_JERR_NO_QUANT_TABLE,4,2        ; @JERR_NO_QUANT_TABLE
	.comm	_DCTSIZE2,4,2                   ; @DCTSIZE2
	.comm	_JERR_MISMATCHED_QUANT_TABLE,4,2 ; @JERR_MISMATCHED_QUANT_TABLE
.subsections_via_symbols
