	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function try_fmt
LCPI0_0:
	.quad	1                               ## 0x1
	.quad	1                               ## 0x1
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_try_fmt:                               ## @try_fmt
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
                                        ## kill: def $edx killed $edx def $rdx
	movq	(%rsi), %rax
	movl	(%rax), %r12d
	sarl	%edx
	cmpl	%edx, %r12d
	jge	LBB0_1
## %bb.2:
	movq	%rsi, %r14
	movq	%rdi, %rbx
	leal	-1(%rdx), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movl	16(%rsi), %r15d
	addl	12(%rsi), %r15d
	sarl	%r15d
	xorl	%edi, %edi
	cmpl	%r15d, %edx
	setg	%dil
	callq	_BUG_ON
	movl	8(%r14), %eax
	movl	%eax, 44(%rbx)
	movq	_VBI_BPL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 40(%rbx)
	movq	_V4L2_PIX_FMT_GREY@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 36(%rbx)
	movq	_VBI_OFFSET@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 32(%rbx)
	movq	(%r14), %rax
	movl	4(%rax), %r13d
	movq	(%rbx), %rdx
	subl	(%rax), %r13d
	cmpq	$0, (%rdx)
	je	LBB0_3
## %bb.4:
	movq	8(%rbx), %rax
	movl	(%rax), %edi
	movl	%r12d, %esi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	callq	_clamp
	movq	(%rbx), %rcx
	movq	8(%rbx), %rdx
	movl	(%rdx), %edi
	subl	%eax, %edi
	addl	(%rcx), %edi
	movl	%eax, (%rdx)
	movl	%r15d, %edx
	subl	%eax, %edx
	movl	$1, %esi
	callq	_clamp
	movq	(%rbx), %rdx
	movq	%rax, (%rdx)
	cmpq	$0, 8(%rdx)
	je	LBB0_6
LBB0_7:
	addl	%r13d, %r15d
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	addl	%r13d, %edx
	addl	%r13d, %r12d
	movq	8(%rbx), %rax
	movl	4(%rax), %edi
	movl	%r12d, %esi
	callq	_clamp
	movq	(%rbx), %rcx
	movq	8(%rbx), %rdx
	movl	4(%rdx), %edi
	subl	%eax, %edi
	addl	8(%rcx), %edi
	movl	%eax, 4(%rdx)
	subl	%eax, %r15d
	movl	$1, %esi
	movl	%r15d, %edx
	callq	_clamp
	movq	%rax, %rcx
	movq	(%rbx), %rdx
	movq	%rax, 8(%rdx)
	movq	(%rdx), %rax
	orq	%rax, %rcx
	jne	LBB0_10
LBB0_9:
	movq	(%r14), %rax
	movl	(%rax), %ecx
	movq	8(%rbx), %rsi
	movl	%ecx, (%rsi)
	movl	4(%rax), %eax
	movl	%eax, 4(%rsi)
	movaps	LCPI0_0(%rip), %xmm0            ## xmm0 = [1,1]
	movups	%xmm0, (%rdx)
LBB0_10:
	movq	$0, 24(%rbx)
	movq	16(%rbx), %rax
	xorps	%xmm0, %xmm0
	movups	%xmm0, (%rax)
	xorl	%eax, %eax
	jmp	LBB0_11
LBB0_1:
	movq	_EBUSY@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_11:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	xorl	%eax, %eax
	cmpq	$0, 8(%rdx)
	jne	LBB0_7
LBB0_6:
	xorl	%ecx, %ecx
	orq	%rax, %rcx
	jne	LBB0_10
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_VBI_BPL,4,2                    ## @VBI_BPL
	.comm	_V4L2_PIX_FMT_GREY,4,2          ## @V4L2_PIX_FMT_GREY
	.comm	_VBI_OFFSET,4,2                 ## @VBI_OFFSET
	.no_dead_strip	_try_fmt
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function try_fmt
_try_fmt:                               ; @try_fmt
	.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
	ldr	x8, [x1]
	ldr	w21, [x8]
	asr	w8, w2, #1
	cmp	w21, w8
	b.ge	LBB0_7
