	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function R_PshadowSurface
LCPI0_0:
	.long	0x80000000                      ## float -0
	.long	0x80000000                      ## float -0
	.long	0x80000000                      ## float -0
	.long	0x80000000                      ## float -0
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_R_PshadowSurface:                      ## @R_PshadowSurface
	.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
	movl	%esi, %r15d
	movq	%rdi, %r8
	movl	8(%rdi), %ecx
	movq	_CULLINFO_PLANE@GOTPCREL(%rip), %rdx
	movq	_tr@GOTPCREL(%rip), %r14
	movl	(%r14), %eax
	testl	%ecx, (%rdx)
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	je	LBB0_10
## %bb.1:
	testl	%eax, %eax
	jle	LBB0_10
## %bb.2:
	movl	$8, %r12d
	xorl	%ebx, %ebx
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_3 Depth=1
	notl	%r13d
	andl	%r13d, %r15d
LBB0_7:                                 ##   in Loop: Header=BB0_3 Depth=1
	movq	_tr@GOTPCREL(%rip), %r14
LBB0_8:                                 ##   in Loop: Header=BB0_3 Depth=1
	incq	%rbx
	movslq	(%r14), %rax
	addq	$32, %r12
	cmpq	%rax, %rbx
	jge	LBB0_9
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movl	$1, %r13d
	movl	%ebx, %ecx
	shll	%cl, %r13d
	btl	%ebx, %r15d
	jae	LBB0_8
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	8(%r14), %r14
	movq	-8(%r14,%r12), %rdi
	movl	40(%r8), %esi
	callq	_DotProduct
	movq	-48(%rbp), %r8                  ## 8-byte Reload
	subss	36(%r8), %xmm0
	movss	(%r14,%r12), %xmm1              ## xmm1 = mem[0],zero,zero,zero
	movaps	%xmm1, %xmm2
	xorps	LCPI0_0(%rip), %xmm2
	ucomiss	%xmm0, %xmm2
	ja	LBB0_6
## %bb.5:                               ##   in Loop: Header=BB0_3 Depth=1
	ucomiss	%xmm1, %xmm0
	jbe	LBB0_7
	jmp	LBB0_6
LBB0_9:
	movl	8(%r8), %ecx
LBB0_10:
	movq	_CULLINFO_BOX@GOTPCREL(%rip), %rdx
	testl	%ecx, (%rdx)
	je	LBB0_24
## %bb.11:
	testl	%eax, %eax
	jle	LBB0_24
## %bb.12:
	movl	$12, %r13d
	xorl	%ebx, %ebx
	jmp	LBB0_13
	.p2align	4, 0x90
LBB0_21:                                ##   in Loop: Header=BB0_13 Depth=1
	notl	%r12d
	andl	%r12d, %r15d
LBB0_22:                                ##   in Loop: Header=BB0_13 Depth=1
	incq	%rbx
	movslq	(%r14), %rax
	addq	$32, %r13
	cmpq	%rax, %rbx
	jge	LBB0_23
LBB0_13:                                ## =>This Inner Loop Header: Depth=1
	movl	$1, %r12d
	movl	%ebx, %ecx
	shll	%cl, %r12d
	btl	%ebx, %r15d
	jae	LBB0_22
## %bb.14:                              ##   in Loop: Header=BB0_13 Depth=1
	movq	8(%r14), %rdx
	movq	-12(%rdx,%r13), %rax
	movss	(%rax), %xmm1                   ## xmm1 = mem[0],zero,zero,zero
	movss	-4(%rdx,%r13), %xmm0            ## xmm0 = mem[0],zero,zero,zero
	movaps	%xmm1, %xmm2
	subss	%xmm0, %xmm2
	movq	16(%r8), %rcx
	movq	8(%rcx), %rsi
	ucomiss	(%rsi), %xmm2
	ja	LBB0_21
