	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_TPL_CloseTPLFile               ## -- Begin function TPL_CloseTPLFile
	.p2align	4, 0x90
_TPL_CloseTPLFile:                      ## @TPL_CloseTPLFile
	.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
	testq	%rdi, %rdi
	je	LBB0_19
## %bb.1:
	movq	%rdi, %r14
	movq	(%rdi), %rax
	movq	_TPL_FILE_TYPE_DISC@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_18
## %bb.2:
	movq	16(%r14), %rdi
	testq	%rdi, %rdi
	je	LBB0_4
## %bb.3:
	callq	_fclose
LBB0_4:
	movq	24(%r14), %r13
	testq	%r13, %r13
	je	LBB0_19
## %bb.5:
	cmpl	$0, 8(%r14)
	jle	LBB0_17
## %bb.6:
	addq	$8, %r13
	xorl	%ebx, %ebx
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_7 Depth=1
	movq	%r15, %rdi
	callq	_free
LBB0_15:                                ##   in Loop: Header=BB0_7 Depth=1
	incq	%rbx
	movslq	8(%r14), %rax
	addq	$16, %r13
	cmpq	%rax, %rbx
	jge	LBB0_16
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	-8(%r13), %r15
	movq	(%r13), %r12
	testq	%r12, %r12
	je	LBB0_11
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movq	(%r12), %rdi
	testq	%rdi, %rdi
	je	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_7 Depth=1
	callq	_free
LBB0_10:                                ##   in Loop: Header=BB0_7 Depth=1
	movq	%r12, %rdi
	callq	_free
LBB0_11:                                ##   in Loop: Header=BB0_7 Depth=1
	testq	%r15, %r15
	je	LBB0_15
## %bb.12:                              ##   in Loop: Header=BB0_7 Depth=1
	movq	(%r15), %rdi
	testq	%rdi, %rdi
	je	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_7 Depth=1
	callq	_free
	jmp	LBB0_14
LBB0_16:
	movq	24(%r14), %r13
LBB0_17:
	movq	%r13, %rdi
	callq	_free
LBB0_18:
	movl	$0, 8(%r14)
	xorps	%xmm0, %xmm0
	movups	%xmm0, 16(%r14)
LBB0_19:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_TPL_FILE_TYPE_DISC,8,3         ## @TPL_FILE_TYPE_DISC
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_TPL_CloseTPLFile               ; -- Begin function TPL_CloseTPLFile
	.p2align	2
_TPL_CloseTPLFile:                      ; @TPL_CloseTPLFile
	.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
	cbz	x0, LBB0_19
; %bb.1:
	mov	x19, x0
	ldr	x8, [x0]
Lloh0:
	adrp	x9, _TPL_FILE_TYPE_DISC@GOTPAGE
Lloh1:
	ldr	x9, [x9, _TPL_FILE_TYPE_DISC@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_18
; %bb.2:
	ldr	x0, [x19, #16]
	cbz	x0, LBB0_4
; %bb.3:
	bl	_fclose
LBB0_4:
	ldr	x0, [x19, #24]
	cbz	x0, LBB0_19
; %bb.5:
	ldr	w8, [x19, #8]
	cmp	w8, #1
	b.lt	LBB0_17
; %bb.6:
	mov	x22, #0
	add	x23, x0, #8
	b	LBB0_9
LBB0_7:                                 ;   in Loop: Header=BB0_9 Depth=1
	mov	x0, x20
	bl	_free
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=1
	add	x22, x22, #1
	ldrsw	x8, [x19, #8]
	add	x23, x23, #16
	cmp	x22, x8
	b.ge	LBB0_16
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldp	x20, x21, [x23, #-8]
	cbz	x21, LBB0_13
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	x0, [x21]
	cbz	x0, LBB0_12
; %bb.11:                               ;   in Loop: Header=BB0_9 Depth=1
	bl	_free
LBB0_12:                                ;   in Loop: Header=BB0_9 Depth=1
	mov	x0, x21
	bl	_free
LBB0_13:                                ;   in Loop: Header=BB0_9 Depth=1
	cbz	x20, LBB0_8
; %bb.14:                               ;   in Loop: Header=BB0_9 Depth=1
	ldr	x0, [x20]
	cbz	x0, LBB0_7
; %bb.15:                               ;   in Loop: Header=BB0_9 Depth=1
	bl	_free
	b	LBB0_7
LBB0_16:
	ldr	x0, [x19, #24]
LBB0_17:
	bl	_free
LBB0_18:
	str	wzr, [x19, #8]
	stp	xzr, xzr, [x19, #16]
LBB0_19:
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_TPL_FILE_TYPE_DISC,8,3         ; @TPL_FILE_TYPE_DISC
.subsections_via_symbols
