	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function switch_create
_switch_create:                         ## @switch_create
	.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
	movq	%rdx, %r15
	movl	%esi, -44(%rbp)                 ## 4-byte Spill
	movq	%rdi, %r14
	movl	(%rdi), %r12d
	movl	(%rdx), %r13d
	movl	%r12d, %edi
	shll	$4, %edi
	addl	$32, %edi
	callq	_malloc
	testq	%rax, %rax
	je	LBB0_12
## %bb.1:
	movq	%rax, %rbx
	movq	%rax, %rdi
	xorl	%esi, %esi
	movl	$32, %edx
	callq	_memset
	testq	%r12, %r12
	je	LBB0_8
## %bb.2:
	movq	24(%rbx), %r8
	cmpl	$1, %r12d
	jne	LBB0_4
## %bb.3:
	xorl	%ecx, %ecx
	jmp	LBB0_6
LBB0_4:
	movl	%r12d, %edx
	andl	$-2, %edx
	leaq	24(%r8), %rsi
	xorl	%ecx, %ecx
	movq	_NONE@GOTPCREL(%rip), %rdi
	.p2align	4, 0x90
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%rdi), %rax
	movq	%rax, -16(%rsi)
	movq	(%rdi), %rax
	movq	%rax, -24(%rsi)
	movq	(%rdi), %rax
	movq	%rax, (%rsi)
	movq	(%rdi), %rax
	movq	%rax, -8(%rsi)
	addq	$2, %rcx
	addq	$32, %rsi
	cmpq	%rcx, %rdx
	jne	LBB0_5
LBB0_6:
	testb	$1, %r12b
	je	LBB0_8
## %bb.7:
	movq	_NONE@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	shlq	$4, %rcx
	movq	%rdx, 8(%r8,%rcx)
	movq	(%rax), %rax
	movq	%rax, (%r8,%rcx)
LBB0_8:
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, (%rbx)
	shll	$2, %r13d
	movl	%r13d, %edi
	callq	_malloc
	movq	%rax, 8(%rbx)
	testq	%rax, %rax
	je	LBB0_11
## %bb.9:
	movq	%r15, 16(%rbx)
	movq	%rbx, 8(%r15)
	movq	%r14, %rdi
	movq	%rbx, %rsi
	callq	_osm_mesh_node_create
	testq	%rax, %rax
	je	LBB0_13
## %bb.10:
	movq	8(%rbx), %rdi
	callq	_free
LBB0_11:
	movq	%rbx, %rdi
	callq	_free
LBB0_12:
	xorl	%ebx, %ebx
LBB0_13:
	movq	%rbx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_NONE,8,3                       ## @NONE
	.no_dead_strip	_switch_create
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function switch_create
_switch_create:                         ; @switch_create
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x21, x2
	mov	x22, x1
	mov	x20, x0
	ldr	w24, [x0]
	ldr	w23, [x2]
	lsl	w8, w24, #4
	add	w0, w8, #32
	bl	_malloc
	mov	x19, x0
	cbz	x0, LBB0_14
; %bb.1:
	mov	x0, x19
	mov	w1, #0
	mov	w2, #32
	bl	_memset
	cbz	w24, LBB0_10
; %bb.2:
	ldr	x9, [x19, #24]
Lloh0:
	adrp	x8, _NONE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _NONE@GOTPAGEOFF]
	cmp	w24, #4
	b.lo	LBB0_7
; %bb.3:
	add	x10, x9, x24, lsl #4
	add	x11, x8, #8
	cmp	x9, x11
	ccmp	x10, x8, #0, lo
	b.hi	LBB0_7
; %bb.4:
	and	x10, x24, #0xfffffffc
	add	x11, x9, #32
	mov	x12, x10
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ld1r.2d	{ v0 }, [x8]
	mov.16b	v1, v0
	sub	x13, x11, #32
	st2.2d	{ v0, v1 }, [x13]
	st2.2d	{ v0, v1 }, [x11]
	add	x11, x11, #64
	subs	x12, x12, #4
	b.ne	LBB0_5
; %bb.6:
	cmp	x10, x24
	b.ne	LBB0_8
	b	LBB0_10
LBB0_7:
	mov	x10, #0
LBB0_8:
	add	x9, x9, x10, lsl #4
	add	x9, x9, #8
	sub	x10, x24, x10
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x11, [x8]
	str	x11, [x9]
	ldr	x11, [x8]
	stur	x11, [x9, #-8]
	add	x9, x9, #16
	subs	x10, x10, #1
	b.ne	LBB0_9
LBB0_10:
	str	w22, [x19]
	lsl	w0, w23, #2
	bl	_malloc
	str	x0, [x19, #8]
	cbz	x0, LBB0_13
; %bb.11:
	str	x21, [x19, #16]
	str	x19, [x21, #8]
	mov	x0, x20
	mov	x1, x19
	bl	_osm_mesh_node_create
	cbz	x0, LBB0_14
; %bb.12:
	ldr	x0, [x19, #8]
	bl	_free
LBB0_13:
	mov	x0, x19
	bl	_free
	mov	x19, #0
LBB0_14:
	mov	x0, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_NONE,8,3                       ; @NONE
	.no_dead_strip	_switch_create
.subsections_via_symbols
