	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bs_rect                        ## -- Begin function bs_rect
	.p2align	4, 0x90
_bs_rect:                               ## @bs_rect
	.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	%r12
	pushq	%rbx
	subq	$32, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r9d, %r15d
	movl	%r8d, %r14d
	movl	%edi, -48(%rbp)
	movl	%esi, -44(%rbp)
	movl	%edx, -40(%rbp)
	movl	%ecx, -36(%rbp)
	leaq	-48(%rbp), %rdi
	leaq	-44(%rbp), %rsi
	leaq	-40(%rbp), %rdx
	leaq	-36(%rbp), %rcx
	xorl	%r8d, %r8d
	xorl	%r9d, %r9d
	callq	_bs_warp_coords
	testq	%rax, %rax
	je	LBB0_47
## %bb.1:
	testl	%r15d, %r15d
	je	LBB0_2
## %bb.3:
	cmpl	$12, %r15d
	je	LBB0_13
## %bb.4:
	cmpl	$15, %r15d
	jne	LBB0_5
## %bb.12:
	movl	$16777215, %r14d                ## imm = 0xFFFFFF
	jmp	LBB0_13
LBB0_2:
	movl	%r15d, %r14d
LBB0_13:
	movq	_g_Bpp@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	cmpl	$1, %eax
	je	LBB0_21
## %bb.14:
	cmpl	$2, %eax
	jne	LBB0_28
## %bb.15:
	cmpl	$0, -36(%rbp)
	jle	LBB0_47
## %bb.16:
	movd	%r14d, %xmm0
	pshuflw	$0, %xmm0, %xmm0                ## xmm0 = xmm0[0,0,0,0,4,5,6,7]
	pshufd	$0, %xmm0, %xmm0                ## xmm0 = xmm0[0,0,0,0]
	xorl	%ebx, %ebx
	movdqa	%xmm0, -64(%rbp)                ## 16-byte Spill
	jmp	LBB0_17
	.p2align	4, 0x90
LBB0_46:                                ##   in Loop: Header=BB0_17 Depth=1
	incl	%ebx
	cmpl	-36(%rbp), %ebx
	jge	LBB0_47
LBB0_17:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_38 Depth 2
                                        ##     Child Loop BB0_41 Depth 2
                                        ##     Child Loop BB0_45 Depth 2
	movl	-48(%rbp), %edi
	movl	-44(%rbp), %esi
	addl	%ebx, %esi
	callq	_get_bs_ptr
	movdqa	-64(%rbp), %xmm0                ## 16-byte Reload
	testq	%rax, %rax
	je	LBB0_46
## %bb.18:                              ##   in Loop: Header=BB0_17 Depth=1
	movl	-40(%rbp), %ecx
	testl	%ecx, %ecx
	jle	LBB0_46
## %bb.19:                              ##   in Loop: Header=BB0_17 Depth=1
	leal	-1(%rcx), %r9d
	cmpl	$15, %r9d
	jae	LBB0_35
## %bb.20:                              ##   in Loop: Header=BB0_17 Depth=1
	xorl	%r8d, %r8d
	jmp	LBB0_44
LBB0_35:                                ##   in Loop: Header=BB0_17 Depth=1
	incq	%r9
	movq	%r9, %r8
	andq	$-16, %r8
	leaq	-16(%r8), %rsi
	movq	%rsi, %rdi
	shrq	$4, %rdi
	incq	%rdi
	movl	%edi, %edx
	andl	$7, %edx
	cmpq	$112, %rsi
	jae	LBB0_37
## %bb.36:                              ##   in Loop: Header=BB0_17 Depth=1
	xorl	%esi, %esi
	jmp	LBB0_39
LBB0_37:                                ##   in Loop: Header=BB0_17 Depth=1
	andq	$-8, %rdi
	xorl	%esi, %esi
	.p2align	4, 0x90
