	.file	"extr_xfs_filestream.c__xfs_filestream_update_ag.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	_xfs_filestream_update_ag, @function
_xfs_filestream_update_ag:
.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
	mov	r13, rsi
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	mov	r12, rdx
	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
	sub	rsp, 24
	.cfi_def_cfa_offset 80
	test	rbp, rbp
	je	.L2
	mov	eax, DWORD PTR 16[rbp]
	mov	edx, DWORD PTR S_IFDIR[rip]
	test	DWORD PTR S_IFREG[rip], eax
	je	.L3
	test	rsi, rsi
	je	.L4
	xor	edi, edi
	test	DWORD PTR 16[rsi], edx
	setne	dil
.L2:
	call	ASSERT@PLT
	mov	r14, QWORD PTR 8[rbp]
	mov	esi, DWORD PTR 0[rbp]
	mov	rbx, QWORD PTR [r14]
	mov	rdi, rbx
	call	xfs_mru_cache_lookup@PLT
	test	rax, rax
	je	.L5
	cmp	QWORD PTR 16[rax], rbp
	mov	QWORD PTR 8[rsp], rax
	sete	dil
	movzx	edi, dil
	call	ASSERT@PLT
	mov	rdx, QWORD PTR 8[rsp]
	mov	rdi, rbx
	mov	r15, QWORD PTR [rdx]
	mov	rax, QWORD PTR 8[rdx]
	mov	QWORD PTR [rdx], r12
	mov	QWORD PTR 8[rdx], r13
	mov	QWORD PTR 8[rsp], rax
	call	xfs_mru_cache_done@PLT
	cmp	r12, r15
	jne	.L25
	test	r13, r13
	je	.L7
.L27:
	mov	rax, QWORD PTR 8[rsp]
	cmp	r13, rax
	jne	.L26
.L7:
	mov	rsi, r12
	mov	rdi, r14
	call	xfs_filestream_peek_ag@PLT
	mov	rsi, r15
	mov	rdi, r14
	mov	ebx, eax
	call	xfs_filestream_peek_ag@PLT
	mov	r9d, ebx
	mov	r8, r12
	mov	rdx, r15
	mov	ecx, eax
	mov	rsi, rbp
	mov	rdi, r14
	xor	ebx, ebx
	call	TRACE_UPDATE@PLT
.L1:
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	mov	eax, ebx
	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
.L3:
	.cfi_restore_state
	test	eax, edx
	setne	al
	xor	edi, edi
	test	rsi, rsi
	sete	dil
	and	edi, eax
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L25:
	mov	rsi, r15
	mov	rdi, r14
	call	xfs_filestream_put_ag@PLT
	mov	rsi, r12
	mov	rdi, r14
	call	xfs_filestream_get_ag@PLT
	test	r13, r13
	jne	.L27
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L5:
	mov	esi, DWORD PTR KM_MAYFAIL[rip]
	mov	edi, DWORD PTR item_zone[rip]
	call	kmem_zone_zalloc@PLT
	mov	r15, rax
	test	rax, rax
	je	.L28
	mov	QWORD PTR [rax], r12
	mov	esi, DWORD PTR 0[rbp]
	mov	rdi, rbx
	mov	rdx, rax
	mov	QWORD PTR 16[rax], rbp
	mov	QWORD PTR 8[rax], r13
	call	xfs_mru_cache_insert@PLT
	mov	ebx, eax
	test	eax, eax
	jne	.L29
	mov	rdi, r14
	mov	rsi, r12
	call	xfs_filestream_get_ag@PLT
	mov	rdi, rbp
	call	IHOLD@PLT
	test	r13, r13
	je	.L11
	mov	rdi, r13
	call	IHOLD@PLT
.L11:
	mov	rsi, r12
	mov	rdi, r14
	call	xfs_filestream_peek_ag@PLT
	mov	rsi, r12
	mov	rdi, r14
	mov	r13d, eax
	call	xfs_filestream_peek_ag@PLT
	mov	r9d, r13d
	mov	r8, r12
	mov	rdx, r12
	mov	ecx, eax
	mov	rsi, rbp
	mov	rdi, r14
	call	TRACE_UPDATE@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L26:
	mov	rdi, rax
	call	IRELE@PLT
	mov	rdi, r13
	call	IHOLD@PLT
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L28:
	mov	ebx, DWORD PTR ENOMEM[rip]
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L29:
	mov	edi, DWORD PTR item_zone[rip]
	mov	rsi, r15
	call	kmem_zone_free@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L4:
	xor	edi, edi
	test	eax, edx
	setne	dil
	jmp	.L2
	.cfi_endproc
