	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function orthogonalize
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
_orthogonalize:                         ## @orthogonalize
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	movq	_BLOCKSIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	testl	%r9d, %r9d
	jle	LBB0_22
## %bb.1:
	cmpl	$1, %r9d
	jne	LBB0_3
## %bb.2:
	xorps	%xmm1, %xmm1
	xorl	%ecx, %ecx
	jmp	LBB0_5
LBB0_3:
	movl	%r9d, %eax
	andl	$-2, %eax
	xorps	%xmm0, %xmm0
	xorl	%ecx, %ecx
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movss	(%rsi,%rcx,4), %xmm2            ## xmm2 = mem[0],zero,zero,zero
	movss	4(%rsi,%rcx,4), %xmm1           ## xmm1 = mem[0],zero,zero,zero
	movsldup	%xmm2, %xmm3                    ## xmm3 = xmm2[0,0,2,2]
	insertps	$16, (%rdi,%rcx,4), %xmm2       ## xmm2 = xmm2[0],mem[0],xmm2[2,3]
	mulps	%xmm3, %xmm2
	addps	%xmm0, %xmm2
	movsldup	%xmm1, %xmm0                    ## xmm0 = xmm1[0,0,2,2]
	insertps	$16, 4(%rdi,%rcx,4), %xmm1      ## xmm1 = xmm1[0],mem[0],xmm1[2,3]
	mulps	%xmm0, %xmm1
	addps	%xmm2, %xmm1
	addq	$2, %rcx
	movaps	%xmm1, %xmm0
	cmpq	%rcx, %rax
	jne	LBB0_4
LBB0_5:
	testb	$1, %r9b
	je	LBB0_7
## %bb.6:
	movss	(%rsi,%rcx,4), %xmm0            ## xmm0 = mem[0],zero,zero,zero
	movsldup	%xmm0, %xmm2                    ## xmm2 = xmm0[0,0,2,2]
	insertps	$16, (%rdi,%rcx,4), %xmm0       ## xmm0 = xmm0[0],mem[0],xmm0[2,3]
	mulps	%xmm0, %xmm2
	addps	%xmm2, %xmm1
LBB0_7:
	movshdup	%xmm1, %xmm0                    ## xmm0 = xmm1[1,1,3,3]
	xorps	LCPI0_0(%rip), %xmm0
	divss	%xmm1, %xmm0
	cmpl	$8, %r9d
	jb	LBB0_8
## %bb.9:
	leaq	(%rsi,%r9,4), %rax
	cmpq	%rdi, %rax
	jbe	LBB0_12
## %bb.10:
	leaq	(%rdi,%r9,4), %rax
	cmpq	%rsi, %rax
	jbe	LBB0_12
LBB0_8:
	xorl	%ecx, %ecx
LBB0_18:
	movq	%rcx, %rax
	notq	%rax
	testb	$1, %r9b
	je	LBB0_20
## %bb.19:
	movss	(%rsi,%rcx,4), %xmm1            ## xmm1 = mem[0],zero,zero,zero
	mulss	%xmm0, %xmm1
	addss	(%rdi,%rcx,4), %xmm1
	movss	%xmm1, (%rdi,%rcx,4)
	orq	$1, %rcx
LBB0_20:
	addq	%r9, %rax
	je	LBB0_22
	.p2align	4, 0x90
LBB0_21:                                ## =>This Inner Loop Header: Depth=1
	movss	(%rsi,%rcx,4), %xmm1            ## xmm1 = mem[0],zero,zero,zero
	mulss	%xmm0, %xmm1
	addss	(%rdi,%rcx,4), %xmm1
	movss	%xmm1, (%rdi,%rcx,4)
	movss	4(%rsi,%rcx,4), %xmm1           ## xmm1 = mem[0],zero,zero,zero
	mulss	%xmm0, %xmm1
	addss	4(%rdi,%rcx,4), %xmm1
	movss	%xmm1, 4(%rdi,%rcx,4)
	addq	$2, %rcx
	cmpq	%rcx, %r9
	jne	LBB0_21
	jmp	LBB0_22
LBB0_12:
	movl	%r9d, %ecx
	andl	$-8, %ecx
	movaps	%xmm0, %xmm1
	shufps	$0, %xmm0, %xmm1                ## xmm1 = xmm1[0,0],xmm0[0,0]
	leaq	-8(%rcx), %rax
	movq	%rax, %r8
	shrq	$3, %r8
	incq	%r8
	testq	%rax, %rax
	je	LBB0_23
## %bb.13:
	movq	%r8, %rax
	andq	$-2, %rax
	xorl	%edx, %edx
	.p2align	4, 0x90
LBB0_14:                                ## =>This Inner Loop Header: Depth=1
	movups	(%rsi,%rdx,4), %xmm2
	movups	16(%rsi,%rdx,4), %xmm3
	mulps	%xmm1, %xmm2
	movups	(%rdi,%rdx,4), %xmm4
	addps	%xmm2, %xmm4
	movups	16(%rdi,%rdx,4), %xmm2
	movups	32(%rdi,%rdx,4), %xmm5
	movups	48(%rdi,%rdx,4), %xmm6
	mulps	%xmm1, %xmm3
	addps	%xmm2, %xmm3
	movups	%xmm4, (%rdi,%rdx,4)
	movups	%xmm3, 16(%rdi,%rdx,4)
	movups	32(%rsi,%rdx,4), %xmm2
	movups	48(%rsi,%rdx,4), %xmm3
	mulps	%xmm1, %xmm2
	addps	%xmm5, %xmm2
	mulps	%xmm1, %xmm3
	addps	%xmm6, %xmm3
	movups	%xmm2, 32(%rdi,%rdx,4)
	movups	%xmm3, 48(%rdi,%rdx,4)
	addq	$16, %rdx
	addq	$-2, %rax
	jne	LBB0_14