## %bb.15:                              ##   in Loop: Header=BB0_13 Depth=1
	addss	%xmm0, %xmm1
	movq	(%rcx), %rdi
	movss	(%rdi), %xmm2                   ## xmm2 = mem[0],zero,zero,zero
	ucomiss	%xmm1, %xmm2
	ja	LBB0_21
## %bb.16:                              ##   in Loop: Header=BB0_13 Depth=1
	movss	4(%rax), %xmm1                  ## xmm1 = mem[0],zero,zero,zero
	movaps	%xmm1, %xmm2
	subss	%xmm0, %xmm2
	ucomiss	4(%rsi), %xmm2
	ja	LBB0_21
## %bb.17:                              ##   in Loop: Header=BB0_13 Depth=1
	addss	%xmm0, %xmm1
	movss	4(%rdi), %xmm2                  ## xmm2 = mem[0],zero,zero,zero
	ucomiss	%xmm1, %xmm2
	ja	LBB0_21
## %bb.18:                              ##   in Loop: Header=BB0_13 Depth=1
	movss	8(%rax), %xmm1                  ## xmm1 = mem[0],zero,zero,zero
	movaps	%xmm1, %xmm2
	subss	%xmm0, %xmm2
	ucomiss	8(%rsi), %xmm2
	ja	LBB0_21
## %bb.19:                              ##   in Loop: Header=BB0_13 Depth=1
	addss	%xmm1, %xmm0
	movss	8(%rdi), %xmm1                  ## xmm1 = mem[0],zero,zero,zero
	ucomiss	%xmm0, %xmm1
	ja	LBB0_21
## %bb.20:                              ##   in Loop: Header=BB0_13 Depth=1
	addq	%r13, %rdx
	callq	_BoxOnPlaneSide
	movq	-48(%rbp), %r8                  ## 8-byte Reload
	cmpl	$2, %eax
	je	LBB0_21
	jmp	LBB0_22
LBB0_23:
	movl	8(%r8), %ecx
LBB0_24:
	movq	_CULLINFO_SPHERE@GOTPCREL(%rip), %rdx
	testl	%ecx, (%rdx)
	je	LBB0_33
## %bb.25:
	testl	%eax, %eax
	jle	LBB0_33
## %bb.26:
	movl	$24, %r13d
	xorl	%ebx, %ebx
	jmp	LBB0_27
	.p2align	4, 0x90
LBB0_30:                                ##   in Loop: Header=BB0_27 Depth=1
	notl	%r12d
	andl	%r12d, %r15d
LBB0_31:                                ##   in Loop: Header=BB0_27 Depth=1
	movq	_tr@GOTPCREL(%rip), %r14
LBB0_32:                                ##   in Loop: Header=BB0_27 Depth=1
	incq	%rbx
	movslq	(%r14), %rax
	addq	$32, %r13
	cmpq	%rax, %rbx
	jge	LBB0_33
LBB0_27:                                ## =>This Inner Loop Header: Depth=1
	movl	$1, %r12d
	movl	%ebx, %ecx
	shll	%cl, %r12d
	btl	%ebx, %r15d
	jae	LBB0_32
## %bb.28:                              ##   in Loop: Header=BB0_27 Depth=1
	movq	8(%r14), %r14
	movl	-4(%r14,%r13), %esi
	movl	(%r14,%r13), %edi
	movq	24(%r8), %rdx
	movss	32(%r8), %xmm0                  ## xmm0 = mem[0],zero,zero,zero
	callq	_SpheresIntersect
	movq	-48(%rbp), %r8                  ## 8-byte Reload
	testl	%eax, %eax
	je	LBB0_30
## %bb.29:                              ##   in Loop: Header=BB0_27 Depth=1
	movq	24(%r8), %rdi
	movl	-8(%r14,%r13), %esi
	callq	_DotProduct
	movq	-48(%rbp), %r8                  ## 8-byte Reload
	subss	-12(%r14,%r13), %xmm0
	movss	32(%r8), %xmm1                  ## xmm1 = mem[0],zero,zero,zero
	xorps	LCPI0_0(%rip), %xmm1
	ucomiss	%xmm0, %xmm1
	ja	LBB0_30
	jmp	LBB0_31
