	.file	"extr_xmerge.c_xdl_fill_merge_buffer.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	xdl_fill_merge_buffer, @function
xdl_fill_merge_buffer:
.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
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 88
	.cfi_def_cfa_offset 144
	mov	QWORD PTR 16[rsp], rdx
	mov	r15, QWORD PTR 152[rsp]
	xor	edx, edx
	mov	QWORD PTR 40[rsp], rdi
	mov	ebp, DWORD PTR 144[rsp]
	mov	QWORD PTR 8[rsp], rcx
	mov	rbx, QWORD PTR 160[rsp]
	mov	QWORD PTR 24[rsp], r8
	mov	QWORD PTR 32[rsp], r9
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 72[rsp], rax
	xor	eax, eax
	mov	QWORD PTR [rdi], 0
	mov	QWORD PTR 56[rsp], 0
	test	r15, r15
	jne	.L15
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L41:
	test	eax, eax
	jne	.L5
	mov	DWORD PTR [r15], ebp
	mov	eax, ebp
.L5:
	test	al, 3
	je	.L9
	xor	eax, eax
	test	rbx, rbx
	je	.L10
	mov	rax, QWORD PTR 56[rsp]
	add	rax, rbx
.L10:
	lea	r12, 64[rsp]
	sub	rsp, 8
	.cfi_def_cfa_offset 152
	mov	ecx, DWORD PTR 4[r15]
	xor	r9d, r9d
	push	rax
	.cfi_def_cfa_offset 160
	xor	r8d, r8d
	mov	rsi, r13
	mov	rdi, r12
	sub	ecx, edx
	call	xdl_recs_copy@PLT
	pop	r10
	.cfi_def_cfa_offset 152
	pop	r11
	.cfi_def_cfa_offset 144
	test	rax, rax
	js	.L6
	mov	rdx, QWORD PTR 64[rsp]
	mov	rsi, QWORD PTR 56[rsp]
	lea	r14, 56[rsp]
	mov	rdi, r14
	call	GIT_ERROR_CHECK_ALLOC_ADD@PLT
	mov	eax, DWORD PTR [r15]
	test	al, 1
	jne	.L40
.L11:
	test	al, 2
	je	.L7
	xor	eax, eax
	test	rbx, rbx
	je	.L14
	mov	rax, QWORD PTR 56[rsp]
	add	rax, rbx
.L14:
	sub	rsp, 8
	.cfi_def_cfa_offset 152
	mov	ecx, DWORD PTR 16[r15]
	mov	edx, DWORD PTR 12[r15]
	mov	rdi, r12
	push	rax
	.cfi_def_cfa_offset 160
	mov	rsi, QWORD PTR 24[rsp]
	xor	r9d, r9d
	xor	r8d, r8d
	call	xdl_recs_copy@PLT
	pop	rsi
	.cfi_def_cfa_offset 152
	pop	rdi
	.cfi_def_cfa_offset 144
	test	rax, rax
	js	.L6
	mov	rdx, QWORD PTR 64[rsp]
	mov	rsi, QWORD PTR 56[rsp]
	mov	rdi, r14
	call	GIT_ERROR_CHECK_ALLOC_ADD@PLT
.L7:
	mov	edx, DWORD PTR 8[r15]
	add	edx, DWORD PTR 4[r15]
.L9:
	mov	r15, QWORD PTR 24[r15]
	test	r15, r15
	je	.L2
.L15:
	mov	eax, DWORD PTR [r15]
	test	ebp, ebp
	jne	.L41
	test	eax, eax
	jne	.L5
	mov	eax, DWORD PTR 176[rsp]
	lea	rdi, 56[rsp]
	mov	rsi, r13
	push	rax
	.cfi_def_cfa_offset 152
	push	rbx
	.cfi_def_cfa_offset 160
	push	r15
	.cfi_def_cfa_offset 168
	mov	eax, DWORD PTR 192[rsp]
	push	rax
	.cfi_def_cfa_offset 176
	push	rdx
	.cfi_def_cfa_offset 184
	push	QWORD PTR 96[rsp]
	.cfi_def_cfa_offset 192
	mov	r9, QWORD PTR 80[rsp]
	mov	r8, QWORD PTR 72[rsp]
	mov	rcx, QWORD PTR 56[rsp]
	mov	rdx, QWORD PTR 64[rsp]
	call	fill_conflict_hunk@PLT
	add	rsp, 48
	.cfi_def_cfa_offset 144
	test	rax, rax
	jns	.L7
