	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hb_read_preview                ## -- Begin function hb_read_preview
	.p2align	4, 0x90
_hb_read_preview:                       ## @hb_read_preview
	.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	$120, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r14d
	movq	%rsi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	callq	_hb_get_instance_id
	movl	8(%rbx), %edx
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
	movl	%r14d, %ecx
	callq	_hb_get_temporary_filename
	movq	%rax, %r14
	leaq	L_.str.1(%rip), %rsi
	movq	%rax, %rdi
	callq	_hb_fopen
	testq	%rax, %rax
	je	LBB0_1
## %bb.4:
	movq	%rax, %r12
	movq	%r14, -152(%rbp)                ## 8-byte Spill
	movq	_AV_PIX_FMT_YUV420P@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%rbx), %edx
	movl	4(%rbx), %esi
	callq	_hb_frame_buffer_init
	movq	%rax, -144(%rbp)                ## 8-byte Spill
	testq	%rax, %rax
	je	LBB0_25
## %bb.5:
	movq	-144(%rbp), %rax                ## 8-byte Reload
	movq	(%rax), %rax
	movl	8(%rax), %ecx
	movl	%ecx, -132(%rbp)                ## 4-byte Spill
	testl	%ecx, %ecx
	jle	LBB0_14
## %bb.6:
	movl	4(%rax), %r13d
	movslq	(%rax), %r15
	movq	16(%rax), %r14
	shlq	$2, %r15
	xorl	%ebx, %ebx
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_7 Depth=1
	incl	%ebx
	addq	%r15, %r14
	cmpl	%ebx, -132(%rbp)                ## 4-byte Folded Reload
	je	LBB0_13
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movl	%r13d, %esi
	movl	$1, %edx
	movq	%r12, %rcx
	callq	_fread
	cmpl	%r13d, %eax
	jge	LBB0_12
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movq	%r12, %rdi
	callq	_ferror
	testq	%rax, %rax
	je	LBB0_12
	jmp	LBB0_9
LBB0_1:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-128(%rbp), %rsi
	movl	$79, %edx
	callq	_strerror_r
	testq	%rax, %rax
	je	LBB0_3
## %bb.2:
	leaq	L_.str.2(%rip), %rsi
	leaq	-128(%rbp), %rdi
	callq	_strcpy
LBB0_3:
	leaq	L_.str.3(%rip), %rdi
	xorl	%ebx, %ebx
	leaq	-128(%rbp), %rdx
	movq	%r14, %rsi
	xorl	%eax, %eax
	callq	_hb_error
	movq	%r14, %rdi
	callq	_free
	jmp	LBB0_26
LBB0_13:
	movq	-144(%rbp), %rax                ## 8-byte Reload
	movq	(%rax), %rax
LBB0_14:
	movl	32(%rax), %ecx
	movl	%ecx, -132(%rbp)                ## 4-byte Spill
	testl	%ecx, %ecx
	jle	LBB0_20
## %bb.15:
	movl	28(%rax), %r13d
	movslq	24(%rax), %r15
	movq	40(%rax), %r14
	shlq	$2, %r15
	xorl	%ebx, %ebx
	jmp	LBB0_16
	.p2align	4, 0x90
LBB0_18:                                ##   in Loop: Header=BB0_16 Depth=1
	incl	%ebx
	addq	%r15, %r14
	cmpl	%ebx, -132(%rbp)                ## 4-byte Folded Reload
	je	LBB0_19
LBB0_16:                                ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movl	%r13d, %esi
	movl	$1, %edx
	movq	%r12, %rcx
	callq	_fread
	cmpl	%r13d, %eax
	jge	LBB0_18
## %bb.17:                              ##   in Loop: Header=BB0_16 Depth=1
	movq	%r12, %rdi
	callq	_ferror
	testq	%rax, %rax
	je	LBB0_18
	jmp	LBB0_9
LBB0_19:
	movq	-144(%rbp), %rax                ## 8-byte Reload
	movq	(%rax), %rax
LBB0_20:
	movl	56(%rax), %ecx
	movl	%ecx, -132(%rbp)                ## 4-byte Spill
	testl	%ecx, %ecx
	jle	LBB0_25
## %bb.21:
	movl	52(%rax), %r13d
	movslq	48(%rax), %r15
	movq	64(%rax), %r14
	shlq	$2, %r15
	xorl	%ebx, %ebx
	jmp	LBB0_22
	.p2align	4, 0x90
