	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_realfs_truncate                ## -- Begin function realfs_truncate
	.p2align	4, 0x90
_realfs_truncate:                       ## @realfs_truncate
	.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
	movl	%edx, %r14d
	movl	(%rdi), %ebx
	movq	%rsi, %rdi
	callq	_fix_path
	movq	_O_RDWR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movl	%ebx, %edi
	movl	%eax, %esi
	callq	_openat
	testl	%eax, %eax
	js	LBB0_4
## %bb.1:
	movl	%eax, %ebx
	movl	%eax, %edi
	movl	%r14d, %esi
	callq	_ftruncate
	xorl	%r14d, %r14d
	testq	%rax, %rax
	jns	LBB0_3
## %bb.2:
	xorl	%eax, %eax
	callq	_errno_map
	movl	%eax, %r14d
LBB0_3:
	movl	%ebx, %edi
	callq	_close
	movl	%r14d, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_4:
	xorl	%eax, %eax
	popq	%rbx
	popq	%r14
	popq	%rbp
	jmp	_errno_map                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_O_RDWR,4,2                     ## @O_RDWR
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_realfs_truncate                ; -- Begin function realfs_truncate
	.p2align	2
_realfs_truncate:                       ; @realfs_truncate
	.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	x20, x2
	ldr	w19, [x0]
	mov	x0, x1
	bl	_fix_path
	mov	x1, x0
Lloh0:
	adrp	x8, _O_RDWR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _O_RDWR@GOTPAGEOFF]
Lloh2:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_openat
	tbnz	w0, #31, LBB0_3
; %bb.1:
	mov	x19, x0
	mov	x1, x20
	bl	_ftruncate
	tbnz	x0, #63, LBB0_4
; %bb.2:
	mov	w20, #0
	b	LBB0_5
LBB0_3:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_errno_map
LBB0_4:
	bl	_errno_map
	mov	x20, x0
LBB0_5:
	mov	x0, x19
	bl	_close
	mov	x0, x20
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_O_RDWR,4,2                     ; @O_RDWR
.subsections_via_symbols
