	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_FreeBrush                      ## -- Begin function FreeBrush
	.p2align	4, 0x90
_FreeBrush:                             ## @FreeBrush
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %r14
	movl	(%rdi), %eax
	testl	%eax, %eax
	jle	LBB0_5
## %bb.1:
	xorl	%ebx, %ebx
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	incq	%rbx
	movslq	%eax, %rcx
	cmpq	%rcx, %rbx
	jge	LBB0_5
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r14), %rcx
	movq	(%rcx,%rbx,8), %rdi
	testq	%rdi, %rdi
	je	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	callq	_FreeWinding
	movl	(%r14), %eax
	jmp	LBB0_4
LBB0_5:
	movq	_numthreads@GOTPCREL(%rip), %rax
	cmpl	$1, (%rax)
	jne	LBB0_7
## %bb.6:
	movq	_c_active_brushes@GOTPCREL(%rip), %rax
	decl	(%rax)
	movq	%r14, %rdi
	callq	_MemorySize
	movq	_c_brushmemory@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdx
	subq	%rax, %rdx
	xorl	%eax, %eax
	testq	%rdx, %rdx
	cmovgq	%rdx, %rax
	movq	%rax, (%rcx)
LBB0_7:
	movq	%r14, %rdi
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_FreeMemory                     ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_numthreads,4,2                 ## @numthreads
	.comm	_c_active_brushes,4,2           ## @c_active_brushes
	.comm	_c_brushmemory,8,3              ## @c_brushmemory
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_FreeBrush                      ; -- Begin function FreeBrush
	.p2align	2
_FreeBrush:                             ; @FreeBrush
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	ldr	w8, [x0]
	cmp	w8, #1
	b.lt	LBB0_5
; %bb.1:
	mov	x20, #0
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x20, x20, #1
	cmp	x20, w8, sxtw
	b.ge	LBB0_5
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x19, #8]
	ldr	x0, [x9, x20, lsl #3]
	cbz	x0, LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	bl	_FreeWinding
	ldr	w8, [x19]
	b	LBB0_2
LBB0_5:
Lloh0:
	adrp	x8, _numthreads@GOTPAGE
Lloh1:
	ldr	x8, [x8, _numthreads@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, #1
	b.ne	LBB0_7
; %bb.6:
Lloh3:
	adrp	x8, _c_active_brushes@GOTPAGE
Lloh4:
	ldr	x8, [x8, _c_active_brushes@GOTPAGEOFF]
	ldr	w9, [x8]
	sub	w9, w9, #1
	str	w9, [x8]
	mov	x0, x19
	bl	_MemorySize
Lloh5:
	adrp	x8, _c_brushmemory@GOTPAGE
Lloh6:
	ldr	x8, [x8, _c_brushmemory@GOTPAGEOFF]
	ldr	x9, [x8]
	sub	x9, x9, x0
	cmp	x9, #0
	csel	x9, x9, xzr, gt
	str	x9, [x8]
LBB0_7:
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_FreeMemory
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_numthreads,4,2                 ; @numthreads
	.comm	_c_active_brushes,4,2           ; @c_active_brushes
	.comm	_c_brushmemory,8,3              ; @c_brushmemory
.subsections_via_symbols