.LFE0:
	.size	_xfs_filestream_update_ag, .-_xfs_filestream_update_ag
	.comm	item_zone,4,4
	.comm	S_IFREG,4,4
	.comm	S_IFDIR,4,4
	.comm	KM_MAYFAIL,4,4
	.comm	ENOMEM,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_xfs_filestream.c__xfs_filestream_update_ag.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	_xfs_filestream_update_ag, %function
_xfs_filestream_update_ag:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	subs	r4, r0, #0
	mov	r8, r1
	mov	r5, r2
	moveq	r0, r4
	sub	sp, sp, #8
	beq	.L2
	ldr	r2, .L25
	ldr	r3, [r4, #8]
	ldr	r1, [r2]
	ldr	r2, .L25+4
	tst	r3, r1
	ldr	r2, [r2]
	beq	.L3
	cmp	r8, #0
	beq	.L4
	ldr	r3, [r8, #8]
	tst	r2, r3
	movne	r0, #1
	moveq	r0, #0
.L2:
	bl	ASSERT
	ldm	r4, {r1, r7}
	ldr	r9, [r7]
	mov	r0, r9
	bl	xfs_mru_cache_lookup
	subs	r6, r0, #0
	beq	.L5
	ldr	r0, [r6, #8]
	sub	r0, r0, r4
	clz	r0, r0
	lsr	r0, r0, #5
	bl	ASSERT
	ldr	r10, [r6]
	mov	r0, r9
	str	r5, [r6]
	ldr	r9, [r6, #4]
	str	r8, [r6, #4]
	bl	xfs_mru_cache_done
	cmp	r5, r10
	bne	.L21
	cmp	r8, #0
	cmpne	r8, r9
	bne	.L22
.L7:
	mov	r1, r10
	mov	r0, r7
	bl	xfs_filestream_peek_ag
	mov	r1, r5
	mov	r6, r0
	mov	r0, r7
	bl	xfs_filestream_peek_ag
	mov	r9, #0
	str	r0, [sp, #4]
	mov	r3, r6
	mov	r2, r10
	mov	r1, r4
	mov	r0, r7
	str	r5, [sp]
	bl	TRACE_UPDATE
	mov	r0, r9
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L3:
	tst	r3, r2
	movne	r0, #1
	moveq	r0, #0
	cmp	r8, #0
	movne	r0, #0
	b	.L2
.L21:
	mov	r1, r10
	mov	r0, r7
	bl	xfs_filestream_put_ag
	mov	r1, r5
	mov	r0, r7
	bl	xfs_filestream_get_ag
	cmp	r8, #0
	cmpne	r8, r9
	beq	.L7
	b	.L22
.L5:
	ldr	r3, .L25+8
	ldr	r10, .L25+12
	ldr	r1, [r3]
	ldr	r0, [r10]
	bl	kmem_zone_zalloc
	subs	r6, r0, #0
	beq	.L23
	mov	r0, r9
	mov	r2, r6
	ldr	r1, [r4]
	str	r5, [r6]
	str	r4, [r6, #8]
	str	r8, [r6, #4]
	bl	xfs_mru_cache_insert
	subs	r9, r0, #0
	bne	.L24
	mov	r1, r5
	mov	r0, r7
	bl	xfs_filestream_get_ag
	mov	r0, r4
	bl	IHOLD
	cmp	r8, #0
	beq	.L11
	mov	r0, r8
	bl	IHOLD
.L11:
	mov	r1, r5
	mov	r0, r7
	bl	xfs_filestream_peek_ag
	mov	r1, r5
	mov	r6, r0
	mov	r0, r7
	bl	xfs_filestream_peek_ag
	mov	r3, r6
	str	r0, [sp, #4]
	mov	r2, r5
	mov	r1, r4
	mov	r0, r7
	str	r5, [sp]
	bl	TRACE_UPDATE
	mov	r0, r9
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L22:
	mov	r0, r9
	bl	IRELE
	mov	r0, r8
	bl	IHOLD
	b	.L7
.L23:
	ldr	r3, .L25+16
	ldr	r9, [r3]
	mov	r0, r9
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L24:
	mov	r1, r6
	ldr	r0, [r10]
	bl	kmem_zone_free
	mov	r0, r9
	add	sp, sp, #8
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L4:
	tst	r3, r2
	movne	r0, #1
	moveq	r0, #0
	b	.L2
.L26:
	.align	2
.L25:
	.word	S_IFREG
	.word	S_IFDIR
	.word	KM_MAYFAIL
	.word	item_zone
	.word	ENOMEM
	.size	_xfs_filestream_update_ag, .-_xfs_filestream_update_ag
	.comm	item_zone,4,4
	.comm	S_IFREG,4,4
	.comm	S_IFDIR,4,4
	.comm	KM_MAYFAIL,4,4
	.comm	ENOMEM,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