## %bb.15:
	testb	$1, %r8b
	je	LBB0_17
LBB0_16:
	movups	(%rsi,%rdx,4), %xmm2
	movups	16(%rsi,%rdx,4), %xmm3
	movups	(%rdi,%rdx,4), %xmm4
	movups	16(%rdi,%rdx,4), %xmm5
	mulps	%xmm1, %xmm2
	addps	%xmm4, %xmm2
	mulps	%xmm1, %xmm3
	addps	%xmm5, %xmm3
	movups	%xmm2, (%rdi,%rdx,4)
	movups	%xmm3, 16(%rdi,%rdx,4)
LBB0_17:
	cmpq	%r9, %rcx
	jne	LBB0_18
LBB0_22:
	popq	%rbp
	retq
LBB0_23:
	xorl	%edx, %edx
	testb	$1, %r8b
	jne	LBB0_16
	jmp	LBB0_17
	.cfi_endproc
                                        ## -- End function
	.comm	_BLOCKSIZE,4,2                  ## @BLOCKSIZE
	.no_dead_strip	_orthogonalize
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function orthogonalize
_orthogonalize:                         ; @orthogonalize
	.cfi_startproc
; %bb.0:
Lloh0:
	adrp	x8, _BLOCKSIZE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BLOCKSIZE@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, #1
	b.lt	LBB0_14
; %bb.1:
	cmp	w8, #4
	b.hs	LBB0_3
; %bb.2:
	mov	x9, #0
	movi	d0, #0000000000000000
	movi	d1, #0000000000000000
	b	LBB0_6
LBB0_3:
	and	x9, x8, #0xfffffffc
	add	x10, x1, #8
	add	x11, x0, #8
	movi	d0, #0000000000000000
	mov	x12, x9
	movi	d1, #0000000000000000
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldp	s2, s3, [x11, #-8]
	ldp	s4, s5, [x11], #16
	ldp	s6, s7, [x10, #-8]
	ldp	s16, s17, [x10], #16
	fmul	s2, s2, s6
	fmul	s3, s3, s7
	fmul	s4, s4, s16
	fmul	s5, s5, s17
	fadd	s1, s1, s2
	fadd	s1, s1, s3
	fadd	s1, s1, s4
	fadd	s1, s1, s5
	fmul	s2, s6, s6
	fmul	s3, s7, s7
	fmul	s4, s16, s16
	fmul	s5, s17, s17
	fadd	s0, s0, s2
	fadd	s0, s0, s3
	fadd	s0, s0, s4
	fadd	s0, s0, s5
	subs	x12, x12, #4
	b.ne	LBB0_4
; %bb.5:
	cmp	x9, x8
	b.eq	LBB0_8
LBB0_6:
	lsl	x11, x9, #2
	add	x10, x1, x11
	add	x11, x0, x11
	sub	x9, x8, x9
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	s2, [x11], #4
	ldr	s3, [x10], #4
	fmadd	s1, s2, s3, s1
	fmadd	s0, s3, s3, s0
	subs	x9, x9, #1
	b.ne	LBB0_7
LBB0_8:
	fneg	s1, s1
	fdiv	s0, s1, s0
	cmp	w8, #16
	b.lo	LBB0_11
; %bb.9:
	lsl	x9, x8, #2
	add	x10, x1, x9
	cmp	x10, x0
	b.ls	LBB0_15
; %bb.10:
	add	x9, x0, x9
	cmp	x9, x1
	b.ls	LBB0_15
LBB0_11:
	mov	x9, #0
LBB0_12:
	lsl	x11, x9, #2
	add	x10, x0, x11
	add	x11, x1, x11
	sub	x8, x8, x9
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldr	s1, [x11], #4
	ldr	s2, [x10]
	fmadd	s1, s0, s1, s2
	str	s1, [x10], #4
	subs	x8, x8, #1
	b.ne	LBB0_13
LBB0_14:
	ret
LBB0_15:
	and	x9, x8, #0xfffffff0
	dup.4s	v1, v0[0]
	add	x10, x0, #32
	add	x11, x1, #32
	mov	x12, x9
LBB0_16:                                ; =>This Inner Loop Header: Depth=1
	ldp	q2, q3, [x11, #-32]
	ldp	q4, q5, [x11], #64
	ldp	q6, q7, [x10, #-32]
	ldp	q16, q17, [x10]
	fmla.4s	v6, v2, v1
	fmla.4s	v7, v3, v1
	fmla.4s	v16, v4, v1
	fmla.4s	v17, v5, v1
	stp	q6, q7, [x10, #-32]
	stp	q16, q17, [x10], #64
	subs	x12, x12, #16
	b.ne	LBB0_16
; %bb.17:
	cmp	x9, x8
	b.eq	LBB0_14
	b	LBB0_12
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_BLOCKSIZE,4,2                  ; @BLOCKSIZE
	.no_dead_strip	_orthogonalize
.subsections_via_symbols
