	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function add_rect_clamped_c
_add_rect_clamped_c:                    ## @add_rect_clamped_c
	.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
	cmpl	$0, 16(%rbp)
	jle	LBB0_6
## %bb.1:
	movl	%r9d, %r14d
	movq	%rcx, %r15
	movq	%rsi, %r12
	movq	%rdi, %rbx
	movslq	%edx, %rax
	movslq	%r8d, %rcx
	shlq	$2, %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	shlq	$3, %rcx
	movq	%rcx, -48(%rbp)                 ## 8-byte Spill
	xorl	%ecx, %ecx
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	incl	%ecx
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	addq	%rax, %rbx
	addq	-48(%rbp), %r15                 ## 8-byte Folded Reload
	addq	%rax, %r12
	cmpl	16(%rbp), %ecx
	je	LBB0_6
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_4 Depth 2
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	testl	%r14d, %r14d
	jle	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	xorl	%r13d, %r13d
	.p2align	4, 0x90
LBB0_4:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%r12,%r13,4), %eax
	addl	$32, %eax
	sarl	$6, %eax
	movslq	%eax, %rdi
	addq	(%r15,%r13,8), %rdi
	callq	_av_clip_uint8
	movl	%eax, (%rbx,%r13,4)
	movl	4(%r12,%r13,4), %eax
	addl	$32, %eax
	sarl	$6, %eax
	movslq	%eax, %rdi
	addq	8(%r15,%r13,8), %rdi
	callq	_av_clip_uint8
	movl	%eax, 4(%rbx,%r13,4)
	addq	$2, %r13
	cmpl	%r14d, %r13d
	jl	LBB0_4
	jmp	LBB0_5
LBB0_6:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_add_rect_clamped_c
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function add_rect_clamped_c
_add_rect_clamped_c:                    ; @add_rect_clamped_c
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
                                        ; kill: def $w4 killed $w4 def $x4
                                        ; kill: def $w2 killed $w2 def $x2
	str	w6, [sp, #28]                   ; 4-byte Folded Spill
	cmp	w6, #1
	b.lt	LBB0_6
; %bb.1:
	mov	x20, x5
	mov	x21, x1
	mov	x22, x0
	mov	w23, #0
	add	x19, x3, #8
	sbfiz	x9, x4, #3, #32
	sbfiz	x8, x2, #2, #32
	stp	x8, x9, [sp, #8]                ; 16-byte Folded Spill
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	w23, w23, #1
	ldr	x8, [sp, #16]                   ; 8-byte Folded Reload
	add	x19, x19, x8
	ldr	x8, [sp, #8]                    ; 8-byte Folded Reload
	add	x21, x21, x8
	add	x22, x22, x8
	ldr	w8, [sp, #28]                   ; 4-byte Folded Reload
	cmp	w23, w8
	b.eq	LBB0_6
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_5 Depth 2
	cmp	w20, #1
	b.lt	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x27, #0
	mov	w28, #0
	mov	x24, x19
LBB0_5:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	add	x25, x21, x27
	ldr	w8, [x25]
	add	w8, w8, #32
	asr	w8, w8, #6
	ldur	x9, [x24, #-8]
	add	x0, x9, w8, sxtw
	bl	_av_clip_uint8
	add	x26, x22, x27
	str	w0, [x26]
	ldr	w8, [x25, #4]
	add	w8, w8, #32
	asr	w8, w8, #6
	ldr	x9, [x24], #16
	add	x0, x9, w8, sxtw
	bl	_av_clip_uint8
	str	w0, [x26, #4]
	add	w28, w28, #2
	add	x27, x27, #8
	cmp	w28, w20
	b.lt	LBB0_5
	b	LBB0_2
LBB0_6:
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_add_rect_clamped_c
.subsections_via_symbols