LBB0_33:
	movq	(%r8), %rcx
	movl	(%rcx), %edx
	addl	$-128, %edx
	xorl	%eax, %eax
	cmpl	$2, %edx
	ja	LBB0_35
## %bb.34:
	movl	%r15d, (%rcx)
	movl	%r15d, %eax
LBB0_35:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_CULLINFO_PLANE,4,2             ## @CULLINFO_PLANE
	.comm	_tr,16,3                        ## @tr
	.comm	_CULLINFO_BOX,4,2               ## @CULLINFO_BOX
	.comm	_CULLINFO_SPHERE,4,2            ## @CULLINFO_SPHERE
	.no_dead_strip	_R_PshadowSurface
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function R_PshadowSurface
_R_PshadowSurface:                      ; @R_PshadowSurface
	.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
	mov	x19, x1
	mov	x20, x0
	ldr	w9, [x0, #8]
Lloh0:
	adrp	x8, _CULLINFO_PLANE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _CULLINFO_PLANE@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	and	w10, w8, w9
Lloh3:
	adrp	x21, _tr@GOTPAGE
Lloh4:
	ldr	x21, [x21, _tr@GOTPAGEOFF]
	ldr	w8, [x21]
	cmp	w10, #0
	ccmp	w8, #1, #8, ne
	b.lt	LBB0_7
; %bb.1:
	mov	x22, #0
	mov	x23, #0
	mov	w24, #1
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x23, x23, #1
	ldrsw	x8, [x21]
	add	x22, x22, #32
	cmp	x23, x8
	b.ge	LBB0_6
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	lsl	w25, w24, w23
	tst	w25, w19
	b.eq	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [x21, #8]
	add	x26, x8, x22
	ldr	x0, [x26]
	ldr	w1, [x20, #40]
	bl	_DotProduct
	ldr	s1, [x20, #36]
	fsub	s0, s0, s1
	ldr	s1, [x26, #8]
	fneg	s2, s1
	fcmp	s0, s2
	fccmp	s0, s1, #0, pl
	b.le	LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	bic	w19, w19, w25
	b	LBB0_2
LBB0_6:
	ldr	w9, [x20, #8]
LBB0_7:
Lloh5:
	adrp	x10, _CULLINFO_BOX@GOTPAGE
Lloh6:
	ldr	x10, [x10, _CULLINFO_BOX@GOTPAGEOFF]
Lloh7:
	ldr	w10, [x10]
	and	w10, w10, w9
	cmp	w10, #0
	ccmp	w8, #1, #8, ne
	b.lt	LBB0_20
; %bb.8:
	mov	x22, #0
	mov	x23, #0
	mov	w24, #1
	b	LBB0_11
LBB0_9:                                 ;   in Loop: Header=BB0_11 Depth=1
	bic	w19, w19, w25
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	add	x23, x23, #1
	ldrsw	x8, [x21]
	add	x22, x22, #32
	cmp	x23, x8
	b.ge	LBB0_19
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	lsl	w25, w24, w23
	tst	w25, w19
	b.eq	LBB0_10
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	ldr	x8, [x21, #8]
	add	x10, x8, x22
	ldr	x9, [x10]
	ldr	s1, [x9]
	ldr	s0, [x10, #8]
	fsub	s2, s1, s0
	ldr	x10, [x20, #16]
	ldr	x1, [x10, #8]
	ldr	s3, [x1]
	fcmp	s2, s3
	b.gt	LBB0_9
; %bb.13:                               ;   in Loop: Header=BB0_11 Depth=1
	fadd	s1, s1, s0
	ldr	x0, [x10]
	ldr	s2, [x0]
	fcmp	s1, s2
	b.mi	LBB0_9
; %bb.14:                               ;   in Loop: Header=BB0_11 Depth=1
	ldr	s1, [x9, #4]
	fsub	s2, s1, s0
	ldr	s3, [x1, #4]
	fcmp	s2, s3
	b.gt	LBB0_9
; %bb.15:                               ;   in Loop: Header=BB0_11 Depth=1
	fadd	s1, s0, s1
	ldr	s2, [x0, #4]
	fcmp	s1, s2
	b.mi	LBB0_9
; %bb.16:                               ;   in Loop: Header=BB0_11 Depth=1
	ldr	s1, [x9, #8]
	fsub	s2, s1, s0
	ldr	s3, [x1, #8]
	fcmp	s2, s3
	b.gt	LBB0_9
; %bb.17:                               ;   in Loop: Header=BB0_11 Depth=1
	fadd	s0, s0, s1
	ldr	s1, [x0, #8]
	fcmp	s0, s1
	b.mi	LBB0_9
; %bb.18:                               ;   in Loop: Header=BB0_11 Depth=1
	add	x8, x8, x22
	add	x2, x8, #12
	bl	_BoxOnPlaneSide
	cmp	w0, #2
	b.eq	LBB0_9
	b	LBB0_10
LBB0_19:
	ldr	w9, [x20, #8]
                                        ; kill: def $w8 killed $w8 killed $x8 def $x8
LBB0_20:
Lloh8:
	adrp	x10, _CULLINFO_SPHERE@GOTPAGE
Lloh9:
	ldr	x10, [x10, _CULLINFO_SPHERE@GOTPAGEOFF]
Lloh10:
	ldr	w10, [x10]
	and	w9, w10, w9
	cmp	w9, #0
	ccmp	w8, #1, #8, ne
	b.ge	LBB0_23
LBB0_21:
	ldr	x8, [x20]
	ldr	w9, [x8]
	sub	w9, w9, #128
	cmp	w9, #2
	b.hi	LBB0_29
; %bb.22:
	str	w19, [x8]
	b	LBB0_30
LBB0_23:
	mov	x22, #0
	mov	x23, #0
	mov	w24, #1
	b	LBB0_26
LBB0_24:                                ;   in Loop: Header=BB0_26 Depth=1
	bic	w19, w19, w25
LBB0_25:                                ;   in Loop: Header=BB0_26 Depth=1
	add	x23, x23, #1
	ldrsw	x8, [x21]
	add	x22, x22, #32
	cmp	x23, x8
	b.ge	LBB0_21
LBB0_26:                                ; =>This Inner Loop Header: Depth=1
	lsl	w25, w24, w23
	tst	w25, w19
	b.eq	LBB0_25
; %bb.27:                               ;   in Loop: Header=BB0_26 Depth=1
	ldr	x8, [x21, #8]
	add	x26, x8, x22
	ldp	w1, w0, [x26, #20]
	ldr	x2, [x20, #24]
	ldr	s0, [x20, #32]
	bl	_SpheresIntersect
	cbz	w0, LBB0_24
; %bb.28:                               ;   in Loop: Header=BB0_26 Depth=1
	ldr	x0, [x20, #24]
	ldr	w1, [x26, #16]
	bl	_DotProduct
	ldr	s1, [x26, #12]
	fsub	s0, s0, s1
	ldr	s1, [x20, #32]
	fneg	s1, s1
	fcmp	s0, s1
	b.mi	LBB0_24
	b	LBB0_25
LBB0_29:
	mov	w19, #0
LBB0_30:
	mov	x0, x19
	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
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_CULLINFO_PLANE,4,2             ; @CULLINFO_PLANE
	.comm	_tr,16,3                        ; @tr
	.comm	_CULLINFO_BOX,4,2               ; @CULLINFO_BOX
	.comm	_CULLINFO_SPHERE,4,2            ; @CULLINFO_SPHERE
	.no_dead_strip	_R_PshadowSurface
.subsections_via_symbols
