	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ExtractAndCropOrScale
_ExtractAndCropOrScale:                 ## @ExtractAndCropOrScale
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	testq	%rdi, %rdi
	je	LBB0_1
## %bb.3:
	movq	%rcx, %r12
	movq	%rdx, %r13
	movq	%rsi, %rbx
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movl	$1, %edi
	callq	_Extract
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movl	$1, %edi
	movq	%rbx, %rsi
	movq	%r13, %rdx
	movq	%r12, %rcx
	callq	_Extract
	movl	%eax, -48(%rbp)                 ## 4-byte Spill
	movl	$7, %edi
	movq	%rbx, %rsi
	movq	%r13, %rdx
	movq	%r12, %rcx
	callq	_Extract
	movl	%eax, %r14d
	movl	$7, %edi
	movq	%rbx, %rsi
	movq	%r13, %rdx
	movq	%r12, %rcx
	callq	_Extract
	movl	%eax, %r15d
	movl	$1, %eax
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_2
## %bb.4:
	incl	%r14d
	incl	%r15d
	cmpl	$0, -48(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_5
## %bb.6:
	movl	$7, %edi
	movq	%rbx, %rsi
	movq	%r13, %rdx
	movq	%r12, %rcx
	callq	_Extract
	incl	%eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movl	$7, %edi
	movq	%rbx, %rsi
	movq	%r13, %rdx
	movq	%r12, %rcx
	callq	_Extract
	movl	%eax, %r12d
	incl	%r12d
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movl	(%rbx), %eax
	cltd
	idivl	%r14d
	movl	$1, %edi
	movl	%eax, %esi
	callq	_max
	movl	%eax, %r14d
	movl	4(%rbx), %eax
	cltd
	idivl	%r15d
	movl	$1, %edi
	movl	%eax, %esi
	callq	_max
	movl	%eax, %r8d
	movl	(%rbx), %eax
	movl	4(%rbx), %ecx
	subl	%r14d, %eax
	cltd
	idivl	-44(%rbp)                       ## 4-byte Folded Reload
	movl	%eax, %esi
	subl	%r8d, %ecx
	movl	%ecx, %eax
	cltd
	idivl	%r12d
	movq	%rbx, %rdi
	movl	%eax, %edx
	movl	%r14d, %ecx
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_WebPPictureCrop                ## TAILCALL
LBB0_1:
	xorl	%eax, %eax
LBB0_2:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_5:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	imull	(%rdi), %r14d
	leal	7(%r14), %esi
	testl	%r14d, %r14d
	cmovnsl	%r14d, %esi
	sarl	$3, %esi
	incl	%esi
	imull	4(%rdi), %r15d
	leal	7(%r15), %edx
	testl	%r15d, %r15d
	cmovnsl	%r15d, %edx
	sarl	$3, %edx
	incl	%edx
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_WebPPictureRescale             ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_ExtractAndCropOrScale
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ExtractAndCropOrScale
_ExtractAndCropOrScale:                 ; @ExtractAndCropOrScale
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	cbz	x0, LBB0_4
; %bb.1:
	mov	x20, x3
	mov	x21, x2
	mov	x22, x1
	mov	x19, x0
	mov	w23, #1
	mov	w0, #1
	bl	_Extract
	mov	x26, x0
	mov	w0, #1
	mov	x1, x22
	mov	x2, x21
	mov	x3, x20
	bl	_Extract
	mov	x24, x0
	mov	w0, #7
	mov	x1, x22
	mov	x2, x21
	mov	x3, x20
	bl	_Extract
	mov	x25, x0
	mov	w0, #7
	mov	x1, x22
	mov	x2, x21
	mov	x3, x20
	bl	_Extract
	cbz	w26, LBB0_5
; %bb.2:
	add	w25, w25, #1
	add	w23, w0, #1
	cbz	w24, LBB0_6
; %bb.3:
	mov	w0, #7
	mov	x1, x22
	mov	x2, x21
	mov	x3, x20
	bl	_Extract
	add	w24, w0, #1
	mov	w0, #7
	mov	x1, x22
	mov	x2, x21
	mov	x3, x20
	bl	_Extract
	add	w21, w0, #1
	ldr	w8, [x19]
	sdiv	w1, w8, w25
	mov	w0, #1
	bl	_max
	mov	x20, x0
	ldr	w8, [x19, #4]
	sdiv	w1, w8, w23
	mov	w0, #1
	bl	_max
	mov	x4, x0
	ldp	w8, w9, [x19]
	sub	w8, w8, w20
	sdiv	w1, w8, w24
	sub	w8, w9, w0
	sdiv	w2, w8, w21
	mov	x0, x19
	mov	x3, x20
	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
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_WebPPictureCrop
LBB0_4:
	mov	w23, #0
LBB0_5:
	mov	x0, x23
	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
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_6:
	ldp	w8, w9, [x19]
	mul	w8, w8, w25
	add	w10, w8, #7
	cmp	w8, #0
	csel	w8, w10, w8, lt
	asr	w8, w8, #3
	add	w1, w8, #1
	mul	w8, w9, w23
	add	w9, w8, #7
	cmp	w8, #0
	csel	w8, w9, w8, lt
	asr	w8, w8, #3
	add	w2, w8, #1
	mov	x0, x19
	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
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_WebPPictureRescale
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_ExtractAndCropOrScale
.subsections_via_symbols