LBB0_38:                                ##   Parent Loop BB0_17 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movdqu	%xmm0, (%rax,%rsi,2)
	movdqu	%xmm0, 16(%rax,%rsi,2)
	movdqu	%xmm0, 32(%rax,%rsi,2)
	movdqu	%xmm0, 48(%rax,%rsi,2)
	movdqu	%xmm0, 64(%rax,%rsi,2)
	movdqu	%xmm0, 80(%rax,%rsi,2)
	movdqu	%xmm0, 96(%rax,%rsi,2)
	movdqu	%xmm0, 112(%rax,%rsi,2)
	movdqu	%xmm0, 128(%rax,%rsi,2)
	movdqu	%xmm0, 144(%rax,%rsi,2)
	movdqu	%xmm0, 160(%rax,%rsi,2)
	movdqu	%xmm0, 176(%rax,%rsi,2)
	movdqu	%xmm0, 192(%rax,%rsi,2)
	movdqu	%xmm0, 208(%rax,%rsi,2)
	movdqu	%xmm0, 224(%rax,%rsi,2)
	movdqu	%xmm0, 240(%rax,%rsi,2)
	subq	$-128, %rsi
	addq	$-8, %rdi
	jne	LBB0_38
LBB0_39:                                ##   in Loop: Header=BB0_17 Depth=1
	testq	%rdx, %rdx
	je	LBB0_42
## %bb.40:                              ##   in Loop: Header=BB0_17 Depth=1
	leaq	(%rax,%rsi,2), %rsi
	addq	$16, %rsi
	shlq	$5, %rdx
	xorl	%edi, %edi
	.p2align	4, 0x90
LBB0_41:                                ##   Parent Loop BB0_17 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movdqu	%xmm0, -16(%rsi,%rdi)
	movdqu	%xmm0, (%rsi,%rdi)
	addq	$32, %rdi
	cmpq	%rdi, %rdx
	jne	LBB0_41
LBB0_42:                                ##   in Loop: Header=BB0_17 Depth=1
	cmpq	%r8, %r9
	je	LBB0_46
## %bb.43:                              ##   in Loop: Header=BB0_17 Depth=1
	leaq	(%rax,%r8,2), %rax
LBB0_44:                                ##   in Loop: Header=BB0_17 Depth=1
	subl	%r8d, %ecx
	xorl	%edx, %edx
	.p2align	4, 0x90
LBB0_45:                                ##   Parent Loop BB0_17 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movw	%r14w, (%rax,%rdx,2)
	incq	%rdx
	cmpl	%edx, %ecx
	jne	LBB0_45
	jmp	LBB0_46
LBB0_5:
	movl	-36(%rbp), %eax
	testl	%eax, %eax
	jle	LBB0_47
## %bb.6:
	xorl	%r12d, %r12d
	movl	-40(%rbp), %ecx
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_7 Depth=1
	incl	%r12d
	cmpl	%eax, %r12d
	jge	LBB0_47
LBB0_7:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_9 Depth 2
	testl	%ecx, %ecx
	jle	LBB0_11
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_9:                                 ##   Parent Loop BB0_7 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	-48(%rbp), %edi
	addl	%ebx, %edi
	movl	-44(%rbp), %esi
	addl	%r12d, %esi
	movl	%r14d, %edx
	movl	%r15d, %ecx
	xorl	%r8d, %r8d
	callq	_bs_set_pixel
	incl	%ebx
	movl	-40(%rbp), %ecx
	cmpl	%ecx, %ebx
	jl	LBB0_9
## %bb.10:                              ##   in Loop: Header=BB0_7 Depth=1
	movl	-36(%rbp), %eax
	jmp	LBB0_11
LBB0_21:
	cmpl	$0, -36(%rbp)
	jle	LBB0_47
## %bb.22:
	xorl	%ebx, %ebx
	jmp	LBB0_23
	.p2align	4, 0x90
LBB0_27:                                ##   in Loop: Header=BB0_23 Depth=1
	incl	%ebx
	cmpl	-36(%rbp), %ebx
	jge	LBB0_47
LBB0_23:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_26 Depth 2
	movl	-48(%rbp), %edi
	movl	-44(%rbp), %esi
	addl	%ebx, %esi
	callq	_get_bs_ptr
	testq	%rax, %rax
	je	LBB0_27
## %bb.24:                              ##   in Loop: Header=BB0_23 Depth=1
	cmpl	$0, -40(%rbp)
	jle	LBB0_27
