	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hb_ff_set_sample_fmt           ## -- Begin function hb_ff_set_sample_fmt
	.p2align	4, 0x90
_hb_ff_set_sample_fmt:                  ## @hb_ff_set_sample_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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	testq	%rdi, %rdi
	je	LBB0_18
## %bb.1:
	movq	%rsi, %rbx
	testq	%rsi, %rsi
	je	LBB0_18
## %bb.2:
	movq	(%rbx), %rax
	movq	_AVMEDIA_TYPE_AUDIO@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_18
## %bb.3:
	cmpq	$0, 8(%rbx)
	je	LBB0_18
## %bb.4:
	movl	%edx, %r14d
	movq	%rdi, %r15
	movl	%edx, %edi
	callq	_av_sample_fmt_is_planar
	movl	%r14d, %edi
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	callq	_av_get_packed_sample_fmt
	jmp	LBB0_7
LBB0_6:
	callq	_av_get_planar_sample_fmt
LBB0_7:
	movq	_AV_SAMPLE_FMT_NONE@GOTPCREL(%rip), %rdi
	movl	(%rdi), %edx
	movl	%edx, (%r15)
	movq	8(%rbx), %r8
	movl	(%r8), %esi
	movl	(%rdi), %ecx
	cmpl	%ecx, %esi
	jne	LBB0_9
## %bb.8:
	movl	%esi, %ecx
	jmp	LBB0_15
LBB0_9:
	leaq	4(%r8), %rbx
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_10 Depth=1
	movl	(%rbx), %esi
	addq	$4, %rbx
	cmpl	%ecx, %esi
	je	LBB0_15
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	cmpl	%r14d, %esi
	je	LBB0_11
## %bb.12:                              ##   in Loop: Header=BB0_10 Depth=1
	cmpl	%eax, %esi
	jne	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_10 Depth=1
	movl	%eax, (%r15)
	movl	(%rdi), %ecx
	movl	%eax, %edx
	jmp	LBB0_14
LBB0_11:
	movl	%r14d, (%r15)
	movl	(%rdi), %ecx
	movl	%r14d, %edx
LBB0_15:
	cmpl	%ecx, %edx
	jne	LBB0_17
## %bb.16:
	movl	(%r8), %edx
	movl	%edx, (%r15)
LBB0_17:
	movl	%edx, 4(%r15)
LBB0_18:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AVMEDIA_TYPE_AUDIO,8,3         ## @AVMEDIA_TYPE_AUDIO
	.comm	_AV_SAMPLE_FMT_NONE,4,2         ## @AV_SAMPLE_FMT_NONE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_hb_ff_set_sample_fmt           ; -- Begin function hb_ff_set_sample_fmt
	.p2align	2
_hb_ff_set_sample_fmt:                  ; @hb_ff_set_sample_fmt
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	cbz	x0, LBB0_18
; %bb.1:
	mov	x21, x1
	cbz	x1, LBB0_18
; %bb.2:
	ldr	x8, [x21]
Lloh0:
	adrp	x9, _AVMEDIA_TYPE_AUDIO@GOTPAGE
Lloh1:
	ldr	x9, [x9, _AVMEDIA_TYPE_AUDIO@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_18
; %bb.3:
	ldr	x8, [x21, #8]
	cbz	x8, LBB0_18
; %bb.4:
	mov	x20, x2
	mov	x19, x0
	mov	x0, x2
	bl	_av_sample_fmt_is_planar
	cbz	x0, LBB0_6
; %bb.5:
	mov	x0, x20
	bl	_av_get_packed_sample_fmt
	b	LBB0_7
LBB0_6:
	mov	x0, x20
	bl	_av_get_planar_sample_fmt
LBB0_7:
Lloh3:
	adrp	x10, _AV_SAMPLE_FMT_NONE@GOTPAGE
Lloh4:
	ldr	x10, [x10, _AV_SAMPLE_FMT_NONE@GOTPAGEOFF]
	ldr	w9, [x10]
	str	w9, [x19]
	ldr	x8, [x21, #8]
	ldr	w13, [x8]
	ldr	w11, [x10]
	cmp	w13, w11
	b.ne	LBB0_9
; %bb.8:
	mov	x11, x13
	b	LBB0_15
LBB0_9:
	add	x12, x8, #4
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	ldr	w13, [x12], #4
	cmp	w13, w11
	b.eq	LBB0_15
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	cmp	w13, w20
	b.eq	LBB0_14
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	cmp	w13, w0
	b.ne	LBB0_10
; %bb.13:                               ;   in Loop: Header=BB0_11 Depth=1
	str	w0, [x19]
	ldr	w11, [x10]
	mov	x9, x0
	b	LBB0_10
LBB0_14:
	str	w20, [x19]
	ldr	w11, [x10]
	mov	x9, x20
LBB0_15:
	cmp	w9, w11
	b.ne	LBB0_17
; %bb.16:
	ldr	w9, [x8]
	str	w9, [x19]
LBB0_17:
	str	w9, [x19, #4]
LBB0_18:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_AVMEDIA_TYPE_AUDIO,8,3         ; @AVMEDIA_TYPE_AUDIO
	.comm	_AV_SAMPLE_FMT_NONE,4,2         ; @AV_SAMPLE_FMT_NONE
.subsections_via_symbols