; %bb.1:
	mov	x20, x1
	mov	x19, x0
	sub	w22, w8, #1
	ldp	w9, w10, [x1, #12]
	add	w9, w10, w9
	asr	w23, w9, #1
	cmp	w8, w23
	cset	w0, gt
	bl	_BUG_ON
	ldr	w8, [x20, #8]
Lloh0:
	adrp	x9, _VBI_BPL@GOTPAGE
Lloh1:
	ldr	x9, [x9, _VBI_BPL@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
Lloh3:
	adrp	x10, _V4L2_PIX_FMT_GREY@GOTPAGE
Lloh4:
	ldr	x10, [x10, _V4L2_PIX_FMT_GREY@GOTPAGEOFF]
	stp	w9, w8, [x19, #40]
Lloh5:
	ldr	w8, [x10]
Lloh6:
	adrp	x9, _VBI_OFFSET@GOTPAGE
Lloh7:
	ldr	x9, [x9, _VBI_OFFSET@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	stp	w9, w8, [x19, #32]
	ldr	x8, [x20]
	ldp	w25, w24, [x8]
	ldr	x9, [x19]
	ldr	x8, [x9]
	cbz	x8, LBB0_9
; %bb.2:
	ldr	x8, [x19, #8]
	ldr	w0, [x8]
	mov	x1, x21
	mov	x2, x22
	bl	_clamp
	ldp	x8, x9, [x19]
	ldr	w10, [x9]
	ldr	w8, [x8]
	sub	w10, w10, w0
	add	w8, w10, w8
	str	w0, [x9]
	sub	w2, w23, w0
	mov	x0, x8
	mov	w1, #1
	bl	_clamp
	ldr	x9, [x19]
	str	x0, [x9]
	ldr	x8, [x9, #8]
	cbz	x8, LBB0_4
LBB0_3:
	sub	w8, w24, w25
	add	w23, w23, w8
	add	w2, w22, w8
	add	w1, w21, w8
	ldr	x8, [x19, #8]
	ldr	w0, [x8, #4]
	bl	_clamp
	ldp	x8, x9, [x19]
	ldr	w10, [x9, #4]
	ldr	w8, [x8, #8]
	sub	w10, w10, w0
	add	w8, w10, w8
	str	w0, [x9, #4]
	sub	w2, w23, w0
	mov	x0, x8
	mov	w1, #1
	bl	_clamp
	mov	x8, x0
	ldr	x9, [x19]
	str	x0, [x9, #8]
	ldr	x0, [x9]
LBB0_4:
	orr	x8, x8, x0
	cbnz	x8, LBB0_6
; %bb.5:
	ldr	x8, [x20]
	ldr	w10, [x8]
	ldr	x11, [x19, #8]
	str	w10, [x11]
	ldr	w8, [x8, #4]
	str	w8, [x11, #4]
	mov	w8, #1
	dup.2d	v0, x8
	str	q0, [x9]
LBB0_6:
	mov	w0, #0
	str	xzr, [x19, #24]
	ldr	x8, [x19, #16]
	stp	xzr, xzr, [x8]
	b	LBB0_8
LBB0_7:
Lloh9:
	adrp	x8, _EBUSY@GOTPAGE
Lloh10:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_8:
	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_9:
	mov	x0, #0
	ldr	x8, [x9, #8]
	cbnz	x8, LBB0_3
	b	LBB0_4
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_VBI_BPL,4,2                    ; @VBI_BPL
	.comm	_V4L2_PIX_FMT_GREY,4,2          ; @V4L2_PIX_FMT_GREY
	.comm	_VBI_OFFSET,4,2                 ; @VBI_OFFSET
	.no_dead_strip	_try_fmt
.subsections_via_symbols