## %bb.25:                              ##   in Loop: Header=BB0_23 Depth=1
	xorl	%ecx, %ecx
	.p2align	4, 0x90
LBB0_26:                                ##   Parent Loop BB0_23 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movb	%r14b, (%rax,%rcx)
	incq	%rcx
	cmpl	-40(%rbp), %ecx
	jl	LBB0_26
	jmp	LBB0_27
LBB0_28:
	cmpl	$0, -36(%rbp)
	jle	LBB0_47
## %bb.29:
	xorl	%ebx, %ebx
	jmp	LBB0_30
	.p2align	4, 0x90
LBB0_34:                                ##   in Loop: Header=BB0_30 Depth=1
	incl	%ebx
	cmpl	-36(%rbp), %ebx
	jge	LBB0_47
LBB0_30:                                ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_33 Depth 2
	movl	-48(%rbp), %edi
	movl	-44(%rbp), %esi
	addl	%ebx, %esi
	callq	_get_bs_ptr
	testq	%rax, %rax
	je	LBB0_34
## %bb.31:                              ##   in Loop: Header=BB0_30 Depth=1
	cmpl	$0, -40(%rbp)
	jle	LBB0_34
## %bb.32:                              ##   in Loop: Header=BB0_30 Depth=1
	xorl	%ecx, %ecx
	.p2align	4, 0x90
LBB0_33:                                ##   Parent Loop BB0_30 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	%r14d, (%rax,%rcx,4)
	incq	%rcx
	cmpl	-40(%rbp), %ecx
	jl	LBB0_33
	jmp	LBB0_34
LBB0_47:
	addq	$32, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_g_Bpp,4,2                      ## @g_Bpp
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bs_rect                        ; -- Begin function bs_rect
	.p2align	2
