	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function swapon_trim
_swapon_trim:                           ## @swapon_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	%rbx
	subq	$56, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	movq	_O_WRONLY@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_open
	movl	%eax, %r15d
	testl	%eax, %eax
	jns	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rsi
	movl	$1, %edi
	movq	%r14, %rdx
	callq	_errx
LBB0_2:
	leaq	-72(%rbp), %rsi
	movl	%r15d, %edi
	callq	_fstat
	testq	%rax, %rax
	jns	LBB0_4
## %bb.3:
	leaq	L_.str.1(%rip), %rsi
	movl	$1, %edi
	movq	%r14, %rdx
	callq	_errx
LBB0_4:
	movl	-72(%rbp), %ebx
	movl	%ebx, %edi
	callq	_S_ISREG
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	movq	-64(%rbp), %rax
	movq	%rax, -56(%rbp)
LBB0_10:
	movq	_BBSIZE@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	-56(%rbp), %rcx
	subq	%rax, %rcx
	movq	%rcx, -40(%rbp)
	movq	_DIOCGDELETE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-48(%rbp), %rdx
	movl	%r15d, %edi
	callq	_ioctl
	testq	%rax, %rax
	je	LBB0_12
## %bb.11:
	leaq	L_.str.4(%rip), %rdi
	callq	_warn
LBB0_12:
	movq	%r14, %rdi
	callq	_swapon
	movl	%eax, %ebx
	movl	%r15d, %edi
	callq	_close
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-32(%rbp), %rax
	jne	LBB0_14
## %bb.13:
	movl	%ebx, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_6:
	movl	%ebx, %edi
	callq	_S_ISCHR
	testq	%rax, %rax
	je	LBB0_9
## %bb.7:
	movq	_DIOCGMEDIASIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-56(%rbp), %rdx
	movl	%r15d, %edi
	callq	_ioctl
	testq	%rax, %rax
	je	LBB0_10
## %bb.8:
	leaq	L_.str.2(%rip), %rsi
	movl	$1, %edi
	callq	_err
	jmp	LBB0_10
LBB0_9:
	leaq	L_.str.3(%rip), %rsi
	movl	$1, %edi
	movq	%r14, %rdx
	callq	_errx
	jmp	LBB0_10
LBB0_14:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_O_WRONLY,4,2                   ## @O_WRONLY
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Cannot open %s"

L_.str.1:                               ## @.str.1
	.asciz	"Cannot stat %s"

	.comm	_DIOCGMEDIASIZE,4,2             ## @DIOCGMEDIASIZE
L_.str.2:                               ## @.str.2
	.asciz	"ioctl(DIOCGMEDIASIZE)"

L_.str.3:                               ## @.str.3
	.asciz	"%s has an invalid file type"

	.comm	_BBSIZE,8,3                     ## @BBSIZE
	.comm	_DIOCGDELETE,4,2                ## @DIOCGDELETE
L_.str.4:                               ## @.str.4
	.asciz	"ioctl(DIOCGDELETE)"

	.no_dead_strip	_swapon_trim
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function swapon_trim
_swapon_trim:                           ; @swapon_trim
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	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]
Lloh3:
	adrp	x8, _O_WRONLY@GOTPAGE
Lloh4:
	ldr	x8, [x8, _O_WRONLY@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	bl	_open
	mov	x20, x0
	tbz	w0, #31, LBB0_2
; %bb.1:
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	w0, #1
	mov	x2, x19
	bl	_errx
LBB0_2:
	add	x1, sp, #8
	mov	x0, x20
	bl	_fstat
	tbz	x0, #63, LBB0_4
; %bb.3:
Lloh8:
	adrp	x1, l_.str.1@PAGE
Lloh9:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	w0, #1
	mov	x2, x19
	bl	_errx
LBB0_4:
	ldr	w21, [sp, #8]
	mov	x0, x21
	bl	_S_ISREG
	cbz	x0, LBB0_10
; %bb.5:
	ldr	x8, [sp, #16]
	str	x8, [sp]
LBB0_6:
Lloh10:
	adrp	x8, _BBSIZE@GOTPAGE
Lloh11:
	ldr	x8, [x8, _BBSIZE@GOTPAGEOFF]
Lloh12:
	ldr	x8, [x8]
	ldr	x9, [sp]
	sub	x9, x9, x8
	stp	x8, x9, [sp, #24]
Lloh13:
	adrp	x8, _DIOCGDELETE@GOTPAGE
Lloh14:
	ldr	x8, [x8, _DIOCGDELETE@GOTPAGEOFF]
Lloh15:
	ldr	w1, [x8]
	add	x2, sp, #24
	mov	x0, x20
	bl	_ioctl
	cbz	x0, LBB0_8
; %bb.7:
Lloh16:
	adrp	x0, l_.str.4@PAGE
Lloh17:
	add	x0, x0, l_.str.4@PAGEOFF
	bl	_warn
LBB0_8:
	mov	x0, x19
	bl	_swapon
	mov	x19, x0
	mov	x0, x20
	bl	_close
	ldr	x8, [sp, #40]
Lloh18:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh19:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh20:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_14
; %bb.9:
	mov	x0, x19
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_10:
	mov	x0, x21
	bl	_S_ISCHR
	cbz	x0, LBB0_13
; %bb.11:
Lloh21:
	adrp	x8, _DIOCGMEDIASIZE@GOTPAGE
Lloh22:
	ldr	x8, [x8, _DIOCGMEDIASIZE@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
	mov	x2, sp
	mov	x0, x20
	bl	_ioctl
	cbz	x0, LBB0_6
; %bb.12:
Lloh24:
	adrp	x1, l_.str.2@PAGE
Lloh25:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	w0, #1
	bl	_err
	b	LBB0_6
LBB0_13:
Lloh26:
	adrp	x1, l_.str.3@PAGE
Lloh27:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	w0, #1
	mov	x2, x19
	bl	_errx
	b	LBB0_6
LBB0_14:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh26, Lloh27
	.cfi_endproc
                                        ; -- End function
	.comm	_O_WRONLY,4,2                   ; @O_WRONLY
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Cannot open %s"

l_.str.1:                               ; @.str.1
	.asciz	"Cannot stat %s"

	.comm	_DIOCGMEDIASIZE,4,2             ; @DIOCGMEDIASIZE
l_.str.2:                               ; @.str.2
	.asciz	"ioctl(DIOCGMEDIASIZE)"

l_.str.3:                               ; @.str.3
	.asciz	"%s has an invalid file type"

	.comm	_BBSIZE,8,3                     ; @BBSIZE
	.comm	_DIOCGDELETE,4,2                ; @DIOCGDELETE
l_.str.4:                               ; @.str.4
	.asciz	"ioctl(DIOCGDELETE)"

	.no_dead_strip	_swapon_trim
.subsections_via_symbols