LBB0_24:                                ##   in Loop: Header=BB0_22 Depth=1
	incl	%ebx
	addq	%r15, %r14
	cmpl	%ebx, -132(%rbp)                ## 4-byte Folded Reload
	je	LBB0_25
LBB0_22:                                ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	movl	%r13d, %esi
	movl	$1, %edx
	movq	%r12, %rcx
	callq	_fread
	cmpl	%r13d, %eax
	jge	LBB0_24
## %bb.23:                              ##   in Loop: Header=BB0_22 Depth=1
	movq	%r12, %rdi
	callq	_ferror
	testq	%rax, %rax
	je	LBB0_24
LBB0_9:
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-128(%rbp), %rsi
	movl	$79, %edx
	callq	_strerror_r
	testq	%rax, %rax
	movq	-152(%rbp), %r14                ## 8-byte Reload
	je	LBB0_11
## %bb.10:
	leaq	L_.str.2(%rip), %rsi
	leaq	-128(%rbp), %rdi
	callq	_strcpy
LBB0_11:
	leaq	L_.str.4(%rip), %rdi
	leaq	-128(%rbp), %rcx
	movl	%ebx, %esi
	movq	%r14, %rdx
	xorl	%eax, %eax
	callq	_hb_error
LBB0_25:
	movq	-152(%rbp), %rdi                ## 8-byte Reload
	callq	_free
	movq	%r12, %rdi
	callq	_fclose
	movq	-144(%rbp), %rbx                ## 8-byte Reload
LBB0_26:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_28
## %bb.27:
	movq	%rbx, %rax
	addq	$120, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_28:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%d_%d_%d"

L_.str.1:                               ## @.str.1
	.asciz	"rb"

	.comm	_errno,4,2                      ## @errno
L_.str.2:                               ## @.str.2
	.asciz	"unknown -- strerror_r() failed"

L_.str.3:                               ## @.str.3
	.asciz	"hb_read_preview: Failed to open %s (reason: %s)"

	.comm	_AV_PIX_FMT_YUV420P,4,2         ## @AV_PIX_FMT_YUV420P
L_.str.4:                               ## @.str.4
	.asciz	"hb_read_preview: Failed to read line %d from %s (reason: %s). Preview will be incomplete."

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hb_read_preview                ; -- Begin function hb_read_preview
	.p2align	2