_bs_rect:                               ; @bs_rect
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	mov	x20, x5
	mov	x19, x4
	stp	w1, w0, [sp, #24]
	stp	w3, w2, [sp, #16]
	add	x0, sp, #28
	add	x1, sp, #24
	add	x2, sp, #20
	add	x3, sp, #16
	mov	w4, #0
	mov	w5, #0
	bl	_bs_warp_coords
	cbz	x0, LBB0_39
; %bb.1:
	cbz	w20, LBB0_5
; %bb.2:
	cmp	w20, #12
	b.eq	LBB0_6
; %bb.3:
	cmp	w20, #15
	b.ne	LBB0_20
; %bb.4:
	mov	w19, #16777215
	b	LBB0_6
LBB0_5:
	mov	x19, x20
LBB0_6:
Lloh0:
	adrp	x8, _g_Bpp@GOTPAGE
Lloh1:
	ldr	x8, [x8, _g_Bpp@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, #1
	b.eq	LBB0_27
; %bb.7:
	cmp	w8, #2
	b.ne	LBB0_33
; %bb.8:
	ldr	w8, [sp, #16]
	cmp	w8, #1
	b.lt	LBB0_39
; %bb.9:
	mov	w20, #0
	dup.8h	v0, w19
	str	q0, [sp]                        ; 16-byte Folded Spill
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	add	w20, w20, #1
	ldr	w8, [sp, #16]
	cmp	w20, w8
	b.ge	LBB0_39
LBB0_11:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_16 Depth 2
                                        ;     Child Loop BB0_19 Depth 2
	ldp	w8, w0, [sp, #24]
	add	w1, w8, w20
	bl	_get_bs_ptr
	ldr	q0, [sp]                        ; 16-byte Folded Reload
	cbz	x0, LBB0_10
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	ldr	w8, [sp, #20]
	subs	w9, w8, #1
	b.lt	LBB0_10
; %bb.13:                               ;   in Loop: Header=BB0_11 Depth=1
	cmp	w9, #31
	b.hs	LBB0_15
; %bb.14:                               ;   in Loop: Header=BB0_11 Depth=1
	mov	w10, #0
	mov	x9, x0
	b	LBB0_18
LBB0_15:                                ;   in Loop: Header=BB0_11 Depth=1
	add	x11, x9, #1
	and	x10, x11, #0x1ffffffe0
	add	x9, x0, x10, lsl #1
	add	x12, x0, #32
	mov	x13, x10
LBB0_16:                                ;   Parent Loop BB0_11 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	stp	q0, q0, [x12, #-32]
	stp	q0, q0, [x12], #64
	subs	x13, x13, #32
	b.ne	LBB0_16
; %bb.17:                               ;   in Loop: Header=BB0_11 Depth=1
	cmp	x11, x10
	b.eq	LBB0_10
LBB0_18:                                ;   in Loop: Header=BB0_11 Depth=1
	sub	w8, w8, w10
LBB0_19:                                ;   Parent Loop BB0_11 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	strh	w19, [x9], #2
	subs	w8, w8, #1
	b.ne	LBB0_19
	b	LBB0_10
LBB0_20:
	ldr	w8, [sp, #16]
	cmp	w8, #1
	b.lt	LBB0_39
; %bb.21:
	mov	w21, #0
	ldr	w9, [sp, #20]
	b	LBB0_23
LBB0_22:                                ;   in Loop: Header=BB0_23 Depth=1
	add	w21, w21, #1
	cmp	w21, w8
	b.ge	LBB0_39
LBB0_23:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_25 Depth 2
	cmp	w9, #1
	b.lt	LBB0_22
; %bb.24:                               ;   in Loop: Header=BB0_23 Depth=1
	mov	w22, #0
LBB0_25:                                ;   Parent Loop BB0_23 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w8, [sp, #28]
	add	w0, w22, w8
	ldr	w8, [sp, #24]
	add	w1, w8, w21
	mov	x2, x19
	mov	x3, x20
	mov	w4, #0
	bl	_bs_set_pixel
	add	w22, w22, #1
	ldr	w9, [sp, #20]
	cmp	w22, w9
	b.lt	LBB0_25
; %bb.26:                               ;   in Loop: Header=BB0_23 Depth=1
	ldr	w8, [sp, #16]
	b	LBB0_22
LBB0_27:
	ldr	w8, [sp, #16]
	cmp	w8, #1
	b.lt	LBB0_39
; %bb.28:
	mov	w20, #0
	b	LBB0_30
LBB0_29:                                ;   in Loop: Header=BB0_30 Depth=1
	add	w20, w20, #1
	ldr	w8, [sp, #16]
	cmp	w20, w8
	b.ge	LBB0_39
LBB0_30:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_32 Depth 2
	ldp	w8, w0, [sp, #24]
	add	w1, w8, w20
	bl	_get_bs_ptr
	ldr	w8, [sp, #20]
	cmp	x0, #0
	ccmp	w8, #1, #8, ne
	b.lt	LBB0_29
; %bb.31:                               ;   in Loop: Header=BB0_30 Depth=1
	mov	x8, #0
LBB0_32:                                ;   Parent Loop BB0_30 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	strb	w19, [x0, x8]
	ldr	w9, [sp, #20]
	add	x8, x8, #1
	cmp	w8, w9
	b.lt	LBB0_32
	b	LBB0_29
LBB0_33:
	ldr	w8, [sp, #16]
	cmp	w8, #1
	b.lt	LBB0_39
; %bb.34:
	mov	w20, #0
	b	LBB0_36
LBB0_35:                                ;   in Loop: Header=BB0_36 Depth=1
	add	w20, w20, #1
	ldr	w8, [sp, #16]
	cmp	w20, w8
	b.ge	LBB0_39
LBB0_36:                                ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_38 Depth 2
	ldp	w8, w0, [sp, #24]
	add	w1, w8, w20
	bl	_get_bs_ptr
	ldr	w8, [sp, #20]
	cmp	x0, #0
	ccmp	w8, #1, #8, ne
	b.lt	LBB0_35
; %bb.37:                               ;   in Loop: Header=BB0_36 Depth=1
	mov	x8, #0
LBB0_38:                                ;   Parent Loop BB0_36 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	str	w19, [x0, x8, lsl #2]
	ldr	w9, [sp, #20]
	add	x8, x8, #1
	cmp	w8, w9
	b.lt	LBB0_38
	b	LBB0_35
LBB0_39:
	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
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_g_Bpp,4,2                      ; @g_Bpp
.subsections_via_symbols
