	.file	"extr_vfs_vnops.c_vn_write.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"No FOF_OFFSET"
	.text
	.p2align 4
	.type	vn_write, @function
vn_write:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	mov	r12d, ecx
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	mov	rbp, rdi
	xor	edi, edi
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	mov	rbx, rsi
	mov	rsi, r8
	sub	rsp, 40
	.cfi_def_cfa_offset 96
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 24[rsp], rax
	xor	eax, eax
	cmp	QWORD PTR 8[rbx], r8
	sete	dil
	call	KASSERT@PLT
	mov	edi, DWORD PTR FOF_OFFSET[rip]
	lea	rsi, .LC0[rip]
	and	edi, r12d
	call	KASSERT@PLT
	mov	r13, QWORD PTR 24[rbp]
	mov	rdx, QWORD PTR 0[r13]
	cmp	rdx, QWORD PTR VREG[rip]
	je	.L48
	mov	r15d, DWORD PTR IO_UNIT[rip]
	mov	eax, DWORD PTR 0[rbp]
.L4:
	test	DWORD PTR FNONBLOCK[rip], eax
	je	.L5
	or	r15d, DWORD PTR IO_NDELAY[rip]
.L5:
	test	DWORD PTR O_DIRECT[rip], eax
	je	.L6
	or	r15d, DWORD PTR IO_DIRECT[rip]
.L6:
	test	DWORD PTR O_FSYNC[rip], eax
	jne	.L7
	mov	rax, QWORD PTR 8[r13]
	test	rax, rax
	je	.L8
	mov	eax, DWORD PTR [rax]
	test	DWORD PTR MNT_SYNCHRONOUS[rip], eax
	jne	.L7
	.p2align 4,,10
	.p2align 3
.L8:
	mov	QWORD PTR 16[rsp], 0
	cmp	QWORD PTR VCHR[rip], rdx
	je	.L13
	mov	edx, DWORD PTR V_WAIT[rip]
	lea	rsi, 16[rsp]
	mov	rdi, r13
	or	edx, DWORD PTR PCATCH[rip]
	call	vn_start_write@PLT
	mov	r12d, eax
	test	eax, eax
	jne	.L1
.L13:
	mov	rdi, rbp
	mov	rsi, rbx
	call	get_advice@PLT
	mov	rdi, QWORD PTR 16[rsp]
	mov	r14d, eax
	call	MNT_SHARED_WRITES@PLT
	test	rax, rax
	je	.L49
.L10:
	mov	esi, DWORD PTR LK_SHARED[rip]
.L14:
	or	esi, DWORD PTR LK_RETRY[rip]
	mov	rdi, r13
	call	vn_lock@PLT
	cmp	r14d, 128
	je	.L16
	lea	eax, -130[r14]
	cmp	eax, 1
	ja	.L17
.L16:
	mov	rsi, rbp
	mov	rdi, rbx
	call	sequential_heuristic@PLT
	or	r15d, eax
.L17:
	mov	rax, QWORD PTR [rbx]
	mov	ecx, DWORD PTR 16[rbp]
	mov	edx, r15d
	mov	rsi, rbx
	mov	rdi, r13
	mov	QWORD PTR 8[rsp], rax
	call	VOP_WRITE@PLT
	xor	esi, esi
	mov	rdi, r13
	mov	r12d, eax
	mov	rax, QWORD PTR [rbx]
	mov	QWORD PTR 8[rbp], rax
	call	VOP_UNLOCK@PLT
	mov	rax, QWORD PTR VCHR[rip]
	cmp	QWORD PTR 0[r13], rax
	je	.L18
	mov	rdi, QWORD PTR 16[rsp]
	call	vn_finished_write@PLT
.L18:
	test	r12d, r12d
	jne	.L1
	cmp	r14d, 131
	jne	.L1
.L12:
	endbr64
	mov	rdx, QWORD PTR [rbx]
	mov	rsi, QWORD PTR 8[rsp]
	cmp	rdx, rsi
	jne	.L50
	.p2align 4,,10
	.p2align 3