_hb_read_preview:                       ; @hb_read_preview
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #192
	.cfi_def_cfa_offset 192
	stp	x26, x25, [sp, #112]            ; 16-byte Folded Spill
	stp	x24, x23, [sp, #128]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #144]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #160]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #176]            ; 16-byte Folded Spill
	add	x29, sp, #176
	.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
	mov	x19, x2
	mov	x21, x1
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-72]
	bl	_hb_get_instance_id
	mov	x1, x0
	ldr	w2, [x21, #8]
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	mov	x3, x19
	bl	_hb_get_temporary_filename
	mov	x19, x0
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_hb_fopen
	cbz	x0, LBB0_7
; %bb.1:
	mov	x20, x0
Lloh7:
	adrp	x8, _AV_PIX_FMT_YUV420P@GOTPAGE
Lloh8:
	ldr	x8, [x8, _AV_PIX_FMT_YUV420P@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
	ldp	w2, w1, [x21]
	bl	_hb_frame_buffer_init
	mov	x21, x0
	cbz	x0, LBB0_25
; %bb.2:
	ldr	x8, [x21]
	ldr	w25, [x8, #8]
	cmp	w25, #1
	b.lt	LBB0_11
; %bb.3:
	mov	w24, #0
	ldp	w9, w22, [x8]
                                        ; kill: def $w9 killed $w9 def $x9
	sxtw	x9, w9
	ldr	x23, [x8, #16]
	lsl	x26, x9, #2
	b	LBB0_5
LBB0_4:                                 ;   in Loop: Header=BB0_5 Depth=1
	add	w24, w24, #1
	add	x23, x23, x26
	cmp	w25, w24
	b.eq	LBB0_10
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x23
	mov	x1, x22
	mov	w2, #1
	mov	x3, x20
	bl	_fread
	cmp	w0, w22
	b.ge	LBB0_4
; %bb.6:                                ;   in Loop: Header=BB0_5 Depth=1
	mov	x0, x20
	bl	_ferror
	cbz	x0, LBB0_4
	b	LBB0_22
LBB0_7:
Lloh10:
	adrp	x8, _errno@GOTPAGE
Lloh11:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh12:
	ldr	w0, [x8]
	add	x20, sp, #24
	add	x1, sp, #24
	mov	w2, #79
	bl	_strerror_r
	cbz	x0, LBB0_9
; %bb.8:
Lloh13:
	adrp	x1, l_.str.2@PAGE
Lloh14:
	add	x1, x1, l_.str.2@PAGEOFF
	add	x0, sp, #24
	bl	_strcpy
LBB0_9:
	stp	x19, x20, [sp]
Lloh15:
	adrp	x0, l_.str.3@PAGE
Lloh16:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_hb_error
	mov	x0, x19
	bl	_free
	mov	x21, #0
	b	LBB0_26
LBB0_10:
	ldr	x8, [x21]
LBB0_11:
	ldr	w25, [x8, #32]
	cmp	w25, #1
	b.lt	LBB0_17
; %bb.12:
	mov	w24, #0
	ldp	w9, w22, [x8, #24]
                                        ; kill: def $w9 killed $w9 def $x9
	sxtw	x9, w9
	ldr	x23, [x8, #40]
	lsl	x26, x9, #2
	b	LBB0_14
LBB0_13:                                ;   in Loop: Header=BB0_14 Depth=1
	add	w24, w24, #1
	add	x23, x23, x26
	cmp	w25, w24
	b.eq	LBB0_16
LBB0_14:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x23
	mov	x1, x22
	mov	w2, #1
	mov	x3, x20
	bl	_fread
	cmp	w0, w22
	b.ge	LBB0_13
; %bb.15:                               ;   in Loop: Header=BB0_14 Depth=1
	mov	x0, x20
	bl	_ferror
	cbz	x0, LBB0_13
	b	LBB0_22
LBB0_16:
	ldr	x8, [x21]
LBB0_17:
	ldr	w25, [x8, #56]
	cmp	w25, #1
	b.lt	LBB0_25
; %bb.18:
	mov	w24, #0
	ldp	w9, w22, [x8, #48]
                                        ; kill: def $w9 killed $w9 def $x9
	sxtw	x9, w9
	ldr	x23, [x8, #64]
	lsl	x26, x9, #2
	b	LBB0_20
LBB0_19:                                ;   in Loop: Header=BB0_20 Depth=1
	add	w24, w24, #1
	add	x23, x23, x26
	cmp	w25, w24
	b.eq	LBB0_25
LBB0_20:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x23
	mov	x1, x22
	mov	w2, #1
	mov	x3, x20
	bl	_fread
	cmp	w0, w22
	b.ge	LBB0_19
; %bb.21:                               ;   in Loop: Header=BB0_20 Depth=1
	mov	x0, x20
	bl	_ferror
	cbz	x0, LBB0_19
LBB0_22:
Lloh17:
	adrp	x8, _errno@GOTPAGE
Lloh18:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh19:
	ldr	w0, [x8]
	add	x22, sp, #24
	add	x1, sp, #24
	mov	w2, #79
	bl	_strerror_r
	cbz	x0, LBB0_24
; %bb.23:
Lloh20:
	adrp	x1, l_.str.2@PAGE
Lloh21:
	add	x1, x1, l_.str.2@PAGEOFF
	add	x0, sp, #24
	bl	_strcpy
LBB0_24:
	stp	x19, x22, [sp, #8]
	str	x24, [sp]
Lloh22:
	adrp	x0, l_.str.4@PAGE
Lloh23:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_hb_error
LBB0_25:
	mov	x0, x19
	bl	_free
	mov	x0, x20
	bl	_fclose
LBB0_26:
	ldur	x8, [x29, #-72]
Lloh24:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh25:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh26:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_28
; %bb.27:
	mov	x0, x21
	ldp	x29, x30, [sp, #176]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #160]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #144]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #128]            ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #112]            ; 16-byte Folded Reload
	add	sp, sp, #192
	ret
LBB0_28:
	bl	___stack_chk_fail
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%d_%d_%d"

l_.str.1:                               ; @.str.1
	.asciz	"rb"

	.comm	_errno,4,2                      ; @errno
l_.str.2:                               ; @.str.2
	.asciz	"unknown -- strerror_r() failed"

l_.str.3:                               ; @.str.3
	.asciz	"hb_read_preview: Failed to open %s (reason: %s)"

	.comm	_AV_PIX_FMT_YUV420P,4,2         ; @AV_PIX_FMT_YUV420P
l_.str.4:                               ; @.str.4
	.asciz	"hb_read_preview: Failed to read line %d from %s (reason: %s). Preview will be incomplete."

.subsections_via_symbols
