	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function trim
_trim:                                  ## @trim
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, %r15d
	movl	%ecx, %r12d
	movq	%rdx, %rbx
	movq	%rsi, %r13
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	testq	%rdx, %rdx
	jne	LBB0_2
## %bb.1:
	movq	%r14, %rdi
	callq	_getsize
	movq	%rax, %rbx
LBB0_2:
	testl	%r15d, %r15d
	je	LBB0_4
## %bb.3:
	leaq	L_.str(%rip), %rdi
	movq	%r14, %rsi
	movl	%r13d, %edx
	movl	%ebx, %ecx
	xorl	%eax, %eax
	callq	_printf
LBB0_4:
	testl	%r12d, %r12d
	je	LBB0_6
## %bb.5:
	leaq	L_str(%rip), %rdi
	callq	_puts
	xorl	%ebx, %ebx
	jmp	LBB0_13
LBB0_6:
	movq	_O_WRONLY@GOTPCREL(%rip), %rax
	movq	_O_DIRECT@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	orl	(%rax), %esi
	movq	%r14, %rdi
	callq	_opendev
	movl	%eax, %r12d
	movq	%r13, -64(%rbp)
	movq	%rbx, -56(%rbp)
	movq	_DIOCGDELETE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-64(%rbp), %rdx
	movl	%r12d, %edi
	callq	_ioctl
	movl	%eax, %ebx
	testl	%eax, %eax
	jns	LBB0_12
## %bb.7:
	testl	%r15d, %r15d
	je	LBB0_11
## %bb.8:
	movq	_errno@GOTPCREL(%rip), %rax
	movq	_EOPNOTSUPP@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	%rcx, (%rax)
	jne	LBB0_11
## %bb.9:
	movl	%r12d, %edi
	callq	_candelete
	testl	%eax, %eax
	je	LBB0_10
LBB0_11:
	leaq	L_.str.3(%rip), %rdi
	movq	%r14, %rsi
	callq	_warn
LBB0_12:
	movl	%r12d, %edi
	callq	_close
LBB0_13:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_15
## %bb.14:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_10:
	leaq	L_.str.2(%rip), %rdi
	movq	%r14, %rsi
	callq	_warnx
	jmp	LBB0_12
LBB0_15:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"trim %s offset %ju length %ju\n"

	.comm	_O_WRONLY,4,2                   ## @O_WRONLY
	.comm	_O_DIRECT,4,2                   ## @O_DIRECT
	.comm	_DIOCGDELETE,4,2                ## @DIOCGDELETE
	.comm	_errno,8,3                      ## @errno
	.comm	_EOPNOTSUPP,8,3                 ## @EOPNOTSUPP
L_.str.2:                               ## @.str.2
	.asciz	"%s: TRIM/UNMAP not supported by driver"

L_.str.3:                               ## @.str.3
	.asciz	"ioctl(DIOCGDELETE) failed: %s"

L_str:                                  ## @str
	.asciz	"dry run: add -f to actually perform the operation"

	.no_dead_strip	_trim
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function trim
_trim:                                  ; @trim
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x20, x4
	mov	x22, x3
	mov	x23, x2
	mov	x21, x1
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #40]
	cbnz	x2, LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_getsize
	mov	x23, x0
LBB0_2:
	cbz	w20, LBB0_4
; %bb.3:
	stp	x21, x23, [sp, #8]
	str	x19, [sp]
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_printf
LBB0_4:
	cbz	w22, LBB0_6
; %bb.5:
Lloh5:
	adrp	x0, l_str@PAGE
Lloh6:
	add	x0, x0, l_str@PAGEOFF
	bl	_puts
	mov	w21, #0
	b	LBB0_12
LBB0_6:
Lloh7:
	adrp	x8, _O_WRONLY@GOTPAGE
Lloh8:
	ldr	x8, [x8, _O_WRONLY@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
Lloh10:
	adrp	x9, _O_DIRECT@GOTPAGE
Lloh11:
	ldr	x9, [x9, _O_DIRECT@GOTPAGEOFF]
Lloh12:
	ldr	w9, [x9]
	orr	w1, w9, w8
	mov	x0, x19
	bl	_opendev
	mov	x22, x0
	stp	x21, x23, [sp, #24]
Lloh13:
	adrp	x8, _DIOCGDELETE@GOTPAGE
Lloh14:
	ldr	x8, [x8, _DIOCGDELETE@GOTPAGEOFF]
Lloh15:
	ldr	w1, [x8]
	add	x2, sp, #24
	bl	_ioctl
	mov	x21, x0
	tbz	w0, #31, LBB0_11
; %bb.7:
	cbz	w20, LBB0_10
; %bb.8:
Lloh16:
	adrp	x8, _errno@GOTPAGE
Lloh17:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh18:
	ldr	x8, [x8]
Lloh19:
	adrp	x9, _EOPNOTSUPP@GOTPAGE
Lloh20:
	ldr	x9, [x9, _EOPNOTSUPP@GOTPAGEOFF]
Lloh21:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_10
; %bb.9:
	mov	x0, x22
	bl	_candelete
	cbz	w0, LBB0_14
LBB0_10:
Lloh22:
	adrp	x0, l_.str.3@PAGE
Lloh23:
	add	x0, x0, l_.str.3@PAGEOFF
	mov	x1, x19
	bl	_warn
LBB0_11:
	mov	x0, x22
	bl	_close
LBB0_12:
	ldr	x8, [sp, #40]
Lloh24:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh25:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh26:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_15
; %bb.13:
	mov	x0, x21
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_14:
Lloh27:
	adrp	x0, l_.str.2@PAGE
Lloh28:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	x1, x19
	bl	_warnx
	b	LBB0_11
LBB0_15:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpAdd	Lloh27, Lloh28
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"trim %s offset %ju length %ju\n"

	.comm	_O_WRONLY,4,2                   ; @O_WRONLY
	.comm	_O_DIRECT,4,2                   ; @O_DIRECT
	.comm	_DIOCGDELETE,4,2                ; @DIOCGDELETE
	.comm	_errno,8,3                      ; @errno
	.comm	_EOPNOTSUPP,8,3                 ; @EOPNOTSUPP
l_.str.2:                               ; @.str.2
	.asciz	"%s: TRIM/UNMAP not supported by driver"

l_.str.3:                               ; @.str.3
	.asciz	"ioctl(DIOCGDELETE) failed: %s"

l_str:                                  ; @str
	.asciz	"dry run: add -f to actually perform the operation"

	.no_dead_strip	_trim
.subsections_via_symbols