.L6:
	mov	eax, -1
.L1:
	mov	rbx, QWORD PTR 72[rsp]
	xor	rbx, QWORD PTR fs:40
	jne	.L42
	add	rsp, 88
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	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
.L40:
	.cfi_restore_state
	mov	rsi, QWORD PTR 8[rsp]
	mov	rdx, r15
	mov	rdi, r13
	call	is_cr_needed@PLT
	mov	r8d, eax
	xor	eax, eax
	test	rbx, rbx
	je	.L12
	mov	rax, QWORD PTR 56[rsp]
	add	rax, rbx
.L12:
	sub	rsp, 8
	.cfi_def_cfa_offset 152
	mov	r9d, DWORD PTR [r15]
	mov	ecx, DWORD PTR 8[r15]
	mov	rsi, r13
	mov	edx, DWORD PTR 4[r15]
	push	rax
	.cfi_def_cfa_offset 160
	mov	rdi, r12
	and	r9d, 2
	call	xdl_recs_copy@PLT
	pop	r8
	.cfi_def_cfa_offset 152
	pop	r9
	.cfi_def_cfa_offset 144
	test	rax, rax
	js	.L6
	mov	rdx, QWORD PTR 64[rsp]
	mov	rsi, QWORD PTR 56[rsp]
	mov	rdi, r14
	call	GIT_ERROR_CHECK_ALLOC_ADD@PLT
	mov	eax, DWORD PTR [r15]
	jmp	.L11
	.p2align 4,,10
	.p2align 3
.L2:
	test	rbx, rbx
	je	.L16
	add	rbx, QWORD PTR 56[rsp]
.L16:
	lea	rdi, 64[rsp]
	sub	rsp, 8
	.cfi_def_cfa_offset 152
	mov	ecx, DWORD PTR 0[r13]
	xor	r9d, r9d
	push	rbx
	.cfi_def_cfa_offset 160
	xor	r8d, r8d
	mov	rsi, r13
	sub	ecx, edx
	call	xdl_recs_copy@PLT
	pop	rdx
	.cfi_def_cfa_offset 152
	pop	rcx
	.cfi_def_cfa_offset 144
	test	rax, rax
	js	.L6
	mov	rdx, QWORD PTR 64[rsp]
	mov	rsi, QWORD PTR 56[rsp]
	lea	rdi, 56[rsp]
	call	GIT_ERROR_CHECK_ALLOC_ADD@PLT
	mov	rax, QWORD PTR 56[rsp]
	mov	rbx, QWORD PTR 40[rsp]
	mov	QWORD PTR [rbx], rax
	xor	eax, eax
	jmp	.L1