.L1:
	mov	rax, QWORD PTR 24[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L51
	add	rsp, 40
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	mov	eax, r12d
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L7:
	.cfi_restore_state
	or	r15d, DWORD PTR IO_SYNC[rip]
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L49:
	cmp	QWORD PTR 16[rsp], 0
	je	.L52
.L15:
	mov	esi, DWORD PTR LK_EXCLUSIVE[rip]
	jmp	.L14
	.p2align 4,,10
	.p2align 3
.L48:
	xor	eax, eax
	call	bwillwrite@PLT
	mov	rdx, QWORD PTR 0[r13]
	cmp	rdx, QWORD PTR VREG[rip]
	mov	r15d, DWORD PTR IO_UNIT[rip]
	mov	eax, DWORD PTR 0[rbp]
	jne	.L4
	test	DWORD PTR O_APPEND[rip], eax
	je	.L4
	or	r15d, DWORD PTR IO_APPEND[rip]
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L50:
	mov	ecx, DWORD PTR POSIX_FADV_DONTNEED[rip]
	sub	rdx, 1
	mov	rdi, r13
	call	VOP_ADVISE@PLT
	mov	r12d, eax
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L52:
	mov	rdi, QWORD PTR 8[r13]
	call	MNT_SHARED_WRITES@PLT
	test	rax, rax
	jne	.L10
	jmp	.L15
.L51:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	vn_write, .-vn_write
	.comm	V_WAIT,4,4
	.comm	VREG,8,8
	.comm	VCHR,8,8
	.comm	POSIX_FADV_DONTNEED,4,4
	.comm	PCATCH,4,4
	.comm	O_FSYNC,4,4
	.comm	O_DIRECT,4,4
	.comm	O_APPEND,4,4
	.comm	MNT_SYNCHRONOUS,4,4
	.comm	LK_SHARED,4,4
	.comm	LK_RETRY,4,4
	.comm	LK_EXCLUSIVE,4,4
	.comm	IO_UNIT,4,4
	.comm	IO_SYNC,4,4
	.comm	IO_NDELAY,4,4
	.comm	IO_DIRECT,4,4
	.comm	IO_APPEND,4,4
	.comm	FOF_OFFSET,4,4
	.comm	FNONBLOCK,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_vfs_vnops.c_vn_write.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"No FOF_OFFSET\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC1:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	vn_write, %function
vn_write:
	@ args = 4, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	sub	sp, sp, #8
	mov	r5, r0
	mov	r4, r1
	ldr	r0, [r1, #4]
	ldr	r1, [sp, #40]
	mov	r6, r3
	sub	r0, r0, r1
	clz	r0, r0
	ldr	r3, .L50
	lsr	r0, r0, #5
	ldr	r3, [r3]
	str	r3, [sp, #4]
	mov	r3,#0
	bl	KASSERT
	ldr	r3, .L50+4
	ldr	r1, .L50+8
	ldr	r0, [r3]
	ldr	r8, .L50+12
	and	r0, r0, r6
	bl	KASSERT
	ldr	r7, [r5, #12]
	ldr	r3, [r8]
	ldr	r2, [r7]
	cmp	r2, r3
	beq	.L45
	ldr	r1, .L50+16
	ldr	r3, [r5]
	ldr	r8, [r1]
.L4:
	ldr	r1, .L50+20
	ldr	r1, [r1]
	tst	r3, r1
	ldrne	r1, .L50+24
	ldrne	r1, [r1]
	orrne	r8, r8, r1
	ldr	r1, .L50+28
	ldr	r1, [r1]
	tst	r3, r1
	ldrne	r1, .L50+32
	ldrne	r1, [r1]
	orrne	r8, r8, r1
	ldr	r1, .L50+36
	ldr	r1, [r1]
	tst	r3, r1
	bne	.L7
	ldr	r3, [r7, #4]
	cmp	r3, #0
	beq	.L8
	ldr	r0, .L50+40
	ldr	r1, [r3]
	ldr	r3, [r0]
	tst	r1, r3
	bne	.L7
.L8:
	mov	r3, #0
	ldr	r9, .L50+44
	str	r3, [sp]
	ldr	r3, [r9]
	cmp	r3, r2
	beq	.L13
	ldr	r2, .L50+48
	ldr	r3, .L50+52
	ldr	r2, [r2]
	ldr	r3, [r3]
	mov	r1, sp
	mov	r0, r7
	orr	r2, r2, r3
	bl	vn_start_write
	subs	r6, r0, #0
	bne	.L1
.L13:
	mov	r1, r4
	mov	r0, r5
	bl	get_advice
	mov	r10, r0
	ldr	r0, [sp]
	bl	MNT_SHARED_WRITES
	cmp	r0, #0
	beq	.L46
.L10:
	ldr	r3, .L50+56
	ldr	r1, [r3]
.L14:
	ldr	r3, .L50+60
	mov	r0, r7
	ldr	r3, [r3]
	orr	r1, r1, r3
	bl	vn_lock
	cmp	r10, #128
	beq	.L16
	sub	r3, r10, #130
	cmp	r3, #1
	bhi	.L17
.L16:
	mov	r1, r5
	mov	r0, r4
	bl	sequential_heuristic
	orr	r8, r8, r0
.L17:
	mov	r2, r8
	mov	r1, r4
	ldr	r3, [r5, #8]
	mov	r0, r7
	ldr	r8, [r4]
	bl	VOP_WRITE
	ldr	r3, [r4]
	mov	r6, r0
	str	r3, [r5, #4]
	mov	r1, #0
	mov	r0, r7
	bl	VOP_UNLOCK
	ldr	r3, [r9]
	ldr	r2, [r7]
	cmp	r2, r3
	beq	.L18
	ldr	r0, [sp]
	bl	vn_finished_write
.L18:
	cmp	r6, #0
	cmpeq	r10, #131
	bne	.L1
.L12:
	ldr	r2, [r4]
	cmp	r2, r8
	moveq	r6, #0
	bne	.L47
.L1:
	ldr	r3, .L50
	ldr	r2, [r3]
	ldr	r3, [sp, #4]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L48
	mov	r0, r6
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L7:
	ldr	r3, .L50+64
	ldr	r3, [r3]
	orr	r8, r8, r3
	b	.L8
.L46:
	ldr	r3, [sp]
	cmp	r3, #0
	beq	.L49
.L15:
	ldr	r3, .L50+68
	ldr	r1, [r3]
	b	.L14
.L45:
	bl	bwillwrite
	ldr	r1, [r8]
	ldr	r2, [r7]
	ldr	r3, .L50+16
	cmp	r2, r1
	ldr	r8, [r3]
	ldrne	r3, [r5]
	bne	.L4
	ldr	r1, .L50+72
	ldr	r3, [r5]
	ldr	r1, [r1]
	tst	r3, r1
	ldrne	r1, .L50+76
	ldrne	r1, [r1]
	orrne	r8, r8, r1
	b	.L4
.L47:
	ldr	r3, .L50+80
	mov	r1, r8
	mov	r0, r7
	ldr	r3, [r3]
	sub	r2, r2, #1
	bl	VOP_ADVISE
	mov	r6, r0
	b	.L1
.L49:
	ldr	r0, [r7, #4]
	bl	MNT_SHARED_WRITES
	cmp	r0, #0
	bne	.L10
	b	.L15
.L48:
	bl	__stack_chk_fail
.L51:
	.align	2
.L50:
	.word	.LC1
	.word	FOF_OFFSET
	.word	.LC0
	.word	VREG
	.word	IO_UNIT
	.word	FNONBLOCK
	.word	IO_NDELAY
	.word	O_DIRECT
	.word	IO_DIRECT
	.word	O_FSYNC
	.word	MNT_SYNCHRONOUS
	.word	VCHR
	.word	V_WAIT
	.word	PCATCH
	.word	LK_SHARED
	.word	LK_RETRY
	.word	IO_SYNC
	.word	LK_EXCLUSIVE
	.word	O_APPEND
	.word	IO_APPEND
	.word	POSIX_FADV_DONTNEED
	.size	vn_write, .-vn_write
	.comm	V_WAIT,4,4
	.comm	VREG,4,4
	.comm	VCHR,4,4
	.comm	POSIX_FADV_DONTNEED,4,4
	.comm	PCATCH,4,4
	.comm	O_FSYNC,4,4
	.comm	O_DIRECT,4,4
	.comm	O_APPEND,4,4
	.comm	MNT_SYNCHRONOUS,4,4
	.comm	LK_SHARED,4,4
	.comm	LK_RETRY,4,4
	.comm	LK_EXCLUSIVE,4,4
	.comm	IO_UNIT,4,4
	.comm	IO_SYNC,4,4
	.comm	IO_NDELAY,4,4
	.comm	IO_DIRECT,4,4
	.comm	IO_APPEND,4,4
	.comm	FOF_OFFSET,4,4
	.comm	FNONBLOCK,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