.L42:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	xdl_fill_merge_buffer, .-xdl_fill_merge_buffer
	.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_xmerge.c_xdl_fill_merge_buffer.c"
	.text
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	xdl_fill_merge_buffer, %function
xdl_fill_merge_buffer:
	@ args = 28, pretend = 0, frame = 24
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	sub	sp, sp, #60
	mov	ip, r0
	str	r0, [sp, #36]
	mov	r0, #0
	mov	r9, r3
	ldr	r3, .L40
	ldr	r4, [sp, #108]
	ldr	r3, [r3]
	str	r3, [sp, #52]
	mov	r3,#0
	ldr	r3, [sp, #96]
	cmp	r4, r0
	mov	r8, r1
	ldr	fp, [sp, #100]
	ldr	r6, [sp, #104]
	ldr	r5, [sp, #112]
	str	r0, [sp, #44]
	str	r0, [ip]
	str	r3, [sp, #32]
	beq	.L18
	mov	r10, r2
	mov	r7, r0
	mov	r2, r0
	b	.L15
.L38:
	cmp	r3, #0
	moveq	r3, r6
	streq	r6, [r4]
.L5:
	tst	r3, #3
	beq	.L9
	cmp	r5, #0
	moveq	r1, r5
	ldrne	r1, [sp, #44]
	ldr	r3, [r4, #4]
	addne	r1, r5, r1
	str	r1, [sp, #8]
	sub	r3, r3, r2
	mov	r1, r8
	str	r7, [sp, #4]
	str	r7, [sp]
	add	r0, sp, #48
	bl	xdl_recs_copy
	cmp	r0, #0
	blt	.L6
	ldr	r2, [sp, #48]
	ldr	r1, [sp, #44]
	add	r0, sp, #44
	bl	GIT_ERROR_CHECK_ALLOC_ADD
	ldr	r3, [r4]
	tst	r3, #1
	bne	.L37
.L11:
	tst	r3, #2
	beq	.L7
	cmp	r5, #0
	moveq	r1, r5
	ldrne	r1, [sp, #44]
	ldr	r2, [r4, #12]
	addne	r1, r5, r1
	ldr	r3, [r4, #16]
	add	r0, sp, #48
	str	r1, [sp, #8]
	str	r7, [sp, #4]
	mov	r1, r9
	str	r7, [sp]
	bl	xdl_recs_copy
	cmp	r0, #0
	blt	.L6
	ldr	r2, [sp, #48]
	ldr	r1, [sp, #44]
	add	r0, sp, #44
	bl	GIT_ERROR_CHECK_ALLOC_ADD
.L7:
	ldmib	r4, {r2, r3}
	add	r2, r3, r2
.L9:
	ldr	r4, [r4, #20]
	cmp	r4, #0
	beq	.L2
.L15:
	cmp	r6, #0
	ldr	r3, [r4]
	bne	.L38
	cmp	r3, #0
	bne	.L5
	ldr	r1, [sp, #120]
	ldr	r3, [sp, #44]
	str	r1, [sp, #28]
	str	r2, [sp, #12]
	ldr	r1, [sp, #116]
	ldr	r2, [sp, #32]
	str	r1, [sp, #16]
	str	r2, [sp]
	str	r3, [sp, #8]
	mov	r2, r10
	mov	r3, r9
	mov	r1, r8
	str	r5, [sp, #24]
	str	r4, [sp, #20]
	str	fp, [sp, #4]
	add	r0, sp, #44
	bl	fill_conflict_hunk
	cmp	r0, #0
	bge	.L7
.L6:
	mvn	r0, #0
.L1:
	ldr	r3, .L40
	ldr	r2, [r3]
	ldr	r3, [sp, #52]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L39
	add	sp, sp, #60
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L37:
	mov	r2, r4
	mov	r1, r9
	mov	r0, r8
	bl	is_cr_needed
	ldmib	r4, {r2, r3}
	cmp	r5, #0
	moveq	ip, r5
	ldrne	ip, [sp, #44]
	ldr	r1, [r4]
	addne	ip, r5, ip
	and	r1, r1, #2
	stm	sp, {r0, r1, ip}
	mov	r1, r8
	add	r0, sp, #48
	bl	xdl_recs_copy
	cmp	r0, #0
	blt	.L6
	ldr	r2, [sp, #48]
	ldr	r1, [sp, #44]
	add	r0, sp, #44
	bl	GIT_ERROR_CHECK_ALLOC_ADD
	ldr	r3, [r4]
	b	.L11
.L18:
	mov	r2, r4
.L2:
	mov	r4, #0
	cmp	r5, #0
	ldrne	r1, [sp, #44]
	ldr	r3, [r8]
	addne	r5, r5, r1
	sub	r3, r3, r2
	mov	r1, r8
	str	r5, [sp, #8]
	str	r4, [sp, #4]
	str	r4, [sp]
	add	r0, sp, #48
	bl	xdl_recs_copy
	cmp	r0, r4
	blt	.L6
	ldr	r2, [sp, #48]
	ldr	r1, [sp, #44]
	add	r0, sp, #44
	bl	GIT_ERROR_CHECK_ALLOC_ADD
	ldr	r3, [sp, #44]
	ldr	r2, [sp, #36]
	mov	r0, r4
	str	r3, [r2]
	b	.L1
.L39:
	bl	__stack_chk_fail
.L41:
	.align	2
.L40:
	.word	.LC0
	.size	xdl_fill_merge_buffer, .-xdl_fill_merge_buffer
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
